作者 lyh

gx

... ... @@ -48,7 +48,10 @@ class RankData extends BaseCommands
}
foreach ($list as $item){
$model = GoogleRankModel::where('project_id', $item['project_id'])->where('lang', '')->first();
@file_put_contents(storage_path('logs/lyh_error.log'), var_export('测试-----2222'.$model, true) . PHP_EOL, FILE_APPEND);
if (!$model || $model->updated_date != date('Y-m-d')) {
@file_put_contents(storage_path('logs/lyh_error.log'), var_export('测试-----2222', true) . PHP_EOL, FILE_APPEND);
$res = $api->getGoogleRank($item['api_no']);
if(!$res){
$error++;
... ... @@ -57,7 +60,6 @@ class RankData extends BaseCommands
//收录数
$indexed_pages_num = $site_res[$item['api_no']] ?? 0;
@file_put_contents(storage_path('logs/lyh_error.log'), var_export('测试-----333', true) . PHP_EOL, FILE_APPEND);
$this->save_rank($item['project_id'], $res, $indexed_pages_num);
}
//有小语种的
... ...