Browse Source

1.删除保存资产名时左右两边的符号2.有剧本资产时直接使用,不再AI生成

lh 5 days ago
parent
commit
403edda5a0
2 changed files with 12 additions and 2 deletions
  1. 3 0
      app/Services/Anime/AnimeService.php
  2. 9 2
      app/Services/DeepSeek/DeepSeekService.php

+ 3 - 0
app/Services/Anime/AnimeService.php

@@ -7013,6 +7013,9 @@ class AnimeService
                     if (empty($product_name)) {
                         continue;
                     }
+
+                    // 处理product_name两边的符号
+                    $product_name = preg_replace('/^[【】\s]+|[【】\s]+$/u', '', $product_name);
                     
                     // 直接插入新资产到 mp_products 表(parent_id 指向对应类型的根文件夹)
                     $product_id = DB::table('mp_products')->insertGetId([

File diff suppressed because it is too large
+ 9 - 2
app/Services/DeepSeek/DeepSeekService.php