作者 刘锟

合并分支 'akun' 到 'master'

Akun



查看合并请求 !2403
... ... @@ -43,7 +43,7 @@ class Temp extends Command
public function handle()
{
$this->specialImport();
}
/**
... ... @@ -54,8 +54,8 @@ class Temp extends Command
*/
public function specialImport()
{
$file_url = 'https://ecdn6.globalso.com/upload/p/3531/file/2025-06/news.csv';
$domain = 'www.hybio.com.cn';
$file_url = 'https://ecdn6.globalso.com/upload/p/3531/file/2025-07/www-cninfo-com-cn_news_v1-1.csv';
$domain = 'static.cninfo.com.cn';
$project_id = 3531;
$is_gbk = 0;
$file_code_type = $this->get_code_type($file_url);
... ... @@ -137,8 +137,10 @@ class Temp extends Command
protected function importModule($project_id, $domain, $data)
{
$module_id = 4;
$category_id = 3;
$model = new CustomModuleContent();
$module = $model->read(['name' => $data[0]]);
$module = $model->read(['module_id' => $module_id, 'name' => $data[0]]);
if (!$module) {
$content = '';
... ... @@ -164,20 +166,20 @@ class Temp extends Command
$content = $data[4];
}
$seo_title = '';
if ($data[6] ?? '') {
$seo_title = substr(strip_tags($data[6]), 0, 70);
}
$seo_title = '巨潮资讯网';
// if ($data[6] ?? '') {
// $seo_title = substr(strip_tags($data[6]), 0, 70);
// }
$seo_keywords = '';
if ($data[7] ?? '') {
$seo_keywords = substr(strip_tags(str_replace('^v6sp$', ',', $data[7])), 0, 255);
}
$seo_keywords = '巨潮资讯网,巨潮网,巨潮资讯,上市公司公告,巨潮,信息披露,法定披露,披露,创业板,基金,债券,财务数据,网络投票,互动易';
// if ($data[7] ?? '') {
// $seo_keywords = substr(strip_tags(str_replace('^v6sp$', ',', $data[7])), 0, 255);
// }
$seo_description = '';
if ($data[8] ?? '') {
$seo_description = substr(strip_tags($data[8]), 0, 200);
}
$seo_description = '巨潮资讯网是中国证监会指定的上市公司信息披露网站,平台提供上市公司公告、公司资讯、公司互动、股东大会网络投票等内容功能,一站式服务资本市场投资者。';
// if ($data[8] ?? '') {
// $seo_description = substr(strip_tags($data[8]), 0, 200);
// }
$release_at = date('Y-m-d H:i:s');
if ($data[9] ?? '') {
... ... @@ -188,8 +190,8 @@ class Temp extends Command
$id = $model->addReturnId(
[
'name' => $data[0],
'category_id' => ',1,',
'module_id' => 2,
'category_id' => ',' . $category_id . ',',
'module_id' => $module_id,
'content' => $content,
'seo_title' => $seo_title,
'seo_keywords' => $seo_keywords,
... ...