修改问卷查看

This commit is contained in:
shidongli 2024-12-20 10:04:00 +08:00
parent 367e4b9fe3
commit 35ee7b8bfe

View File

@ -575,10 +575,12 @@ export default {
e.questionType == "COMBINATION_SCORING_SUBJECT"
) {
if(e.whetherScore==true){
e.whetherScore = "1";
}else{
e.whetherScore = "0";
e.whetherScore = 1;
}else if(e.whetherScore==false){
e.whetherScore = 0;
}
}else{
e.whetherScore = 0;
}
e.questionSubjectOptionList.forEach((el) => {
el.questionNumber = e.questionNumber;
@ -602,7 +604,7 @@ export default {
this.$delete(this.questiondata, "updateTime");
var score = 0;
//
var lengthScore=this.questiondata.questionSubjectList.filter(f=> f.whetherScore == '0')
var lengthScore=this.questiondata.questionSubjectList.filter(f=> f.whetherScore == 0)
this.questiondata.questionSubjectList.forEach((e) => {
if (e.questionSubjectOptionList?.length > 0) {
e.questionSubjectOptionList.forEach((el) => {
@ -614,7 +616,7 @@ export default {
e.questionType == "COMBINATION_MULTIPLE_SUBJECT" ||
e.questionType == "COMBINATION_SCORING_SUBJECT"
) {
if (el.optionChooseSign == "0" && e.whetherScore == '1') {
if (el.optionChooseSign == "0" && e.whetherScore == 1) {
score += el.optionScore;
}
}