作者 zhl

u bug

... ... @@ -146,7 +146,7 @@ class SyncInquiryProject extends Command
$this->pushTask($project->id);
}
$ids = InquiryProject::where('date', '<', $date)->where('version', '=', InquiryProject::VERSION_SIX)->pluck('id')->toArraty();
$ids = InquiryProject::where('date', '<', $date)->where('version', '=', InquiryProject::VERSION_SIX)->pluck('id')->toArray();
$this->deleteExpire($ids);
return true;
... ...
... ... @@ -127,6 +127,7 @@ class SyncInquiryProjectRoute extends Command
*/
public function syncGloV6Route($task)
{
echo '同步项目ID:' . $task->id . PHP_EOL;
$date = intval(date('Ymd'));
ProjectServer::useProject($task->primary_id);
// TODO 产品分类标题、路由, 产品标题、路由, 同步到路由表
... ... @@ -138,7 +139,6 @@ class SyncInquiryProjectRoute extends Command
// 产品数量会比较多, 所以使用分页 同步数据
$id = 0;
while (true) {
echo '同步项目路由:' . $id . PHP_EOL;
$product = Product::where('status', Product::STATUS_ON)->where('id', '>', $id)->orderBy('id', 'asc')->limit(1000)->get(['id', 'title', 'route']);
if ($product->isEmpty())
break;
... ...