正在显示
1 个修改的文件
包含
2 行增加
和
6 行删除
| @@ -121,16 +121,12 @@ class GeoQuestionRes extends Command | @@ -121,16 +121,12 @@ class GeoQuestionRes extends Command | ||
| 121 | if (!empty($hit_keyword['keywords'])) { | 121 | if (!empty($hit_keyword['keywords'])) { |
| 122 | $hit++; | 122 | $hit++; |
| 123 | } | 123 | } |
| 124 | - if(!empty($hit_keyword['keywords_num'])){ | ||
| 125 | - $keyword_num = json_encode($hit_keyword['keywords_num'],true); | ||
| 126 | - } | 124 | + $keyword_num = json_encode($hit_keyword['keywords_num'] ?? [],true); |
| 127 | $hit_url = $this->getUrl($taskInfo['url'],$hit_data); | 125 | $hit_url = $this->getUrl($taskInfo['url'],$hit_data); |
| 128 | if (!empty($hit_url['url'])) { | 126 | if (!empty($hit_url['url'])) { |
| 129 | $hit++; | 127 | $hit++; |
| 130 | } | 128 | } |
| 131 | - if (!empty($hit_url['url_num'])) { | ||
| 132 | - $url_num = json_encode($hit_url['url'],true); | ||
| 133 | - } | 129 | + $url_num = json_encode($hit_url['url'] ?? [],true); |
| 134 | // 保存数据结果 | 130 | // 保存数据结果 |
| 135 | $geo_result = $geoResultModel->read(['project_id' => $taskInfo['project_id'],'type' => $taskInfo['type'], 'question_id' => $task_id, 'platform' => $platform, 'question' => $question],['id']); | 131 | $geo_result = $geoResultModel->read(['project_id' => $taskInfo['project_id'],'type' => $taskInfo['type'], 'question_id' => $task_id, 'platform' => $platform, 'question' => $question],['id']); |
| 136 | $save_data = [ | 132 | $save_data = [ |
-
请 注册 或 登录 后发表评论