From 7bea692dfb693bcf68d6a662ec670b0957d7fcdc Mon Sep 17 00:00:00 2001
From: yujialong <479214531@qq.com>
Date: Mon, 3 Jun 2024 18:52:08 +0800
Subject: [PATCH] =?UTF-8?q?=E8=B5=9B=E4=BA=8B=E4=BF=AE=E5=A4=8D?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/index.js | 1 +
src/pages/match/details/index.vue | 23 +++++++++++++++--------
src/pages/record/show/index.vue | 2 +-
src/pages/station/preview/index.vue | 2 +-
4 files changed, 18 insertions(+), 10 deletions(-)
diff --git a/src/api/index.js b/src/api/index.js
index f60a4ab..3b0a54d 100644
--- a/src/api/index.js
+++ b/src/api/index.js
@@ -159,6 +159,7 @@ export default {
teamAssignmentButtonDisplay: `competition/competitionTeamAutomaticAllocationRecord/teamAssignmentButtonDisplay`,
assignedPlayer: `competition/competition/automaticAllocation/assignedPlayer`,
competitionTeamAutomaticAllocationRecordSave: `competition/competitionTeamAutomaticAllocationRecord/saveOrUpdate`,
+ whetherTheTeamHasReport: `competition/competitionAutomaticAllocationRecord/whetherTheTeamHasReport`,
// 创业活动
activityList: `occupationlab/occupationlab/activity/activityList`,
diff --git a/src/pages/match/details/index.vue b/src/pages/match/details/index.vue
index 836c5f0..c37f99e 100644
--- a/src/pages/match/details/index.vue
+++ b/src/pages/match/details/index.vue
@@ -260,9 +260,9 @@
竞赛阶段: |
- {{
- assignRecord.assignOrNot && status < 3 ? '取消' : '' }}自动分配阶段成员
+ assignRecord.assignOrNot && status < 3 ? '取消' : '' }}重新自动分配阶段成员
@@ -297,7 +297,7 @@
无
-
异常
@@ -654,6 +654,7 @@ export default {
teamErrors: [],
stageTip: null,
showButton: false,
+ hasReport: false,
assignRecord: {},
allocating: false,
};
@@ -911,7 +912,7 @@ export default {
teamId: this.info.teamId
})
this.teamErrors = res.teamTip.split(';').filter(e => e)
- if (Object.keys(res.stageTip)) {
+ if (Object.keys(res.stageTip).length) {
this.stageTip = res.stageTip
}
},
@@ -1143,9 +1144,14 @@ export default {
},
// 获取团队分配按钮展示与否
async getTeamAssign () {
- const res = await this.$post(`${this.api.teamAssignmentButtonDisplay}?competitionId=${this.id}&teamId=${this.info.teamId}`)
+ const param = `?competitionId=${this.id}&teamId=${this.info.teamId}`
+ const res = await this.$post(this.api.teamAssignmentButtonDisplay + param)
this.showButton = res.showButton // 自动分配按钮是否展示
this.assignRecord = res.teamRecord || {} // 展示成自动分配 or 取消分配
+
+ // 查询团队是否存在实验报告
+ const res1 = await this.$post(this.api.whetherTheTeamHasReport + param)
+ this.hasReport = res1.hasReport
this.allocating = false
},
// 移除参赛人员
@@ -1349,14 +1355,15 @@ export default {
const whether = this.assignRecord.assignOrNot && this.status < 3
const tips = this.status < 3 ?
whether ?
- '确定取消自动分配阶段成员?' :
- '是否要启用自动分配成员参加阶段赛项?启用后,将在报名结束后给团队成员自动分配阶段参赛人员。'
- : '确定立即自动分配阶段成员?'
+ '确定取消重新自动分配阶段成员?' :
+ '是否要启用重新自动分配成员参加阶段赛项? 启用后,将在报名结束后给团队成员自动分配阶段参赛人员。'
+ : '确定立即重新自动分配阶段成员?'
this.$confirm(tips, '提示', {
cancelButtonText: '否',
confirmButtonText: '是',
type: 'success',
closeOnClickModal: false,
+ dangerouslyUseHTMLString: true,
}).then(async () => {
this.allocating = true
// 报名结束之前则调修改接口,否则调自动分配接口
diff --git a/src/pages/record/show/index.vue b/src/pages/record/show/index.vue
index a433cd4..4ae55c8 100644
--- a/src/pages/record/show/index.vue
+++ b/src/pages/record/show/index.vue
@@ -275,7 +275,7 @@ export default {
}
})
e.lcStudentAnswer.map((n, i) => {
- e.answer += `${i + 1}.${n.userAnswer};`
+ e.answer += `${i + 1}.${n.userAnswer || '未填写'};`
})
})
} else { // python系统显示图片(从userScores里取)
diff --git a/src/pages/station/preview/index.vue b/src/pages/station/preview/index.vue
index 2ad7b80..6100b37 100644
--- a/src/pages/station/preview/index.vue
+++ b/src/pages/station/preview/index.vue
@@ -234,7 +234,7 @@
{{
item.showChildren ? '收起所有回复' :
- `查看所有${item.children.length}条回复`}}
+ `查看所有${item.children.length}条回复` }}
|