|
|
@@ -390,6 +390,12 @@ class DeepSeekService
|
|
|
$version_id = getProp($data, 'version_id');
|
|
|
$generate_json = getProp($data, 'generate_json');
|
|
|
|
|
|
+ // 判断是否有未生成字幕的段落
|
|
|
+ $no_subtitle_sequences = DB::table('mp_chapter_paragraph_audios')->where('bid', $bid)->where('cid', $cid)->where('version_id', $version_id)->whereNull('subtitle_info')->pluck('sequence')->toArray();
|
|
|
+ if ($no_subtitle_sequences) {
|
|
|
+ Utils::throwError('20003:请先将以下章节序号生成字幕('.implode('、', $no_subtitle_sequences).')');
|
|
|
+ }
|
|
|
+
|
|
|
// 获取已生成的音频
|
|
|
$paragraph_audios = DB::table('mp_chapter_paragraph_audios')->where('bid', $bid)->where('cid', $cid)->where('version_id', $version_id)->get();
|
|
|
|