diff --git a/src/pages/achievement/ass/index.vue b/src/pages/achievement/ass/index.vue index 065626c..63a19de 100644 --- a/src/pages/achievement/ass/index.vue +++ b/src/pages/achievement/ass/index.vue @@ -154,7 +154,9 @@ export default { this.avg = res.avgScore this.total = res.peopleNum let list = res.page.records; - this.assessmentId = res.page.records[0].assessmentId; + if (res.page.records.length){ + this.assessmentId = res.page.records[0].assessmentId; + } let score = 0; list.map(n => { n.class = this.className; @@ -218,9 +220,8 @@ export default { type: "warning" }) .then(() => { - let ids = this.multipleSelection.map(item => { - return item.reportId; - }); + let ids = [row.reportId] + console.log(ids) this.$post(`${this.api.deleteExperimentalReport}`,ids).then(res => { util.successMsg("删除成功"); this.getData(); @@ -237,7 +238,7 @@ export default { return `reportId=${item.reportId}`; }); let delList1 = newArr.map(item => { - return `recordId=${item.recordId}`; + return `recordId=${item.reportId}`; }); this.$confirm("确定要删除吗?", "提示", { type: "warning"