diff --git a/pages/apply/subPages/SE/1trainNotifyShow.vue b/pages/apply/subPages/SE/1trainNotifyShow.vue index 8c84fd0..3b521db 100644 --- a/pages/apply/subPages/SE/1trainNotifyShow.vue +++ b/pages/apply/subPages/SE/1trainNotifyShow.vue @@ -9,6 +9,10 @@ + + + diff --git a/pages/apply/subPages/SE/2trainRecordShow.vue b/pages/apply/subPages/SE/2trainRecordShow.vue index 2f37cd3..f245551 100644 --- a/pages/apply/subPages/SE/2trainRecordShow.vue +++ b/pages/apply/subPages/SE/2trainRecordShow.vue @@ -9,6 +9,10 @@ + + + diff --git a/pages/apply/subPages/SE/7answerPageEdit.vue b/pages/apply/subPages/SE/7answerPageEdit.vue index 9f484d5..2022524 100644 --- a/pages/apply/subPages/SE/7answerPageEdit.vue +++ b/pages/apply/subPages/SE/7answerPageEdit.vue @@ -44,7 +44,7 @@ - + @@ -73,25 +73,41 @@ {{(index+1)+'. '+ item.Nav_Test.NAME+getType(item.Nav_Test.TYPE)}} - - - --> + + + + + + + + + @change="checkboxChange($event,item,item.ID)" placement="column"> + v-for="(item3, index3) in radiolist2[item.ID]" :key="item3.name" + :label="item3.name" :name="item3.value" :disabled="readonly"> @@ -121,7 +137,8 @@ extendRule, guid, initFilter, - initFilterGroup + initFilterGroup, + getSelectedOptions } from '../../../../utils/common' import { getRequest, @@ -147,10 +164,12 @@ tableKey: '0', radiolist1: [{ name: '正确', + value: 1, disabled: false }, { name: '错误', + value: 2, disabled: false }, ], @@ -228,6 +247,8 @@ extendInclude(json, 'Nav_User'); getRequest(json, "/SE/SETrainRecord/GetUserPapers").then(res => { this.model = res + + if (res && res.Nav_Papers && res.Nav_Papers.length > 0) { let papers = res.Nav_Papers.sort((a, b) => { return a.Nav_Test.TYPE - b.Nav_Test.TYPE @@ -243,24 +264,32 @@ } this.papers = papers; this.papers.forEach(item => { + if (item.Nav_Test.TYPE == 2) { + item.ANSWER3 = getSelectedOptions(item.ANSWER) + } let test = {} if (item.Nav_Test.TYPE != 0) { this.radiolist2[item.ID] = []; this.radiolist2[item.ID].push({ - name: item.Nav_Test.OPTION_A + name: item.Nav_Test.OPTION_A, + value: 1 }, { - name: item.Nav_Test.OPTION_B + name: item.Nav_Test.OPTION_B, + value: 2 }, { - name: item.Nav_Test.OPTION_C + name: item.Nav_Test.OPTION_C, + value: 4 }, ) if (item.Nav_Test.OPTION_D != undefined && item.Nav_Test.OPTION_D != "") { this.radiolist2[item.ID].push({ - name: item.Nav_Test.OPTION_D + name: item.Nav_Test.OPTION_D, + value: 8 }) } if (item.Nav_Test.OPTION_E != undefined && item.Nav_Test.OPTION_E != "") { this.radiolist2[item.ID].push({ - name: item.Nav_Test.OPTION_E + name: item.Nav_Test.OPTION_E, + value: 16 }) } } @@ -386,8 +415,8 @@ item.ANSWER = 16; } }, - checkboxChange(arr, item) { - let indexArr = this.findCommonElementsIndices(arr, this.radiolist2[item.ID]) + checkboxChange(arr, item,itemID) { + let indexArr = this.findCommonElementsIndices(arr, this.radiolist2[itemID])//item.ID item.ANSWER3 = arr; item.ANSWER = 0; indexArr.forEach(index => { @@ -408,8 +437,9 @@ const commonElements = []; for (let i = 0; i < arr1.length; i++) { for (let j = 0; j < arr2.length; j++) { - if (arr1[i] === arr2[j].name) { + if (arr1[i] === arr2[j].value) {//name commonElements.push(j); + break } } }