正在显示
1 个修改的文件
包含
30 行增加
和
3 行删除
| @@ -92,6 +92,21 @@ class UpdateSeoTdk extends Command | @@ -92,6 +92,21 @@ class UpdateSeoTdk extends Command | ||
| 92 | 'blog_cat_meta_keywords' => 'seo_keywords', | 92 | 'blog_cat_meta_keywords' => 'seo_keywords', |
| 93 | 'blog_cat_meta_description' => 'seo_des', | 93 | 'blog_cat_meta_description' => 'seo_des', |
| 94 | ], | 94 | ], |
| 95 | + 'gl_ai_blog' => [ | ||
| 96 | + 'ai_blog_title' => 'seo_title', | ||
| 97 | + 'ai_blog_meta_keywords' => 'seo_keyword', | ||
| 98 | + 'ai_blog_meta_description' => 'seo_description', | ||
| 99 | + ], | ||
| 100 | + 'gl_ai_blog_list' => [ | ||
| 101 | + 'ai_blog_cat_title' => 'seo_title', | ||
| 102 | + 'ai_blog_cat_meta_keywords' => 'seo_keyword', | ||
| 103 | + 'ai_blog_cat_meta_description' => 'seo_description', | ||
| 104 | + ], | ||
| 105 | + 'gl_ai_blog_author' => [ | ||
| 106 | + 'ai_blog_author_title' => 'seo_title', | ||
| 107 | + 'ai_blog_author_meta_keywords' => 'seo_keyword', | ||
| 108 | + 'ai_blog_author_meta_description' => 'seo_description', | ||
| 109 | + ], | ||
| 95 | 'gl_news' => [ | 110 | 'gl_news' => [ |
| 96 | 'news_title' => 'seo_title', | 111 | 'news_title' => 'seo_title', |
| 97 | 'news_meta_keywords' => 'seo_keywords', | 112 | 'news_meta_keywords' => 'seo_keywords', |
| @@ -131,6 +146,9 @@ class UpdateSeoTdk extends Command | @@ -131,6 +146,9 @@ class UpdateSeoTdk extends Command | ||
| 131 | 'gl_product_category' => 'title', | 146 | 'gl_product_category' => 'title', |
| 132 | 'gl_blog' => 'name', | 147 | 'gl_blog' => 'name', |
| 133 | 'gl_blog_category' => 'name', | 148 | 'gl_blog_category' => 'name', |
| 149 | + 'gl_ai_blog' => 'new_title', | ||
| 150 | + 'gl_ai_blog_list' => '', //直接使用 top blog | ||
| 151 | + 'gl_ai_blog_author' => 'title', | ||
| 134 | 'gl_news' => 'name', | 152 | 'gl_news' => 'name', |
| 135 | 'gl_news_category' => 'name', | 153 | 'gl_news_category' => 'name', |
| 136 | 'gl_product_keyword' => 'title', | 154 | 'gl_product_keyword' => 'title', |
| @@ -149,7 +167,7 @@ class UpdateSeoTdk extends Command | @@ -149,7 +167,7 @@ class UpdateSeoTdk extends Command | ||
| 149 | ]; | 167 | ]; |
| 150 | 168 | ||
| 151 | /** | 169 | /** |
| 152 | - * '表' => 'C端页面更新的数据类型' | 170 | + * '表' => 'C端页面更新的数据类型' 子表 route_map的source类型 |
| 153 | * @return array | 171 | * @return array |
| 154 | * @author akun | 172 | * @author akun |
| 155 | * @date 2024/11/14 | 173 | * @date 2024/11/14 |
| @@ -160,6 +178,9 @@ class UpdateSeoTdk extends Command | @@ -160,6 +178,9 @@ class UpdateSeoTdk extends Command | ||
| 160 | 'gl_product_category' => 'product_category', | 178 | 'gl_product_category' => 'product_category', |
| 161 | 'gl_blog' => 'blog', | 179 | 'gl_blog' => 'blog', |
| 162 | 'gl_blog_category' => 'blog_category', | 180 | 'gl_blog_category' => 'blog_category', |
| 181 | + 'gl_ai_blog' => 'ai_blog', | ||
| 182 | + 'gl_ai_blog_list' => 'ai_blog_list', | ||
| 183 | + 'gl_ai_blog_author' => 'ai_blog_author', | ||
| 163 | 'gl_news' => 'news', | 184 | 'gl_news' => 'news', |
| 164 | 'gl_news_category' => 'news_category', | 185 | 'gl_news_category' => 'news_category', |
| 165 | 'gl_product_keyword' => 'product_keyword', | 186 | 'gl_product_keyword' => 'product_keyword', |
| @@ -179,6 +200,9 @@ class UpdateSeoTdk extends Command | @@ -179,6 +200,9 @@ class UpdateSeoTdk extends Command | ||
| 179 | 'gl_product_category' => 'route', | 200 | 'gl_product_category' => 'route', |
| 180 | 'gl_blog' => 'url', | 201 | 'gl_blog' => 'url', |
| 181 | 'gl_blog_category' => 'alias', | 202 | 'gl_blog_category' => 'alias', |
| 203 | + 'gl_ai_blog' => 'route', | ||
| 204 | + 'gl_ai_blog_list' => 'route', | ||
| 205 | + 'gl_ai_blog_author' => 'route', | ||
| 182 | 'gl_news' => 'url', | 206 | 'gl_news' => 'url', |
| 183 | 'gl_news_category' => 'alias', | 207 | 'gl_news_category' => 'alias', |
| 184 | 'gl_product_keyword' => 'route', | 208 | 'gl_product_keyword' => 'route', |
| @@ -340,8 +364,7 @@ class UpdateSeoTdk extends Command | @@ -340,8 +364,7 @@ class UpdateSeoTdk extends Command | ||
| 340 | } | 364 | } |
| 341 | $data[$field] = $this->ai_send($prompt, $project_id, $table, $v['id']); | 365 | $data[$field] = $this->ai_send($prompt, $project_id, $table, $v['id']); |
| 342 | } | 366 | } |
| 343 | - } | ||
| 344 | - else if ($table == 'gl_product_keyword' && $field == 'seo_title') { | 367 | + } else if ($table == 'gl_product_keyword' && $field == 'seo_title') { |
| 345 | # TODO 聚合页seo title 特殊处理 前缀_1 . 关键词 . 后缀_2 | 368 | # TODO 聚合页seo title 特殊处理 前缀_1 . 关键词 . 后缀_2 |
| 346 | $prefix = $this->getPrefixKeyword($project_id, 'prefix', 1, $v[$this->topic_fields[$table]]); | 369 | $prefix = $this->getPrefixKeyword($project_id, 'prefix', 1, $v[$this->topic_fields[$table]]); |
| 347 | $suffix = $this->getPrefixKeyword($project_id, 'suffix', 2, $v[$this->topic_fields[$table]]); | 370 | $suffix = $this->getPrefixKeyword($project_id, 'suffix', 2, $v[$this->topic_fields[$table]]); |
| @@ -350,6 +373,10 @@ class UpdateSeoTdk extends Command | @@ -350,6 +373,10 @@ class UpdateSeoTdk extends Command | ||
| 350 | $seo_title = $prefix . ' ' . $v[$this->topic_fields[$table]] . ' ' . $suffix; | 373 | $seo_title = $prefix . ' ' . $v[$this->topic_fields[$table]] . ' ' . $suffix; |
| 351 | $data[$field] = $seo_title; | 374 | $data[$field] = $seo_title; |
| 352 | $update[$table]['title']++; | 375 | $update[$table]['title']++; |
| 376 | + } else if ($table == 'gl_ai_blog_list' && $field == 'seo_title') { | ||
| 377 | + //直接使用 top blog | ||
| 378 | + $data[$field] = 'top blog'; | ||
| 379 | + $update[$table]['title']++; | ||
| 353 | } else { | 380 | } else { |
| 354 | //直接使用topic | 381 | //直接使用topic |
| 355 | if (count($field_arr) > 1) { | 382 | if (count($field_arr) > 1) { |
-
请 注册 或 登录 后发表评论