Pu Zhibing
2025-02-10 b9a9d7dbe0ff19813877fb9d6a0533d22ed228ee
修改bug
2个文件已修改
29 ■■■■■ 已修改文件
cloud-server-competition/src/main/java/com/dsh/competition/controller/ParticipantController.java 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-competition/src/main/java/com/dsh/competition/controller/ParticipantController.java
@@ -120,16 +120,11 @@
            if (null == uid) {
                return ResultUtil.tokenErr();
            }
            int numDigits = String.valueOf(editParticipant.getId()).length();
            if (numDigits == 9) {
            if (null != editParticipant.getIsStudent() && 0 == editParticipant.getIsStudent()) {
                Participant byId = participantService.getById(editParticipant.getId());
                editParticipant.setName(byId.getName());
                return participantService.editParticipant(uid, editParticipant);
            } else {
                TStudent student = new TStudent();
                student.setId(editParticipant.getId());
@@ -149,8 +144,6 @@
                        return ResultUtil.error("身份证和姓名不匹配");
                    }
                }
                student.setPhone(editParticipant.getPhone());
                studentClient.updateAppUser(student);
                return ResultUtil.success();
cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java
@@ -681,16 +681,18 @@
    public void moneyOut() throws AlipayApiException {
        Date date = new Date();
        List<Competition> list = competitionService.list(new QueryWrapper<Competition>().lt("endTime",date).ne("isOut",1));
        List<Integer> coms = new ArrayList<>();
        for (Competition competition : list) {
            coms.add(competition.getId());
            competition.setIsOut(1);
        if(list.size() > 0){
            List<Integer> coms = new ArrayList<>();
            for (Competition competition : list) {
                coms.add(competition.getId());
                competition.setIsOut(1);
            }
            List<PaymentCompetition> pays = paymentCompetitionService.list(new QueryWrapper<PaymentCompetition>().in("competitionId", coms));
            for (PaymentCompetition pay : pays) {
                moneyOut(pay.getPayOrderNo(),pay.getPayOrderNo(),pay.getCode());
            }
            competitionService.updateBatchById(list);
        }
        List<PaymentCompetition> pays = paymentCompetitionService.list(new QueryWrapper<PaymentCompetition>().in("competitionId", coms));
        for (PaymentCompetition pay : pays) {
            moneyOut(pay.getPayOrderNo(),pay.getPayOrderNo(),pay.getCode());
        }
        competitionService.updateBatchById(list);
    }