作者 lyh

gx

... ... @@ -492,6 +492,14 @@ class OptimizeController extends BaseController
$this->processChunkedList($productCategoryModel, ['status' => $productCategoryModel::STATUS_ACTIVE], ['id', 'title', 'route'], $domain, $data, 'product_category');
$productKeywordModel = new Keyword();
$this->processChunkedList($productKeywordModel, ['status' => $productKeywordModel::STATUS_ACTIVE], ['id', 'title', 'route'], $domain, $data, 'product_keyword');
$aiBlogModel = new AiBlog();
$list = $aiBlogModel->list(['route'=>['!=',null]],'id',['route','new_title']);
if(!empty($list)){
$DomainInfo['domain'] = $DomainInfo['domain'] ?? '';
foreach ($list as $v){
$data['ai_blog'][] = ('https://'.$DomainInfo['domain'].'/') . 'blog/' . $v['route'] . '/{' . $v['new_title'] . '}';
}
}
DB::disconnect('custom_mysql');
$this->response('success', Code::SUCCESS, $data);
}
... ...