作者 刘锟

合并分支 'akun' 到 'master'

Akun



查看合并请求 !2961
... ... @@ -61,6 +61,9 @@ class SyncInquiryProject extends Command
*/
public function handle()
{
//截断路由表
InquiryProjectRoute::truncate();
$this->output('开始同步v5');
$this->syncGloV5();
$this->output('开始同步v6');
... ... @@ -202,8 +205,9 @@ class SyncInquiryProject extends Command
if (empty($ids))
return true;
$project_num = InquiryProject::whereIn('id', $ids)->delete();
$project_route_num = InquiryProjectRoute::whereIn('project_id', $ids)->delete();
$this->log('删除过期项目数量:' . $project_num . ', 删除过期项目路由数量:' . $project_route_num);
// $project_route_num = InquiryProjectRoute::whereIn('project_id', $ids)->delete();
// $this->log('删除过期项目数量:' . $project_num . ', 删除过期项目路由数量:' . $project_route_num);
$this->log('删除过期项目数量:' . $project_num);
return true;
}
... ...
... ... @@ -95,7 +95,7 @@ class SyncInquiryProjectRoute extends Command
$result = json_decode($result, true);
if (empty($result)) {
// 未获取到数据 删除当前项目过期路由
$this->deleteExpire($task->id, $date);
// $this->deleteExpire($task->id, $date);
$this->log('syncGloV5Route 未获取到路由信息:' . $task->id . ', 路由获取地址:' . ($task->is_split && $task->test_url ? $task->test_url : $task->main_url) . 'k_u_api.php');
return false;
}
... ... @@ -118,7 +118,7 @@ class SyncInquiryProjectRoute extends Command
}
// 删除当前项目过期路由
$this->deleteExpire($task->id, $date);
// $this->deleteExpire($task->id, $date);
return true;
}
... ... @@ -153,7 +153,7 @@ class SyncInquiryProjectRoute extends Command
DB::disconnect('custom_mysql');
// 删除当前项目过期路由
$this->deleteExpire($task->id, $date);
// $this->deleteExpire($task->id, $date);
return true;
}
... ...
... ... @@ -54,6 +54,12 @@ class SyncInquiryRelay extends Command
public function handle()
{
$hour = date('H');
if ($hour >= 2 && $hour <= 7) {
//凌晨2点~7点是同步项目及路由时间,该时间段不同步询盘
return;
}
$this->output('开始同步表单系统询盘');
$this->getInquiryForm();
... ...