|
...
|
...
|
@@ -57,12 +57,12 @@ class UpdateSeoTdk extends Command |
|
|
|
echo date('Y-m-d H:i:s') . ' start: ' . $project_id . PHP_EOL;
|
|
|
|
try {
|
|
|
|
ProjectServer::useProject($project_id);
|
|
|
|
$this->updateProduct($project_id);
|
|
|
|
$this->updateProductCate($project_id);
|
|
|
|
$this->updateBlogs($project_id);
|
|
|
|
$this->updateBlogCate($project_id);
|
|
|
|
$this->updateNews($project_id);
|
|
|
|
$this->updateNewsCate($project_id);
|
|
|
|
// $this->updateProduct($project_id);
|
|
|
|
// $this->updateProductCate($project_id);
|
|
|
|
// $this->updateBlogs($project_id);
|
|
|
|
// $this->updateBlogCate($project_id);
|
|
|
|
// $this->updateNews($project_id);
|
|
|
|
// $this->updateNewsCate($project_id);
|
|
|
|
$this->updatePage($project_id);
|
|
|
|
DB::disconnect('custom_mysql');
|
|
|
|
}catch (\Exception $e){
|
|
...
|
...
|
@@ -332,7 +332,7 @@ class UpdateSeoTdk extends Command |
|
|
|
$v = (array)$v;
|
|
|
|
echo date('Y-m-d H:i:s') . ' updatePage: ' . $v['id'] . PHP_EOL;
|
|
|
|
$data = [];
|
|
|
|
if(empty($v['seo_title'])){
|
|
|
|
if(empty($v['title'])){
|
|
|
|
//生成seo_title
|
|
|
|
$data['title'] = $v['title'];
|
|
|
|
}
|
|
...
|
...
|
@@ -353,6 +353,7 @@ class UpdateSeoTdk extends Command |
|
|
|
DB::connection('custom_mysql')->table('gl_web_custom_template')->where(['id'=>$v['id']])->update($data);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
...
|
...
|
|