diff --git a/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualcompetitionprojectregistration/controller/AnnualCompetitionProjectRegistrationController.java b/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualcompetitionprojectregistration/controller/AnnualCompetitionProjectRegistrationController.java index 67f0ec6f..dbc4d0f7 100644 --- a/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualcompetitionprojectregistration/controller/AnnualCompetitionProjectRegistrationController.java +++ b/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualcompetitionprojectregistration/controller/AnnualCompetitionProjectRegistrationController.java @@ -471,11 +471,19 @@ public class AnnualCompetitionProjectRegistrationController { //判断队伍人数是否合格 AnnualCompPoint compPoint = annualCompPointService.query().eq("id", info.getAnnualCompid()).one(); - if (managements.size() != compPoint.getTeamNumber()) - return Result.error("队伍人数要求" + compPoint.getTeamNumber() + "人,请重新组队"); - if (instructorSheetList.size() != compPoint.getTeacherNumber()) - return Result.error("老师人数要求" + compPoint.getTeacherNumber() + "人,请重新选择"); - + //只有是团队赛的时候才进行判断,个人赛值判断是不是自己一个人 + if (compPoint.getEntryForm().equals("Y")) { + if (managements.size() != compPoint.getTeamNumber()) + return Result.error("队伍人数要求" + compPoint.getTeamNumber() + "人,请重新组队"); + if (instructorSheetList.size() != compPoint.getTeacherNumber()) + return Result.error("老师人数要求" + compPoint.getTeacherNumber() + "人,请重新选择"); + } else if (compPoint.getEntryForm().equals("N")) { + if (managements.size() >1){ + return Result.error("个人赛只能一个人参加"); + } else if ( !managements.get(0).getUserId().equals(loginUser.getId())) { + return Result.error("你只能为你自己报名"); + } + } //判断队员是否已经参加这个比赛 int i = 1; for (TeamManagement management : managements) { diff --git a/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitPass.vue b/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitPass.vue index 3d1e7f01..94d8d398 100644 --- a/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitPass.vue +++ b/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitPass.vue @@ -12,25 +12,25 @@ diff --git a/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitReject.vue b/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitReject.vue index 702a9f99..79963da0 100644 --- a/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitReject.vue +++ b/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListAwaitReject.vue @@ -12,25 +12,25 @@ diff --git a/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListPass.vue b/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListPass.vue index 7e8bb45b..a144a693 100644 --- a/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListPass.vue +++ b/jeecgboot-vue3-master/src/views/annualCompPoint/superAdmin/AnnualCompPointListPass.vue @@ -12,25 +12,25 @@ @@ -276,13 +276,13 @@ function getTableAction(record) { { label: '详情', onClick: handleDetail.bind(null, record), - }, { + }, /*{ label: '删除', popConfirm: { title: '是否确认删除', confirm: handleDelete.bind(null, record), } - }, + },*/ ]; return actions; }