| | |
| | | String transaction_id = map.get("transaction_id"); |
| | | String result = map.get("result"); |
| | | |
| | | PaymentCompetition paymentCompetition = paymentCompetitionService.getOne(new QueryWrapper<PaymentCompetition>().eq("code", code) |
| | | .eq("payType", 1)); |
| | | PaymentCompetition paymentCompetition = paymentCompetitionService.getOne(new QueryWrapper<PaymentCompetition>().eq("code", code).eq("payType", 1)); |
| | | if (paymentCompetition.getPayStatus() == 1) { |
| | | paymentCompetition.setAppUserId(null); |
| | | paymentCompetition.setPayStatus(2); |
| | | paymentCompetition.setPayTime(new Date()); |
| | | paymentCompetition.setPayOrderNo(transaction_id); |
| | | paymentCompetitionService.updateById(paymentCompetition); |
| | | |
| | | Competition competition = cttService.getById(paymentCompetition.getCompetitionId()); |
| | | competition.setApplicantsNumber(competition.getApplicantsNumber() + 1); |
| | | cttService.updateById(competition); |
| | | } |
| | | |
| | | PrintWriter out = response.getWriter(); |
| | | out.write(result); |
| | | out.flush(); |