Merge remote-tracking branch 'origin/prod' into prod
This commit is contained in:
@@ -36,7 +36,7 @@ public class UMemberPointsController {
|
||||
*/
|
||||
@GetMapping("pointsBasicSetting")
|
||||
public CzgResult<PointsBasicSettingDTO> getPointsBasicSetting() {
|
||||
Long shopId = StpKit.USER.getShopId(0L);
|
||||
Long shopId = StpKit.USER.getShopId();
|
||||
PointsBasicSetting entity = pointsBasicSettingService.getById(shopId);
|
||||
PointsBasicSettingDTO data = BeanUtil.copyProperties(entity, PointsBasicSettingDTO.class);
|
||||
return CzgResult.success(data);
|
||||
|
||||
@@ -97,7 +97,7 @@ public class MemberPointsServiceImpl extends ServiceImpl<MemberPointsMapper, Mem
|
||||
@Override
|
||||
public OrderDeductionPointsDTO getMemberUsablePoints(Long shopUserId, BigDecimal orderAmount) {
|
||||
MemberPoints entity = initMemberPoints(shopUserId);
|
||||
Long shopId = entity.getSourceShopId();
|
||||
Long shopId = entity.getMainShopId();
|
||||
Integer accountPoints = entity.getAccountPoints();
|
||||
OrderDeductionPointsDTO dto = new OrderDeductionPointsDTO();
|
||||
dto.setAccountPoints(accountPoints);
|
||||
|
||||
@@ -363,7 +363,8 @@ public class OrderInfoServiceImpl extends ServiceImpl<OrderInfoMapper, OrderInfo
|
||||
param.getPointsDiscountAmount().compareTo(BigDecimal.ZERO) > 0);
|
||||
}
|
||||
// 积分校验
|
||||
PointsBasicSetting pointSetting = pointsBasicService.getById(shopId);
|
||||
Long mainShopId = shopInfoService.getMainIdByShopId(shopId);
|
||||
PointsBasicSetting pointSetting = pointsBasicService.getById(mainShopId);
|
||||
boolean usePointsDeduction = param.getPointsNum() > 0 || param.getPointsDiscountAmount().compareTo(BigDecimal.ZERO) > 0;
|
||||
if (usePointsDeduction) {
|
||||
if (pointSetting == null || !pointSetting.getEnableDeduction().equals(1)) {
|
||||
|
||||
Reference in New Issue
Block a user