|
...
|
...
|
@@ -77,6 +77,8 @@ class GeoQuestionRes extends Command |
|
|
|
echo $e->getMessage().PHP_EOL;
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
//查询当前是否已有执行保存记录
|
|
|
|
$resultInfo = $geoResultModel->read(['project_id'=>$info['project_id'],'question_id'=>$info['id'],'platform'=>$p_item,'question'=>$q_item],['id']);
|
|
|
|
//保存一条结果记录
|
|
|
|
$data = [
|
|
|
|
'project_id'=>$info['project_id'],
|
|
...
|
...
|
@@ -87,7 +89,11 @@ class GeoQuestionRes extends Command |
|
|
|
'text'=>json_encode($result_data ?? [],true),
|
|
|
|
'url'=>json_encode($urls ?? [],true),//命中的网址
|
|
|
|
];
|
|
|
|
$geoResultModel->addReturnId($data);
|
|
|
|
if($resultInfo === false){
|
|
|
|
$geoResultModel->addReturnId($data);
|
|
|
|
}else{
|
|
|
|
$geoResultModel->edit($data,['id'=>$resultInfo['id']]);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
//更新下次执行时间
|
...
|
...
|
|