|
@@ -22,12 +22,9 @@
|
|
|
<span class="question-number" title="双击切换序号类型" @dblclick="changeOptionType(data)">
|
|
|
{{ computedQuestionNumber(i, data.option_number_show_mode) }}
|
|
|
</span>
|
|
|
- <el-input
|
|
|
- v-if="data.other.audio_generation_method === 'auto'"
|
|
|
- v-model="item.content"
|
|
|
- placeholder="拼音间用空格隔开"
|
|
|
- @change="item.audio_file_id = ''"
|
|
|
- />
|
|
|
+ <div class="option-content">
|
|
|
+ <RichText v-model="item.content" :class="'repeat' + i" placeholder="输入内容" :inline="true" />
|
|
|
+ </div>
|
|
|
<UploadAudio
|
|
|
v-if="data.other.audio_generation_method === 'upload'"
|
|
|
:key="item.audio_file_id || i"
|
|
@@ -209,11 +206,15 @@ export default {
|
|
|
},
|
|
|
// 自动生成音频
|
|
|
handleMatically(item, i) {
|
|
|
- if (item.content.trim()) {
|
|
|
+ if (
|
|
|
+ document.getElementsByClassName(`repeat${i}`) &&
|
|
|
+ document.getElementsByClassName(`repeat${i}`)[0] &&
|
|
|
+ document.getElementsByClassName(`repeat${i}`)[0].innerText
|
|
|
+ ) {
|
|
|
this.loading_list[i].loading = true;
|
|
|
let MethodName = 'tool-PinyinToVoiceFile';
|
|
|
let data = {
|
|
|
- pinyin: item.content.trim().split(' ').join(','),
|
|
|
+ pinyin: document.getElementsByClassName(`repeat${i}`)[0].innerText.trim().split(' ').join(','),
|
|
|
};
|
|
|
GetStaticResources(MethodName, data)
|
|
|
.then((res) => {
|