|
|
|
@ -107,12 +107,12 @@ public class ActBannerServiceImpl extends BaseServiceImpl<ActBannerDao, ActBanne |
|
|
|
// 上架
|
|
|
|
if (ActStateConstant.ACT_BANNER_STATUS_UNDERCARRIAGE.equals(entity.getStatus())) { |
|
|
|
// 上架的banner数量不能超过5条
|
|
|
|
if (NumConstant.FIVE > baseDao.getBannerStatusNumber()) { |
|
|
|
// if (NumConstant.FIVE > baseDao.getBannerStatusNumber()) {
|
|
|
|
updateEntity.setStatus(ActStateConstant.ACT_BANNER_STATUS_GROUNDING); |
|
|
|
updateById(updateEntity); |
|
|
|
} else { |
|
|
|
return new Result().error("Banner上架数量不能超过5条"); |
|
|
|
} |
|
|
|
// } else {
|
|
|
|
// return new Result().error("Banner上架数量不能超过5条");
|
|
|
|
// }
|
|
|
|
// 下架
|
|
|
|
} else if (ActStateConstant.ACT_BANNER_STATUS_GROUNDING.equals(entity.getStatus())) { |
|
|
|
updateEntity.setStatus(ActStateConstant.ACT_BANNER_STATUS_UNDERCARRIAGE); |
|
|
|
|