|
|
|
@ -63,8 +63,8 @@ |
|
|
|
|
</li> |
|
|
|
|
<li> |
|
|
|
|
<label>学生班级:</label> |
|
|
|
|
<el-input v-if="editing" v-model="infoData.workNumber"></el-input> |
|
|
|
|
<span v-else>{{ infoData.workNumber }}</span> |
|
|
|
|
<el-input v-if="editing" v-model="infoData.className"></el-input> |
|
|
|
|
<span v-else>{{ infoData.className }}</span> |
|
|
|
|
</li> |
|
|
|
|
<li> |
|
|
|
|
<label>指导老师:</label> |
|
|
|
@ -197,9 +197,22 @@ export default { |
|
|
|
|
getData() { // 查询详情 |
|
|
|
|
this.$get(`${this.api.reportDetail}?reportId=${this.reportId}`).then(res => { |
|
|
|
|
this.form = res.report |
|
|
|
|
this.expData = res.userScores |
|
|
|
|
this.project = this.expData.find(e => e.lcRuleRecords) // 银行系统才有lcRuleRecords |
|
|
|
|
let form = this.form; |
|
|
|
|
const list = res.userScores |
|
|
|
|
this.project = list.find(e => e.lcRuleRecords) // 银行系统才有lcRuleRecords |
|
|
|
|
let form = this.form |
|
|
|
|
form.className = this.className |
|
|
|
|
if (this.project) { |
|
|
|
|
list.map(e => { |
|
|
|
|
e.assessmentPoint = '' |
|
|
|
|
e.referenceAnswer = '' |
|
|
|
|
e.answer = '' |
|
|
|
|
e.lcRuleRecords.map((n, i) => { |
|
|
|
|
e.assessmentPoint += `${i + 1}.${n.name}` |
|
|
|
|
e.referenceAnswer += `${i + 1}.${n.ruleAnswer}` |
|
|
|
|
e.answer += `${i + 1}.${n.userAnswer}` |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
this.infoData = { |
|
|
|
|
workNumber: form.workNumber, |
|
|
|
|
experimentalClassName: form.experimentalClassName, |
|
|
|
@ -210,6 +223,7 @@ export default { |
|
|
|
|
score: form.score, |
|
|
|
|
userName: form.userName |
|
|
|
|
} |
|
|
|
|
this.expData = list |
|
|
|
|
form.assessmentId && (this.breadPath = ['实验记录', '实验报告']) |
|
|
|
|
}).catch(res => {}) |
|
|
|
|
}, |
|
|
|
@ -225,7 +239,7 @@ export default { |
|
|
|
|
if (form[i] && typeof form[i] === 'string') form[i] = form[i].replace(/<[^>]+>/g, '') |
|
|
|
|
} |
|
|
|
|
form.purpose = form.purpose.replace(/<[^>]+>/g, '') |
|
|
|
|
this.$post(this.api.exportLabReport, { |
|
|
|
|
this.$post(this.project ? this.api.exportBankExperimentReport : this.api.exportLabReport, { |
|
|
|
|
...form, |
|
|
|
|
experimentalData: list |
|
|
|
|
}).then(res => { |
|
|
|
|