|
|
|
@ -74,16 +74,8 @@ |
|
|
|
|
</el-checkbox-group> |
|
|
|
|
</template> |
|
|
|
|
<template v-if="item.name == '简答题'"> |
|
|
|
|
<el-upload |
|
|
|
|
class="upload" |
|
|
|
|
:before-upload="file => beforeUpload(file,item)" |
|
|
|
|
:on-remove="(file, fileList) => handleRemove(file, fileList, item)" |
|
|
|
|
:on-error="uploadError" |
|
|
|
|
:on-success="(res, file, fileList) => uploadSuccess(res, file, fileList, item)" |
|
|
|
|
:before-remove="beforeRemove" |
|
|
|
|
:on-exceed="handleExceed" |
|
|
|
|
:action="api.fileupload" |
|
|
|
|
> |
|
|
|
|
<el-upload class="upload" :before-upload="file => beforeUpload(file,item)" :on-remove="(file, fileList) => handleRemove(file, fileList, item)" |
|
|
|
|
:on-error="uploadError" :on-success="(res, file, fileList) => uploadSuccess(res, file, fileList, item)" :before-remove="beforeRemove" :on-exceed="handleExceed" :action="api.fileupload"> |
|
|
|
|
<el-button type="primary" class="ml20">上传文件</el-button> |
|
|
|
|
</el-upload> |
|
|
|
|
<el-input type="textarea" rows="5" resize="none" v-model="item.val" @input="updateProgress"></el-input> |
|
|
|
@ -182,7 +174,7 @@ export default { |
|
|
|
|
this.judgeScore = data.list4.length ? data.list4[0].judgeScore : 0 |
|
|
|
|
this.fillBlanksScore = data.list3.length ? data.list3[0].fillBlanksScore : 0 |
|
|
|
|
this.briefAnswerScore = data.list5.length ? data.list5[0].briefAnswerScore : 0 |
|
|
|
|
this.scoreList = [this.singlePoint,this.multipleChoiceScore,this.fillBlanksScore,this.briefAnswerScore,this.briefAnswerScore] |
|
|
|
|
this.scoreList = [this.singlePoint * this.singleCount,this.multipleChoiceScore * this.multipleCount,this.judgeScore * this.judgeCount,this.fillBlanksScore * this.fillBlankCount,this.briefAnswerScore * this.briefAnswerCount] |
|
|
|
|
|
|
|
|
|
window.updateProgress = (item) => { |
|
|
|
|
this.updateProgress(item,1) |
|
|
|
@ -251,7 +243,7 @@ export default { |
|
|
|
|
}else if(i == 3){ |
|
|
|
|
let answer = answered.user_answer.split('<>'); |
|
|
|
|
[...document.querySelectorAll(`.stem${i}${k} input`)].map((n,j) => { |
|
|
|
|
n.value = answer[j] |
|
|
|
|
if(answer[j]) n.value = answer[j] |
|
|
|
|
}) |
|
|
|
|
n.val = answered.user_answer |
|
|
|
|
if(answer.filter(n => n).length) n.hadAnswer = 1 |
|
|
|
@ -388,9 +380,7 @@ export default { |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
this.$post(`${this.api.addPractiseExamAnswerDetails}`,data1) |
|
|
|
|
.then(res => {}) |
|
|
|
|
.catch(err => {}) |
|
|
|
|
this.$post(`${this.api.addPractiseExamAnswerDetails}`,data1).then(res => {}).catch(err => {}) |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|