...
|
...
|
@@ -498,9 +498,12 @@ public class CutDownPriceServiceImpl implements ICutDownPriceService { |
|
|
logger.warn(" the cutdown product not exist, activityId is {}, productSkn is {}", activityId, productSkn);
|
|
|
throw new ServiceException(ServiceError.ACTIVITY_CUTDOWNPRICE_PRODUCT_NOTEXIST_ERROR);
|
|
|
}
|
|
|
// 查询该用户是否已经发起过(之前发起过,没砍价成功,发起时间超过24小时)
|
|
|
// 查询该用户是否已经发起过
|
|
|
// (之前发起过,没砍价成功,发起时间超过24小时,可以重新发起)
|
|
|
// 之前发起过,砍价成功了,但是24小时没付款失效了,就不能再重新发起了
|
|
|
CutDownPriceUserRecord recordDb = cutDownPriceUserRecordMapper.selectCutDownPriceUserRecord(userId, activityId, productSkn);
|
|
|
if(recordDb!=null && (recordDb.getHelpCount()>=cutDownPriceProductBo.getJoinNum()+1 || (DateUtils.getCurrentTimeSecond() - recordDb.getCreateTime() < TIME_24_HOUR))){
|
|
|
if(recordDb!=null &&
|
|
|
(recordDb.getHelpCount()>=cutDownPriceProductBo.getJoinNum()+1 || (DateUtils.getCurrentTimeSecond() - recordDb.getCreateTime() < TIME_24_HOUR))){
|
|
|
logger.warn(" the cutdown record has exist, userId is {}, activityId is {}, productSkn is {}", userId, activityId, productSkn);
|
|
|
throw new ServiceException(ServiceError.ACTIVITY_CUTDOWNPRICE_YOU_HAS_CREATE_CUTDOWN_ERROR);
|
|
|
}
|
...
|
...
|
|