Compare commits

..

No commits in common. "e95e90e6ad40582127b0a256a83afc00aa034d98" and "844bf0b2b1dae0a3427d14dd4b63705b99113445" have entirely different histories.

3 changed files with 19 additions and 19 deletions

View File

@ -65,16 +65,14 @@ public class RechargeOrderController {
@PutMapping("/update")
@Operation(summary = "更新订单")
@TenantIgnore
@PreAuthorize("@ss.hasPermission('shop:recharge-order:update')")
public CommonResult<Boolean> updateRechargeOrder(@Valid @RequestBody RechargeOrderUpdateReqVO updateReqVO) {
rechargeOrderService.updateRechargeOrder(updateReqVO);
return success(true);
}
@PostMapping("/updateByIds")
@PutMapping("/updateByIds")
@Operation(summary = "批量更新订单状态")
@TenantIgnore
public CommonResult<Boolean> updateByIds(@Valid @RequestBody BatchOrderUpdateReqVO updateReqVO) {
rechargeOrderService.updateByIds(updateReqVO);
return success(true);

View File

@ -2,23 +2,19 @@ package cn.iocoder.yudao.module.shop.service.recharge;
import cn.hutool.core.date.LocalDateTimeUtil;
import cn.hutool.core.util.NumberUtil;
import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.security.core.LoginUser;
import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils;
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
import cn.iocoder.yudao.module.member.api.user.MemberUserApi;
import cn.iocoder.yudao.module.member.api.user.dto.AppUserInfoReqDTO;
import cn.iocoder.yudao.module.member.api.user.dto.MemberUserRespDTO;
import cn.iocoder.yudao.module.shop.controller.admin.recharge.vo.*;
import cn.iocoder.yudao.module.shop.controller.app.member.vo.PromoterMemberOrderVO;
import cn.iocoder.yudao.module.shop.controller.app.member.vo.ShoppingMemberOrderVO;
import cn.iocoder.yudao.module.shop.convert.recharge.RechargeOrderConvert;
import cn.iocoder.yudao.module.shop.dal.dataobject.recharge.RechargeOrderDO;
import cn.iocoder.yudao.module.shop.dal.dataobject.recharge.RechargeOrderInfoDO;
import cn.iocoder.yudao.module.shop.dal.mysql.order.StoreOrderMapper;
import cn.iocoder.yudao.module.shop.dal.mysql.recharge.RechargeOrderInfoMapper;
import cn.iocoder.yudao.module.shop.dal.mysql.recharge.RechargeOrderMapper;
import cn.iocoder.yudao.module.shop.request.member.MemberChangeTieRequest;
import cn.iocoder.yudao.module.shop.request.member.RefundRequest;
import cn.iocoder.yudao.module.shop.response.member.MemberHeadResponse;
import cn.iocoder.yudao.module.system.api.tenant.TenantApi;
import cn.iocoder.yudao.module.system.api.tenant.dto.TenantDTO;
@ -27,23 +23,32 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import org.springframework.util.Assert;
import org.springframework.util.CollectionUtils;
import org.springframework.validation.annotation.Validated;
import javax.annotation.Resource;
import java.math.BigDecimal;
import java.time.DayOfWeek;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.time.temporal.TemporalAdjusters;
import java.util.Collection;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.*;
import java.util.stream.Collectors;
import cn.iocoder.yudao.module.shop.controller.admin.recharge.vo.*;
import cn.iocoder.yudao.module.shop.dal.dataobject.recharge.RechargeOrderDO;
import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.module.shop.convert.recharge.RechargeOrderConvert;
import cn.iocoder.yudao.module.shop.dal.mysql.recharge.RechargeOrderMapper;
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
import static cn.iocoder.yudao.module.shop.enums.ErrorCodeConstants.RECHARGE_ORDER_NOT_EXISTS;
import static cn.iocoder.yudao.module.shop.enums.ErrorCodeConstants.*;
import static java.util.stream.Collectors.toMap;
/**
* Service
@ -140,9 +145,8 @@ public class RechargeOrderServiceImpl implements RechargeOrderService {
orderDOS.forEach(e -> {
e.setStatus(updateReqVO.getStatus());
});
rechargeOrderMapper.updateBatch(orderDOS, orderDOS.size());
}
return Boolean.TRUE;
return null;
}
@Override

View File

@ -264,9 +264,7 @@
<if test="data.promoterId !=null ">
and a.promoter_id =#{data.promoterId}
</if>
<if test="data.status !=null ">
and a.status =#{data.status}
</if>
</where>
</sql>
</mapper>