白坯订单管理

highway
wws 1 year ago
parent 1f0fd5b808
commit 343bac2b82

@ -173,7 +173,9 @@ public class ProOrderServiceImpl implements IProOrderService {
ProOrderWorkorderBatch proOrderWorkorderBatch = setCommonBatchAttribute();
// 设置工单
proOrderWorkorder.setWorkorderId(IdUtils.fastSimpleUUID());
proOrderWorkorder.setWorkorderCode(proOrder.getOrderCode()+"-1");
// 设置工单code
int endCode = getEndCode(proOrder.getId());
proOrderWorkorder.setWorkorderCode(proOrder.getOrderCode()+"-"+endCode);
proOrderWorkorder.setOrderId(proOrder.getId());
proOrderWorkorder.setOrderCode(proOrder.getOrderCode());
proOrderWorkorder.setUnit(proOrder.getUnit());

@ -88,6 +88,7 @@ public class ProWhiteOrderServiceImpl implements IProWhiteOrderService {
int num = 1;
// 创建主订单
proOrder.setPlanFactoryCode(factory);
proOrder.setFactoryCode(factory);
proOrder.setId(IdUtils.fastSimpleUUID());
proOrder.setParentOrder("0");
proOrder.setStatus("o0");
@ -141,11 +142,12 @@ public class ProWhiteOrderServiceImpl implements IProWhiteOrderService {
childProOrder.setProdDesc(prodDescs[i]);
childProOrder.setProdCode(prodCodes[i]);
childProOrder.setPlanFactoryCode(factory);
childProOrder.setFactoryCode(factory);
childProOrder.setId(IdUtils.fastSimpleUUID());
childProOrder.setParentOrder(orderCode);
childProOrder.setStatus("o0");
childProOrder.setOrderType(proOrder.getProdType());
childProOrder.setOrderCode(orderCode+"-"+num++);
childProOrder.setOrderCode(orderCode+num++);
childProOrder.setCreateBy(SecurityContextHolder.getUserName());
childProOrder.setCreateTime(DateUtils.getNowDate());
childProOrder.setUpdateBy(SecurityContextHolder.getUserName());

@ -89,6 +89,7 @@
insert into pro_order
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">id,</if>
<if test="planFactoryCode != null and planFactoryCode != ''">plan_factory_code,</if>
<if test="factoryCode != null">factory_code,</if>
<if test="orderType != null">order_type,</if>
<if test="orderCode != null">order_code,</if>
@ -113,6 +114,7 @@
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
<if test="planFactoryCode != null and planFactoryCode != ''">#{planFactoryCode},</if>
<if test="factoryCode != null">#{factoryCode},</if>
<if test="orderType != null">#{orderType},</if>
<if test="orderCode != null">#{orderCode},</if>

Loading…
Cancel
Save