} elseif ($type == 'J') { use_class('minierp_packages'); $class_mp = new minierp_packages(); use_class('orders'); $class_o = new orders(); foreach ($pack as $p) { $items = $class_mp->sendPackage($p['packages_id']); foreach ($items as $items_id) { $class_o->updateProductStatus($items_id, '7', $session_userinfo['username']); } } } else { use_class('depot_orders'); $class_do = new depot_orders(); foreach ($pack as $p) { $class_do->packageSetSent($p['packages_id'], $session_userinfo['username']); } } } echo utf8_encode($logistic_id); } elseif ($_POST['me_action'] == 'SAVELOG') { use_class('products_minierp'); $class_pm = new products_minierp(); $bgst = $class_pm->retrieveBestGoodSettings(); $logistic_id = tep_db_prepare_input($_POST['lid']); $logpart = tep_db_prepare_input($_POST['lpart']); $ldate = explode('.', tep_db_prepare_input($_POST['ldate'])); $logistic_date = date('Y-m-d', strtotime($ldate[2] . '-' . $ldate[1] . '-' . $ldate[0])); $logistic_code = strtolower($logpart) == 'dhl' ? 'DHL' . date('ymd', strtotime($logistic_date)) : tep_db_prepare_input($_POST['lcode']); $logistic_weight = tep_db_prepare_input($_POST['lweight']); $logistic_price = tep_db_prepare_input($_POST['lprice']);