Joburgess 5 anni fa
parent
commit
126740c099

+ 3 - 3
mec-biz/src/main/java/com/ym/mec/biz/service/impl/VipGroupServiceImpl.java

@@ -1117,9 +1117,11 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
 			throw new BizException("课程信息错误");
 		}
 
+		Date date=new Date();
+
         VipGroup vipGroup = vipGroupDao.get(vipGroupBuyParams.getVipGroupId());
 
-		if(vipGroup.getStatus()!=VipGroupStatusEnum.APPLYING){
+		if(vipGroup.getPaymentExpireDate().before(date)){
 			throw new BizException("该课程已结束报名!");
 		}
 
@@ -1157,8 +1159,6 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
 			}
 		}
 
-		Date date=new Date();
-
 		List<CourseSchedule> courseSchedules = JSON.parseArray(vipGroup.getCourseSchedulesJson(),CourseSchedule.class);
 		courseScheduleService.checkNewCourseSchedules(courseSchedules,false);