|
@@ -10,6 +10,14 @@
|
|
|
>{{ label }}</a
|
|
|
>
|
|
|
</div>
|
|
|
+ <div class="answer-type" v-if="data.property.model === 'input'">
|
|
|
+ <span>答题方式:</span>
|
|
|
+ <el-checkbox-group v-model="data.answer_type">
|
|
|
+ <el-checkbox label="pinyin">填拼音</el-checkbox>
|
|
|
+ <el-checkbox label="en">填释义</el-checkbox>
|
|
|
+ <!-- <el-checkbox label="con">写汉字</el-checkbox> -->
|
|
|
+ </el-checkbox-group>
|
|
|
+ </div>
|
|
|
<div class="content-box" v-for="(item, index) in data.option_list" :key="index">
|
|
|
<div class="content-item">
|
|
|
<el-input
|
|
@@ -21,6 +29,51 @@
|
|
|
></el-input>
|
|
|
<el-button @click="identify(item)">识别</el-button>
|
|
|
</div>
|
|
|
+ <div class="option-item">
|
|
|
+ <template v-if="isEnable(data.property.is_enable_pinyin) || data.answer_type.indexOf('pinyin') > -1">
|
|
|
+ <span>共用拼音:</span>
|
|
|
+ <el-radio-group v-model="item.is_common_pinyin">
|
|
|
+ <el-radio :label="true">是</el-radio>
|
|
|
+ <el-radio :label="false">否</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
+ <template
|
|
|
+ v-if="
|
|
|
+ isEnable(data.property.is_enable_pinyin) && data.property.model === 'input' && item.is_common_pinyin
|
|
|
+ "
|
|
|
+ >
|
|
|
+ <span>拼音</span>
|
|
|
+ <el-input v-model="item.pinyin" placeholder="输入拼音"></el-input>
|
|
|
+ </template>
|
|
|
+ <template
|
|
|
+ v-if="data.answer_type.indexOf('pinyin') > -1 && data.property.model === 'input' && item.is_common_pinyin"
|
|
|
+ >
|
|
|
+ <span>拼音答案</span>
|
|
|
+ <el-input v-model="item.answer_pinyin" placeholder="输入拼音"></el-input>
|
|
|
+ </template>
|
|
|
+
|
|
|
+ <template v-if="isEnable(data.property.is_enable_shiyi) && data.property.model === 'input'">
|
|
|
+ <span>释义</span>
|
|
|
+ <el-input v-model="item.shiyi" placeholder="输入释义"></el-input>
|
|
|
+ </template>
|
|
|
+ <template v-if="data.answer_type.indexOf('en') > -1 && data.property.model === 'input'">
|
|
|
+ <span>释义答案</span>
|
|
|
+ <el-input v-model="item.answer_en" placeholder="输入释义"></el-input>
|
|
|
+ </template>
|
|
|
+ <template
|
|
|
+ v-if="
|
|
|
+ data.property.model === 'input' &&
|
|
|
+ (data.answer_type.indexOf('en') > -1 ||
|
|
|
+ (data.answer_type.indexOf('pinyin') > -1 && item.is_common_pinyin))
|
|
|
+ "
|
|
|
+ >
|
|
|
+ <span>例子</span>
|
|
|
+ <el-radio-group v-model="item.is_example">
|
|
|
+ <el-radio :label="true">是</el-radio>
|
|
|
+ <el-radio :label="false">否</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
+ </template>
|
|
|
+ </template>
|
|
|
+ </div>
|
|
|
<div class="content-items" v-for="(items, indexs) in item.content_list" :key="indexs">
|
|
|
<template v-if="items">
|
|
|
<label>内容:{{ items.con }} </label>
|
|
@@ -37,14 +90,19 @@
|
|
|
@updateFileList="updateFileList"
|
|
|
/>
|
|
|
<div class="option-item">
|
|
|
- <template v-if="isEnable(data.property.is_enable_pinyin)">
|
|
|
+ <template
|
|
|
+ v-if="
|
|
|
+ isEnable(data.property.is_enable_pinyin) &&
|
|
|
+ (data.property.model === 'miao' || (data.property.model === 'input' && !item.is_common_pinyin))
|
|
|
+ "
|
|
|
+ >
|
|
|
<span>拼音</span>
|
|
|
- <el-input v-model="items.pinyin"></el-input>
|
|
|
+ <el-input v-model="items.pinyin" placeholder="输入拼音"></el-input>
|
|
|
</template>
|
|
|
- <template v-if="isEnable(data.property.is_enable_shiyi) && data.property.model === 'input'">
|
|
|
+ <!-- <template v-if="isEnable(data.property.is_enable_shiyi) && data.property.model === 'input'">
|
|
|
<span>释义</span>
|
|
|
- <el-input v-model="items.shiyi"></el-input>
|
|
|
- </template>
|
|
|
+ <el-input v-model="items.shiyi" placeholder="输入释义"></el-input>
|
|
|
+ </template> -->
|
|
|
<template v-if="data.property.model === 'miao' && items.type === 'hanzi'">
|
|
|
<span>可输入</span>
|
|
|
<el-radio-group v-model="items.is_can_input_answer">
|
|
@@ -62,6 +120,29 @@
|
|
|
<el-radio :label="false">否</el-radio>
|
|
|
</el-radio-group>
|
|
|
</template>
|
|
|
+ <template
|
|
|
+ v-if="
|
|
|
+ data.answer_type.indexOf('pinyin') > -1 && data.property.model === 'input' && !item.is_common_pinyin
|
|
|
+ "
|
|
|
+ >
|
|
|
+ <span>拼音答案</span>
|
|
|
+ <el-input v-model="items.answer_pinyin" placeholder="输入拼音"></el-input>
|
|
|
+ </template>
|
|
|
+ <template
|
|
|
+ v-if="
|
|
|
+ data.property.model === 'input' && data.answer_type.indexOf('pinyin') > -1 && !item.is_common_pinyin
|
|
|
+ "
|
|
|
+ >
|
|
|
+ <span>例子</span>
|
|
|
+ <el-radio-group v-model="items.is_example">
|
|
|
+ <el-radio :label="true">是</el-radio>
|
|
|
+ <el-radio :label="false">否</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
+ </template>
|
|
|
+ <template v-if="isEnable(data.property.is_enable_high_strokes) && data.property.model === 'input'">
|
|
|
+ <span>高亮笔画</span>
|
|
|
+ <el-input v-model="items.shiyi" placeholder="多笔用、隔开"></el-input>
|
|
|
+ </template>
|
|
|
</div>
|
|
|
</template>
|
|
|
</div>
|
|
@@ -162,6 +243,7 @@ export default {
|
|
|
answer_en: '',
|
|
|
is_example: false,
|
|
|
is_can_input_answer: true,
|
|
|
+ is_can_input_pinyin: true,
|
|
|
};
|
|
|
} else if (item === '#') {
|
|
|
// 书写
|
|
@@ -301,28 +383,43 @@ export default {
|
|
|
line-height: 34px;
|
|
|
color: #4e5969;
|
|
|
}
|
|
|
+}
|
|
|
|
|
|
- .option-item {
|
|
|
- display: flex;
|
|
|
- align-items: center;
|
|
|
- margin-top: 5px;
|
|
|
+.option-item {
|
|
|
+ display: flex;
|
|
|
+ flex-flow: wrap;
|
|
|
+ align-items: center;
|
|
|
+ margin-top: 5px;
|
|
|
|
|
|
- span {
|
|
|
- flex-shrink: 0;
|
|
|
- width: max-content;
|
|
|
- margin-right: 10px;
|
|
|
- font-size: 14px;
|
|
|
- color: #4e5969;
|
|
|
- }
|
|
|
+ span {
|
|
|
+ flex-shrink: 0;
|
|
|
+ width: max-content;
|
|
|
+ margin-right: 10px;
|
|
|
+ font-size: 14px;
|
|
|
+ color: #4e5969;
|
|
|
+ }
|
|
|
|
|
|
- .el-input {
|
|
|
- max-width: 100px;
|
|
|
- margin-right: 30px;
|
|
|
- }
|
|
|
+ .el-input {
|
|
|
+ max-width: 100px;
|
|
|
+ margin-right: 30px;
|
|
|
+ }
|
|
|
|
|
|
- .el-radio-group {
|
|
|
- margin-right: 30px;
|
|
|
- }
|
|
|
+ .el-radio-group {
|
|
|
+ margin-right: 30px;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.answer-type {
|
|
|
+ display: flex;
|
|
|
+ gap: 10px;
|
|
|
+ margin: 10px 0;
|
|
|
+
|
|
|
+ span {
|
|
|
+ flex-shrink: 0;
|
|
|
+ width: max-content;
|
|
|
+ margin-right: 10px;
|
|
|
+ font-size: 14px;
|
|
|
+ color: #4e5969;
|
|
|
}
|
|
|
}
|
|
|
</style>
|