Commit 5b8339ce by 李小惠

修改出入库数据结构

parent aa8368e0
package com.junmp.jyzb.api.bean.query.InAndOutRecordReq;
import lombok.Data;
@Data
public class DetailJsonReq {
private String locationId;
private Integer num;
private String locationName;
private String typeId;
private String sizeId;
}
......@@ -22,4 +22,5 @@ public class OrderReq {
private String bussinessType;
private List<DetailOrderReq> orderDetail;
private List<PurchaseEqsReq> purchaseList;
private List<DetailJsonReq> detailJson;
}
......@@ -161,5 +161,8 @@ public class OrderMain implements Serializable {
@TableField("is_print")
private String isPrint;
@TableField("detail_json")
private String detailJson;
private static final long serialVersionUID = 1L;
}
\ No newline at end of file
......@@ -234,7 +234,7 @@ public class CounterSignListener implements ExecutionListener {
execution.setVariable(variable, assigneeList);
execution.setVariable("currentAssignee", assigneeList);
//为流程进行中的单据设置审核信息
String orderType= execution.getVariable("orderType").toString();
String orderType= execution.getVariable("typeOrder").toString();
if (orderType.equals("workOrder"))
{
OrderMain om= orderMainService.getOne(new LambdaQueryWrapper<OrderMain>()
......
......@@ -2,6 +2,7 @@ package com.junmp.jyzb.service.impl;
import cn.hutool.core.util.ObjectUtil;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
......@@ -112,6 +113,9 @@ public class LogSummaryServiceImpl extends ServiceImpl<LogSummaryMapper, LogSumm
boolean c=true;
boolean c1=true;
if (ObjectUtil.isNotNull(order)){
//设置出入库仓库以及出入库数量
List<DetailJsonReq> detailJson = order.getDetailJson();
String jsonString = JSONObject.toJSONString(detailJson);
List<DetailOrderReq> orderDetailList = order.getOrderDetail();
OrderMain one = orderMainService.getOne(new LambdaQueryWrapper<OrderMain>()
.eq(OrderMain::getId, order.getId()));
......@@ -120,6 +124,7 @@ public class LogSummaryServiceImpl extends ServiceImpl<LogSummaryMapper, LogSumm
one.setActualQuantity(0);
}
// one.setActualQuantity(order.getActualQuantity()+one.getActualQuantity());
one.setDetailJson(jsonString);
one.setActualQuantity(order.getActualQuantity());
one.setOrderState(one.getOrderState());
one.setOrderState("finished");
......@@ -173,6 +178,7 @@ public class LogSummaryServiceImpl extends ServiceImpl<LogSummaryMapper, LogSumm
warehouseInventory.setOrgId(order.getOrgId());
warehouseInventory.setFlag(0);
warehouseInventory.setCreateTime(DateTimeUtil.getCurrentDateTime());
warehouseInventory.setUpdateTime(DateTimeUtil.getCurrentDateTime());
warehouseInventoryList.add(warehouseInventory);
inventory.setEpc(eqsReq.getEpc());
......
......@@ -232,7 +232,7 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain
}
}
//添加日志记录
if (req.getLogSummaryId() !=null){
if (ObjectUtil.isNull(req.getLogSummaryId()) || req.getLogSummaryId()==null){
s=s+listReq.getWarehouseName()+"【"+listReq.getTypeName()+"--"+listReq.getSizeName()+"】预计数量:"+listReq.getPlanNum()+"\n";
}
detailList.add(detail);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论