称重打包费问题
退款原因
This commit is contained in:
@@ -62,6 +62,9 @@ public class ProductRpcServiceImpl implements ProductRpcService {
|
||||
}
|
||||
for (ProductStockSubtractDTO dto : list) {
|
||||
Product product = productMapper.selectOneById(dto.getProductId());
|
||||
if (product == null) {
|
||||
continue;
|
||||
}
|
||||
productMapper.updateProductStockNum(dto.getProductId(), dto.getShopId(), "sub", dto.getNum());
|
||||
// 记录商品库存流水
|
||||
ProductStockFlow flow = new ProductStockFlow();
|
||||
@@ -119,9 +122,7 @@ public class ProductRpcServiceImpl implements ProductRpcService {
|
||||
consStockFlowMapper.insert(consStockFlow);
|
||||
}
|
||||
}
|
||||
ThreadUtil.execAsync(() -> {
|
||||
rabbitPublisher.sendProductInfoChangeMsg(Convert.toStr(shopId));
|
||||
});
|
||||
ThreadUtil.execAsync(() -> rabbitPublisher.sendProductInfoChangeMsg(Convert.toStr(shopId)));
|
||||
log.info("ProductService.--------------------------------------------库存更新成功");
|
||||
}
|
||||
|
||||
@@ -191,9 +192,7 @@ public class ProductRpcServiceImpl implements ProductRpcService {
|
||||
consStockFlowMapper.insert(consStockFlow);
|
||||
}
|
||||
}
|
||||
ThreadUtil.execAsync(() -> {
|
||||
rabbitPublisher.sendProductInfoChangeMsg(Convert.toStr(shopId));
|
||||
});
|
||||
ThreadUtil.execAsync(() -> rabbitPublisher.sendProductInfoChangeMsg(Convert.toStr(shopId)));
|
||||
log.info("ProductService.--------------------------------------------库存更新成功");
|
||||
}
|
||||
|
||||
@@ -266,9 +265,7 @@ public class ProductRpcServiceImpl implements ProductRpcService {
|
||||
consStockFlowMapper.insert(consStockFlow);
|
||||
}
|
||||
}
|
||||
ThreadUtil.execAsync(() -> {
|
||||
rabbitPublisher.sendProductInfoChangeMsg(Convert.toStr(shopId));
|
||||
});
|
||||
ThreadUtil.execAsync(() -> rabbitPublisher.sendProductInfoChangeMsg(Convert.toStr(shopId)));
|
||||
log.info("ProductService.--------------------------------------------库存更新成功");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user