|
@@ -486,8 +486,10 @@ public class WebsitSalesLogic {
|
|
|
|
|
|
if (bean.getGoodsType().equals(WebsitGoodsTypeEnum.M.toString())) {
|
|
if (bean.getGoodsType().equals(WebsitGoodsTypeEnum.M.toString())) {
|
|
final WorkerGoods workerGoods = workerGoodsService.getById(bean.getWorkerGoodsId());
|
|
final WorkerGoods workerGoods = workerGoodsService.getById(bean.getWorkerGoodsId());
|
|
- detail.setWorkerGoodsId(workerGoods.getStatus().equals(ESGoodsStatusEnum.ON.getKey()) ? bean.getWorkerGoodsId() : null);
|
|
|
|
- detail.setWorkerGoodsName(workerGoods.getStatus().equals(ESGoodsStatusEnum.ON.getKey()) ? bean.getWorkerGoodsName() : null);
|
|
|
|
|
|
+ if (Objects.nonNull(workerGoods)) {
|
|
|
|
+ detail.setWorkerGoodsId(workerGoods.getStatus().equals(ESGoodsStatusEnum.ON.getKey()) ? bean.getWorkerGoodsId() : null);
|
|
|
|
+ detail.setWorkerGoodsName(workerGoods.getStatus().equals(ESGoodsStatusEnum.ON.getKey()) ? bean.getWorkerGoodsName() : null);
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
detail.setOrigPartsPrice(bean.getOrigPartsPrice());
|
|
detail.setOrigPartsPrice(bean.getOrigPartsPrice());
|