From 16aa4fa86c45ad7b8e16ae66f787cdb783ba388a Mon Sep 17 00:00:00 2001 From: 44323 <443237572@qq.com> Date: 星期四, 21 三月 2024 14:14:10 +0800 Subject: [PATCH] bug修改 --- cloud-server-communityWorldCup/src/main/java/com/dsh/communityWorldCup/service/impl/WorldCupServiceImpl.java | 9 +++++++-- 1 files changed, 7 insertions(+), 2 deletions(-) diff --git a/cloud-server-communityWorldCup/src/main/java/com/dsh/communityWorldCup/service/impl/WorldCupServiceImpl.java b/cloud-server-communityWorldCup/src/main/java/com/dsh/communityWorldCup/service/impl/WorldCupServiceImpl.java index aa8c625..e753e6e 100644 --- a/cloud-server-communityWorldCup/src/main/java/com/dsh/communityWorldCup/service/impl/WorldCupServiceImpl.java +++ b/cloud-server-communityWorldCup/src/main/java/com/dsh/communityWorldCup/service/impl/WorldCupServiceImpl.java @@ -173,6 +173,7 @@ ids.add(worldCupCompetitor.getId()); //已参赛 if(0 == worldCupPaymentParticipant.getAlreadyEntered()){ + worldCupPaymentParticipant.setWorldCupId(null); worldCupPaymentParticipant.setAlreadyEntered(1); worldCupPaymentParticipantService.updateById(worldCupPaymentParticipant); } @@ -183,7 +184,7 @@ //2、调起开启游戏的接口。 HashMap<String, String> map = new HashMap<>(); map.put("sign", "0DB011836143EEE2C2E072967C9F4E4B"); - map.put("space_id", tGame.getStoreId() + ""); + map.put("space_id", tGame.getSiteId() + ""); map.put("red_sutu_id", tGame.getRed()); map.put("blue_sutu_id", tGame.getBlue()); map.put("api_url", "http://221.182.45.100:56666/communityWorldCup/base/worldCup/endWorldCupCallback"); @@ -593,7 +594,7 @@ List<CoursePackageOrderStudent> coursePackageOrderStudent = coursePackageOrderStudentClient.getCoursePackageOrderUser(paymentWorldCup.getUid()); int sum = coursePackageOrderStudent.stream().mapToInt(CoursePackageOrderStudent::getLaveClassHours).sum(); - if(sum < worldCup.getClassHour()){ + if(sum < worldCup.getClassHour() * num){ return ResultUtil.error("报名失败,课时不足,请续课!"); } @@ -840,6 +841,10 @@ } } + + WorldCup worldCup = this.getById(id); + worldCup.setStatus(4); + this.updateById(worldCup); } -- Gitblit v1.7.1