|
|
|
@ -472,6 +472,7 @@ public class ProOrderServiceImpl implements IProOrderService {
|
|
|
|
|
ProOrder orderExit = proOrderMapper.selectProOrderByOrderCode(proOrder.getOrderCode());
|
|
|
|
|
if (orderExit==null) {//不存在就插入
|
|
|
|
|
proOrder.setId(IdUtils.fastSimpleUUID());
|
|
|
|
|
proOrder.setCreateTime(nowDate);
|
|
|
|
|
proOrderMapper.insertProOrder(proOrder);
|
|
|
|
|
logger.info("=======订单"+proOrder.getOrderCode()+"同步成功");
|
|
|
|
|
} else {//存在,如果没活动更新,否则不允许更新,关闭订单
|
|
|
|
@ -493,7 +494,7 @@ public class ProOrderServiceImpl implements IProOrderService {
|
|
|
|
|
//删除批次pro_order_workorder_batch
|
|
|
|
|
proOrderWorkorderBatchMapper.deleteProOrderWorkorderBatchByWorkorderIds(ids);
|
|
|
|
|
//删除工单pro_order_workorder
|
|
|
|
|
proOrderWorkorderMapper.deleteProOrderWorkorderByWorkorderIds(ids);
|
|
|
|
|
proOrderWorkorderMapper.deleteProOrderWorkorderByOrderIds(ids);
|
|
|
|
|
}
|
|
|
|
|
logger.info("=======订单"+proOrder.getOrderCode()+"同步成功");
|
|
|
|
|
}else{
|
|
|
|
@ -547,7 +548,6 @@ public class ProOrderServiceImpl implements IProOrderService {
|
|
|
|
|
order.setPlanFactoryCode(factoryCode);
|
|
|
|
|
order.setFactoryCode(factoryCode);
|
|
|
|
|
order.setCreateBy(SecurityUtils.getUsername());
|
|
|
|
|
order.setCreateTime(DateUtils.getNowDate());
|
|
|
|
|
order.setOrderType("LJ01");
|
|
|
|
|
order.setProdType("prod");
|
|
|
|
|
order.setStatus("o0");
|
|
|
|
|