init
This commit is contained in:
@@ -277,7 +277,10 @@ public class ActivityShopServiceImpl extends ServiceImpl<ActivityShopMapper,Acti
|
||||
String code = codeKit.nextCodeActivity();
|
||||
bo.setActivityCode(code);
|
||||
if(bo.getStartTime().isAfter(bo.getEndTime())){
|
||||
throw new ServiceException("开始时间不能大于结束时间");
|
||||
throw new ServiceException("报名开始时间不能大于报名结束时间");
|
||||
}
|
||||
if(bo.getActivityStartTime().isAfter(bo.getActivityEndTime())){
|
||||
throw new ServiceException("活动开始时间不能大于活动结束时间");
|
||||
}
|
||||
AreaCode areaCode = areaCodeService.getById(bo.getCityCode());
|
||||
bo.setCityName(areaCode.getName());
|
||||
@@ -287,7 +290,10 @@ public class ActivityShopServiceImpl extends ServiceImpl<ActivityShopMapper,Acti
|
||||
@Override
|
||||
public void updateData(ActivityShopAdminUpdateReq bo) {
|
||||
if(bo.getStartTime().isAfter(bo.getEndTime())){
|
||||
throw new ServiceException("开始时间不能大于结束时间");
|
||||
throw new ServiceException("报名开始时间不能大于报名结束时间");
|
||||
}
|
||||
if(bo.getActivityStartTime().isAfter(bo.getActivityEndTime())){
|
||||
throw new ServiceException("活动开始时间不能大于活动结束时间");
|
||||
}
|
||||
ActivityShop update = BeanConvertUtil.convertTo(bo, ActivityShop::new);
|
||||
AreaCode areaCode = areaCodeService.getById(bo.getCityCode());
|
||||
|
||||
Reference in New Issue
Block a user