作者 刘锟

update

... ... @@ -320,6 +320,9 @@ class ProjectUpdate extends Command
} else {
$image = $item['images'] ?? '';
}
if(strpos($image,'//') === 0){
$image = 'https:'.$image;
}
$id = $model->addReturnId([
'project_id' => $project_id,
'name' => $item['ttile'],
... ...
... ... @@ -40,7 +40,7 @@ class Temp extends Command
protected function start_update()
{
$list = UpdateLog::where('project_id', 437)->where('api_type', 'news')->get();
$list = UpdateLog::where('project_id', '!=', 437)->where('api_type', 'news')->get();
foreach ($list as $task) {
$project_id = $task->project_id;
... ... @@ -86,8 +86,8 @@ class Temp extends Command
} else {
$image = $item['images'] ?? '';
}
if(strpos($image,'//') === 0){
$image = 'https:'.$image;
if (strpos($image, '//') === 0) {
$image = 'https:' . $image;
}
$model->edit(['image' => $image], ['id' => $news['id']]);
} catch (\Exception $e) {
... ...