update:
1. update user-point
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
set amount = amount + #{amount} , version = version + 1
|
||||
where id = #{userId} and version = #{version}
|
||||
</update>
|
||||
|
||||
<update id="deductUserPoint">
|
||||
update
|
||||
user_point
|
||||
|
||||
@@ -38,8 +38,8 @@ public class CommonUserPointServiceImpl extends BaseServiceImpl<CommonUserPointM
|
||||
return page.setRecords(baseMapper.selectCommonUserPointPage(page, commonUserPoint));
|
||||
}
|
||||
|
||||
@Transactional(rollbackFor = RuntimeException.class)
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean addUserPoint(CommonUserPointApiDTO dto) {
|
||||
CommonUserPointLogEntity userPointLog = saveBenefitPointLog(dto, 1);
|
||||
CommonUserPointEntity userPoint = getById(dto.getUserId());
|
||||
@@ -103,7 +103,6 @@ public class CommonUserPointServiceImpl extends BaseServiceImpl<CommonUserPointM
|
||||
if (!userPointLogService.save(userPointLog)) {
|
||||
throw new RuntimeException("商城积分流水记录失败");
|
||||
}
|
||||
|
||||
return userPointLog;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user