代二狗子的修改日常

This commit is contained in:
Yuanjianghong 2021-11-30 08:53:54 +08:00
parent 1dd3235872
commit 06300c0429
1 changed files with 18 additions and 6 deletions

View File

@ -50,48 +50,50 @@
<a-card title="题目(题干内容)" :bordered="false">
<a-textarea placeholder="" :rows="6" v-model="multiselect.questionName" style="width: 100%" />
</a-card>
<a-checkbox-group @change="onChange" :value="checkedValues" style="width: 100%">
<a-card :bordered="false">
<template slot="title">
选项从选项中选择一个作为答案<br />A &nbsp;&nbsp;
<a-checkbox v-model="multiselect.a" value="A">答案</a-checkbox>
<a-checkbox value="A">答案</a-checkbox>
</template>
<a-textarea placeholder="" :rows="6" v-model="multiselect.answerA" style="width: 100%" />
</a-card>
<a-card :bordered="false">
<template slot="title">
B &nbsp;&nbsp;
<a-checkbox v-model="multiselect.b" value="B">答案</a-checkbox>
<a-checkbox value="B">答案</a-checkbox>
</template>
<a-textarea placeholder="" :rows="6" v-model="multiselect.answerB" style="width: 100%" />
</a-card>
<a-card :bordered="false">
<template slot="title">
C &nbsp;&nbsp;
<a-checkbox v-model="multiselect.c" value="C">答案</a-checkbox>
<a-checkbox value="C">答案</a-checkbox>
</template>
<a-textarea placeholder="" :rows="6" v-model="multiselect.answerC" style="width: 100%" />
</a-card>
<a-card :bordered="false">
<template slot="title">
D &nbsp;&nbsp;
<a-checkbox v-model="multiselect.d" value="D">答案</a-checkbox>
<a-checkbox value="D">答案</a-checkbox>
</template>
<a-textarea placeholder="" :rows="6" v-model="multiselect.answerD" style="width: 100%" />
</a-card>
<a-card :bordered="false">
<template slot="title">
E &nbsp;&nbsp;
<a-checkbox v-model="multiselect.E" value="E">答案</a-checkbox>
<a-checkbox value="E">答案</a-checkbox>
</template>
<a-textarea placeholder="" :rows="6" v-model="multiselect.answerE" style="width: 100%" />
</a-card>
<a-card :bordered="false">
<template slot="title">
F &nbsp;&nbsp;
<a-checkbox v-model="multiselect.F" value="F">答案</a-checkbox>
<a-checkbox value="F">答案</a-checkbox>
</template>
<a-textarea placeholder="" :rows="6" v-model="multiselect.answerF" style="width: 100%" />
</a-card>
</a-checkbox-group>
<a-card title="答案解析" :bordered="false">
<a-textarea placeholder="" :rows="6" v-model="multiselect.asnwerParse" style="width: 100%" />
</a-card>
@ -165,6 +167,7 @@ export default {
components: {},
data() {
return {
checkedValues:[],
radio: {},
multiselect: {},
estimate: {},
@ -189,6 +192,9 @@ export default {
this.radio.disabled = false
} else if (this.tabKey == '2') {
this.multiselect = res.data
console.log('c---------------s------------',this.multiselect)
if(this.multiselect.rightAnswers) this.checkedValues = this.multiselect.rightAnswers.split('')
console.log('arr',this.checkedValues)
this.multiselect.disabled = false
this.getRightAnswer()
} else if (this.tabKey == '3') {
@ -226,6 +232,12 @@ export default {
this.tabKey = key
},
//
onChange(checkedValues) {
console.log('checked = ', checkedValues);
this.checkedValues = checkedValues;
},
//
addAnswerSize() {
if (this.Completion.answerList.length == 5) {