|
|
@@ -564,6 +564,9 @@ switch ($action) {
|
|
|
exit();
|
|
|
break;
|
|
|
case 'main_welcome':
|
|
|
+ //分担查询
|
|
|
+ include ONLINE_ROOT . 'libs' . DS . 'map_config.ini.php';
|
|
|
+
|
|
|
$cp = common::check_input($_POST ['cp']); //current_page
|
|
|
$ps = common::check_input($_POST ['ps']); //ps
|
|
|
if (empty($ps))
|
|
|
@@ -594,7 +597,8 @@ switch ($action) {
|
|
|
$rc = $_POST ['rc'];
|
|
|
if ($rc == - 1) {
|
|
|
$sql = "SELECT count(1) from public.kln_ocean" . $sqlWhere;
|
|
|
- $rc = common::excuteOneSql($sql);
|
|
|
+ //$rc = common::excuteOneSql($sql);
|
|
|
+ $rc = $mapdb->GetOne($sql) or ( (!$mapdb->ErrorMsg()) or error_log(common::dbLog($mapdb, $sql), 0));
|
|
|
}
|
|
|
$tp = ceil($rc / $ps);
|
|
|
if ($rc > 0) {
|
|
|
@@ -615,7 +619,8 @@ switch ($action) {
|
|
|
//$sqlWhere and last_status_315_update_time is not null";
|
|
|
$sql .= " ORDER BY eta desc,id DESC limit " . $ps . " offset " . ($cp - 1) * $ps;
|
|
|
//$sql .= " ORDER BY last_status_315_update_time DESC limit " . $ps . " offset " . ($cp - 1) * $ps;
|
|
|
- $rss = common::excuteListSql($sql);
|
|
|
+ //$rss = common::excuteListSql($sql);
|
|
|
+ $rss = $mapdb->GetAll($sql) or ( (!$mapdb->ErrorMsg()) or error_log(common::dbLog($mapdb, $sql), 0));
|
|
|
//RecentStatusList
|
|
|
$RecentStatusList = array();
|
|
|
foreach ($rss as $key => $value) {
|
|
|
@@ -639,9 +644,7 @@ switch ($action) {
|
|
|
} elseif ($value['transport_mode'] == "air"){
|
|
|
//air milestone 的Departed实际描述要替换: IFFDEP =》 IFFONB
|
|
|
$milestone_sql = "select a.act_date,a.act_time,sn.description,a.timezone,
|
|
|
- case when a.code = 'IFFONB' then 'IFFDEP'
|
|
|
- else a.code
|
|
|
- end as dd_code
|
|
|
+ a.code as dd_code
|
|
|
from $_schemas_bk.air_milestone a
|
|
|
inner join public.customer_service_milestone_sno sn on sn.code=a.code and sn.type = 'air'
|
|
|
where a.serial_no='$serial_no'
|
|
|
@@ -695,15 +698,6 @@ switch ($action) {
|
|
|
$timezone = common::excuteOneSql($sql);
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
- // 根据IFFDEL这个milestone来判断是否转变为completed
|
|
|
- // if($value['dd_code'] == "IFFAFD"){
|
|
|
- // $timezone = $EDI315Time[$value['dd_code']]['timezone'];
|
|
|
- // if(empty($timezone)){
|
|
|
- // $sql = "select time_zone from public.city_timezone where uncode = '".$value['place_of_delivery_un']."'";
|
|
|
- // $timezone = common::excuteOneSql($sql);
|
|
|
- // }
|
|
|
- // }
|
|
|
}
|
|
|
|
|
|
$Arrived = $value['description'];
|