Commit 8a48f546 authored by honghy's avatar honghy

bug335 NG2419441L显示放货数量不对

parent 413af5c7
......@@ -1152,11 +1152,7 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
orderCargoControlPickDO.setPickVolume(orderCargoControlPickDO.getPickVolume().multiply(ratio).setScale(2, RoundingMode.UP));
}
orderCargoControlPickMapper.updateById(orderCargoControlPickDO);
Long count = orderCargoControlPickMapper.selectCount(new LambdaQueryWrapper<OrderCargoControlPickDO>()
.eq(OrderCargoControlPickDO::getOrderId, orderCargoControlPickDO.getOrderId())
.in(OrderCargoControlPickDO::getStatus, 1, 2, 3, 4, 5, 6)
.gt(OrderCargoControlPickDO::getPickNum, 0)
.eq(OrderCargoControlPickDO::getDeleted, false));
Long count = orderCargoControlPickMapper.selectSumByOrderId(orderCargoControlPickDO.getOrderId());
// 避免并发修改,这里只对订单的控货状态进行修改
if (count == 0) {
orderService.update(new LambdaUpdateWrapper<OrderDO>()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment