|
@@ -4,13 +4,10 @@
|
|
|
<div class="stem">
|
|
|
<RichText v-model="data.stem" :font-size="18" placeholder="输入题干" />
|
|
|
|
|
|
- <el-input
|
|
|
- v-show="isEnable(data.property.is_enable_description)"
|
|
|
+ <RichText
|
|
|
+ v-if="isEnable(data.property.is_enable_description)"
|
|
|
v-model="data.description"
|
|
|
- rows="3"
|
|
|
- resize="none"
|
|
|
- type="textarea"
|
|
|
- placeholder="输入描述"
|
|
|
+ placeholder="输入提示"
|
|
|
/>
|
|
|
</div>
|
|
|
|
|
@@ -86,6 +83,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
+import RichText from '@/components/common/RichText.vue';
|
|
|
import QuestionMixin from '../common/QuestionMixin.js';
|
|
|
|
|
|
import { getRandomNumber } from '@/utils';
|
|
@@ -93,6 +91,7 @@ import { dialogueData } from '@/views/exercise_questions/data/dialogue';
|
|
|
|
|
|
export default {
|
|
|
name: 'DialogueQuestion',
|
|
|
+ components: { RichText },
|
|
|
mixins: [QuestionMixin],
|
|
|
data() {
|
|
|
return {
|
|
@@ -102,8 +101,9 @@ export default {
|
|
|
watch: {
|
|
|
'data.dialogue': {
|
|
|
handler(val) {
|
|
|
- if (!val) return;
|
|
|
-
|
|
|
+ if (!val) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
let direction = 'row';
|
|
|
let preName = '';
|
|
|
this.data.option_list = val
|
|
@@ -131,7 +131,6 @@ export default {
|
|
|
.filter((item) => item)
|
|
|
.map((content) => {
|
|
|
let isInput = reg.test(content);
|
|
|
-
|
|
|
return {
|
|
|
content: isInput ? '' : content,
|
|
|
mark: getRandomNumber(),
|
|
@@ -139,7 +138,6 @@ export default {
|
|
|
};
|
|
|
});
|
|
|
}
|
|
|
-
|
|
|
return {
|
|
|
name,
|
|
|
content: isFill ? fillList : content,
|