|
@@ -72,6 +72,7 @@ public class YqPayController extends BaseController {
|
|
|
@PostMapping("/toPay")
|
|
|
@Transactional
|
|
|
public Object toPay(@ModelAttribute @Validated Order order) throws Exception {
|
|
|
+ logger.info(order.toString());
|
|
|
BigDecimal amount = new BigDecimal("0");
|
|
|
School school = schoolService.get(order.getClassId());
|
|
|
//计划招生人数有更新,更新
|
|
@@ -80,7 +81,7 @@ public class YqPayController extends BaseController {
|
|
|
//1、判断已报名人数
|
|
|
CourseGroupInfo courseGroupInfo = CourseGroupInfoService.get(order.getCourseId());
|
|
|
if (courseGroupInfo.getRegNum().compareTo(courseGroupInfo.getPlanNum()) >= 0) {
|
|
|
- Integer nums = orderService.getPayingOrderNums();
|
|
|
+ Integer nums = orderService.getPayingOrderNums(order.getGroupId());
|
|
|
return failed(HttpStatus.FORBIDDEN, "当前排队人数" + nums + "人,请您耐心等待");
|
|
|
}
|
|
|
|