|
@@ -131,6 +131,23 @@ class Material():
|
|
audio_id = list[count]['audio_id']
|
|
audio_id = list[count]['audio_id']
|
|
srt = list[count]['text']
|
|
srt = list[count]['text']
|
|
return audio_id, srt, title_list
|
|
return audio_id, srt, title_list
|
|
|
|
+ else:
|
|
|
|
+ audio_type = [{"audio": "音画美文--美文类", "type": "6VXm7q"}, {"audio": "音画美文--通用类", "type": "aSNFl8"}]
|
|
|
|
+ audio_type = random.choice(audio_type)
|
|
|
|
+ type = audio_type['type']
|
|
|
|
+ audio_type = Feishu.get_values_batch("prod", "succinct", type)
|
|
|
|
+ for row in audio_type[1:]:
|
|
|
|
+ audio_id = row[0]
|
|
|
|
+ text = row[1]
|
|
|
|
+ title = row[2]
|
|
|
|
+ number = {"audio_id": audio_id, "text": text}
|
|
|
|
+ if audio_id:
|
|
|
|
+ list.append(number)
|
|
|
|
+ title_list.append(title)
|
|
|
|
+ list = random.choice(list)
|
|
|
|
+ audio_id = list['audio_id']
|
|
|
|
+ srt = list['text']
|
|
|
|
+ return audio_id, srt, title_list
|
|
else:
|
|
else:
|
|
audio_type = [{"audio": "音画美文--美文类", "type": "6VXm7q"}, {"audio": "音画美文--通用类", "type": "aSNFl8"}]
|
|
audio_type = [{"audio": "音画美文--美文类", "type": "6VXm7q"}, {"audio": "音画美文--通用类", "type": "aSNFl8"}]
|
|
audio_type = random.choice(audio_type)
|
|
audio_type = random.choice(audio_type)
|