diff --git a/appengine/src/main/java/com/currency/appengine/controller/export/ExportController.java b/appengine/src/main/java/com/currency/appengine/controller/export/ExportController.java index 570107b..cb6c576 100644 --- a/appengine/src/main/java/com/currency/appengine/controller/export/ExportController.java +++ b/appengine/src/main/java/com/currency/appengine/controller/export/ExportController.java @@ -1,17 +1,21 @@ package com.currency.appengine.controller.export; +import cn.afterturn.easypoi.excel.entity.ExportParams; +import cn.afterturn.easypoi.handler.inter.IExcelExportServer; +import com.currency.appengine.annotation.CheckToken; import com.currency.appengine.domain.export.UserInfoExport; import com.currency.appengine.export.ExportServer; import com.currency.appengine.export.impl.ExportServerImpl; +import com.currency.appengine.utils.StringUtil; +import com.currency.appengine.utils.export.poi.ExcelExportUtil; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.web.bind.annotation.PostMapping; -import org.springframework.web.bind.annotation.RequestBody; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.*; import sun.security.util.PendingException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import java.util.ArrayList; +import java.util.List; import java.util.Map; @RestController @@ -35,5 +39,4 @@ public class ExportController { exportServer.exportExpertWord(json, request, response); } - } diff --git a/appengine/src/main/java/com/currency/appengine/service/export/ExportDataPageService.java b/appengine/src/main/java/com/currency/appengine/service/export/ExportDataPageService.java index 231478f..944db33 100644 --- a/appengine/src/main/java/com/currency/appengine/service/export/ExportDataPageService.java +++ b/appengine/src/main/java/com/currency/appengine/service/export/ExportDataPageService.java @@ -3,12 +3,17 @@ package com.currency.appengine.service.export; import org.apache.poi.xssf.streaming.SXSSFSheet; import org.apache.poi.xssf.streaming.SXSSFWorkbook; +import java.util.LinkedHashMap; import java.util.Map; public interface ExportDataPageService { int findCount(Map params, int method); + Object findPage(Map params, int method); + void setWorkbook(SXSSFWorkbook wb, SXSSFSheet eachSheet, Integer startRowCount, Integer endRowCount, Object datas, int method); + void magicExport(Integer count, Map bodyObj, String className, String sqlFunc, String fileName, String excelTitle, + String sheetName); } diff --git a/appengine/src/main/java/com/currency/appengine/service/export/impl/ExportDataPageServiceImpl.java b/appengine/src/main/java/com/currency/appengine/service/export/impl/ExportDataPageServiceImpl.java index 7d444a1..cd1936f 100644 --- a/appengine/src/main/java/com/currency/appengine/service/export/impl/ExportDataPageServiceImpl.java +++ b/appengine/src/main/java/com/currency/appengine/service/export/impl/ExportDataPageServiceImpl.java @@ -1,9 +1,13 @@ package com.currency.appengine.service.export.impl; +import cn.afterturn.easypoi.excel.entity.ExportParams; +import cn.afterturn.easypoi.handler.inter.IExcelExportServer; import com.currency.appengine.domain.export.UserInfoExport; import com.currency.appengine.handler.exception.MyException; import com.currency.appengine.mapper.export.ExportMapper; import com.currency.appengine.service.export.ExportDataPageService; +import com.currency.appengine.utils.ObjectUtil; +import com.currency.appengine.utils.export.poi.ExcelExportUtil; import org.apache.poi.ss.usermodel.Cell; import org.apache.poi.ss.usermodel.CellStyle; import org.apache.poi.ss.usermodel.Font; @@ -13,11 +17,14 @@ import org.apache.poi.xssf.streaming.SXSSFSheet; import org.apache.poi.xssf.streaming.SXSSFWorkbook; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import org.springframework.web.context.request.RequestAttributes; +import org.springframework.web.context.request.RequestContextHolder; +import org.springframework.web.context.request.ServletRequestAttributes; +import org.ssssssss.magicapi.core.context.RequestContext; +import org.ssssssss.magicapi.core.service.MagicAPIService; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; -import java.util.Objects; +import javax.servlet.http.HttpServletResponse; +import java.util.*; @Service public class ExportDataPageServiceImpl implements ExportDataPageService { @@ -25,8 +32,12 @@ public class ExportDataPageServiceImpl implements ExportDataPageService { @Autowired private ExportMapper exportMapper; + @Autowired + MagicAPIService service; + /** - * 查询总数 + * 查询总数 + * * @param params 参数 如筛选条件 * @param method 方法标识 * @return @@ -37,34 +48,36 @@ public class ExportDataPageServiceImpl implements ExportDataPageService { } /** - * 查询数据sql + * 查询数据sql + * * @param params 参数 如筛选条件 * @param method 方法标识 * @return */ - private String sql(Map params, int method){ + private String sql(Map params, int method) { StringBuffer buffer = new StringBuffer(); switch (method) { case 0:// 0 用户信息 buffer.append("select id, user_id, status, date_format(create_time,'%Y-%m-%d %T') create_time, nick_name, user_img from mini_user where 1=1 "); - if(Objects.nonNull(params.get("userId"))){ + if (Objects.nonNull(params.get("userId"))) { buffer.append(" and user_id like CONCAT('%',#{userId},'%') "); } - if(Objects.nonNull(params.get("nickName"))){ + if (Objects.nonNull(params.get("nickName"))) { buffer.append(" and nick_name like CONCAT('%',#{nickName},'%') "); } - if(Objects.nonNull(params.get("status"))){ + if (Objects.nonNull(params.get("status"))) { buffer.append(" and and status = #{status} "); } break; - default: - throw new MyException("导出失败,传入method参数不匹配,请检查代码"); + default: + throw new MyException("导出失败,传入method参数不匹配,请检查代码"); } return buffer.toString(); } /** - * 查询数据 + * 查询数据 + * * @param params 参数 如筛选条件 * @param method 方法标识 * @return @@ -74,7 +87,7 @@ public class ExportDataPageServiceImpl implements ExportDataPageService { Object list = new ArrayList<>(); switch (method) { case 0:// 0 用户信息 - params.put("sql",this.sql(params, method)); + params.put("sql", this.sql(params, method)); list = exportMapper.findUserInfoPage(params); break; } @@ -84,12 +97,13 @@ public class ExportDataPageServiceImpl implements ExportDataPageService { /** * 自定义样式导出使用 + * * @param wb * @param eachSheet * @param startRowCount * @param endRowCount * @param datas - * @param method 方法标识 + * @param method 方法标识 */ @Override public void setWorkbook(SXSSFWorkbook wb, SXSSFSheet eachSheet, Integer startRowCount, Integer endRowCount, Object datas, int method) { @@ -106,6 +120,41 @@ public class ExportDataPageServiceImpl implements ExportDataPageService { } } + @Override + public void magicExport(Integer count, Map bodyObj, String className, String sqlFunc, String fileName, String excelTitle, + String sheetName) { + try { + IExcelExportServer iExcelExportServer = new IExcelExportServer() { + @Override + // 分页查询 obj 总页数 page 第几页 + public List selectListForExcelExport(Object obj, int page) { + bodyObj.put("page", page); + Map params = new HashMap<>(); + params.put("body", bodyObj); + + Object value = service.invoke(sqlFunc, params); + + try { + List list = new ArrayList<>(); + list.addAll(ObjectUtil.convertObjectToListBean(value, Class.forName(className))); + return list; + } catch (ClassNotFoundException e) { + throw new RuntimeException(e); + } + } + }; + ExportParams exportParams = new ExportParams(excelTitle, sheetName); + ExcelExportUtil.exportBigEasyPoi(getResponse(), exportParams, fileName, Class.forName(className), iExcelExportServer, count); + } catch (Exception e) { + e.printStackTrace(); + } + } + + private HttpServletResponse getResponse() { + RequestAttributes requestAttributes = RequestContextHolder.getRequestAttributes(); + return requestAttributes instanceof ServletRequestAttributes ? ((ServletRequestAttributes) requestAttributes).getResponse() : RequestContext.getHttpServletResponse().getResponse(); + } + private void setUserInfoExportData(SXSSFWorkbook wb, SXSSFSheet eachSheet, Integer startRowCount, Integer endRowCount, List list) { for (int i = startRowCount; i <= endRowCount; i++) { @@ -118,10 +167,10 @@ public class ExportDataPageServiceImpl implements ExportDataPageService { eachDataRow.createCell(3).setCellValue(model.getCreateTime()); eachDataRow.createCell(4).setCellValue(model.getStatus()); - if("1".equals(model.getStatus())) { + if ("1".equals(model.getStatus())) { int physicalNumberOfCells = eachDataRow.getPhysicalNumberOfCells(); for (int j = 0; j < physicalNumberOfCells; j++) { - if(i <= 1){ + if (i <= 1) { eachSheet.setColumnWidth(j, 20 * 256); } //获取当前单元格 中的value diff --git a/appengine/src/main/java/com/currency/appengine/service/export/model/ExtrusionScheduleExport.java b/appengine/src/main/java/com/currency/appengine/service/export/model/ExtrusionScheduleExport.java new file mode 100644 index 0000000..7ea1e5c --- /dev/null +++ b/appengine/src/main/java/com/currency/appengine/service/export/model/ExtrusionScheduleExport.java @@ -0,0 +1,76 @@ +package com.currency.appengine.service.export.model; + +import cn.afterturn.easypoi.excel.annotation.Excel; +import lombok.Data; + +import java.math.BigDecimal; + +@Data +public class ExtrusionScheduleExport { + @Excel(name = "排产单号", width = 40) + private String scheduleNumber; + + @Excel(name = "挤压排产日期", width = 40) + private String extrusionDate; + + @Excel(name = "挤压机台", width = 40) + private String extrusionMachineName; + + @Excel(name = "挤压班组", width = 40) + private String extrusionTeamName; + + @Excel(name = "销售订单编号", width = 40) + private String salesOrderCode; + + @Excel(name = "销售员", width = 40) + private String salespersonName; + + @Excel(name = "物料编码", width = 40) + private String materialCode; + + @Excel(name = "物料名称", width = 40) + private String materialName; + + @Excel(name = "订单长度 (M)", width = 40) + private BigDecimal orderLength; + + @Excel(name = "订单总数 (支)", width = 40) + private Integer orderTotalQuantity; + + @Excel(name = "表面方式 (颜色)", width = 40) + private String surfaceMethod; + + @Excel(name = "规格型号 (MM)", width = 40) + private String specification; + + @Excel(name = "客方料号", width = 40) + private String customerMaterialCode; + + @Excel(name = "壁厚", width = 40) + private BigDecimal thickness; + + @Excel(name = "理论重量 (KG)", width = 40) + private BigDecimal theoreticalWeight; + + @Excel(name = "实际总重量(KG)", width = 40) + private BigDecimal actualWeight; + + @Excel(name = "包装数量(扎数)", width = 40) + private Integer packingQuantity; + + @Excel(name = "包装方式", width = 40) + private String packagingMethod; + + @Excel(name = "排产长度", width = 40) + private BigDecimal productionLength; + + @Excel(name = "排产支数", width = 40) + private Integer productionPieces; + + @Excel(name = "锯切方式", width = 40) + private String sawingMethod; + + @Excel(name = "排产理论重量", width = 40) + private BigDecimal productionWeight; + +} diff --git a/appengine/src/main/java/com/currency/appengine/service/export/model/OrderTrackingExport.java b/appengine/src/main/java/com/currency/appengine/service/export/model/OrderTrackingExport.java new file mode 100644 index 0000000..5330421 --- /dev/null +++ b/appengine/src/main/java/com/currency/appengine/service/export/model/OrderTrackingExport.java @@ -0,0 +1,152 @@ +package com.currency.appengine.service.export.model; + +import cn.afterturn.easypoi.excel.annotation.Excel; +import lombok.Data; + +import java.util.Date; + +/** + * 队伍信息 + */ +@Data +public class OrderTrackingExport { + + @Excel(name = "销售订单号", width = 40) + private String salesOrderCode; + + @Excel(name = "订单号", width = 40) + private String orderNo; + + @Excel(name = "产品编码", width = 40) + private String materialCode; + + @Excel(name = "物料名称", width = 40) + private String materialName; + + @Excel(name = "型材型号", width = 40) + private String profileModel; + + @Excel(name = "规格型号", width = 40) + private String specification; + + @Excel(name = "壁厚", width = 40) + private String thickness; + + @Excel(name = "米重 (kg/m)", width = 40) + private String weight; + + @Excel(name = "订单总数 (支)", width = 40) + private String orderLength; + + @Excel(name = "订单长度 (M)", width = 40) + private String orderTotalQuantity; + + @Excel(name = "表面方式 (颜色)", width = 40) + private String surfaceMethod; + + @Excel(name = "订单日期", width = 40) + private String deliveryDate; + + @Excel(name = "理论重量 (KG)", width = 40) + private String theoreticalWeight; + + @Excel(name = "生产支数", width = 40) + private String producedPieces; + + @Excel(name = "生产长度 (m)", width = 40) + private String producedLength; + + @Excel(name = "计划支数", width = 40) + private String plannedPieces; + + @Excel(name = "排产长度", width = 40) + private String productionLength; + + @Excel(name = "排产支数", width = 40) + private String productionPieces; + + @Excel(name = "锯切方式", width = 40) + private String sawingMethod; + + @Excel(name = "实际米重", width = 40) + private String jiya_productionWeight; + + @Excel(name = "已挤压支数", width = 40) + private String jiya_productionNumber; + + @Excel(name = "已挤压重量(KG)", width = 40) + private String jiya_actualWeight; + + @Excel(name = "已精品支数", width = 40) + private String jingpin_productionNumber; + + @Excel(name = "已精品重量(KG)", width = 40) + private String jingpin_productionWeight; + + @Excel(name = "已氧化上排支数", width = 40) + private String yanghau1_productionNumber; + + @Excel(name = "已氧化上排重量(KG)", width = 40) + private String yanghau1_actualWeight; + + @Excel(name = "已氧化下排支数", width = 40) + private String yanghua2_productionNumber; + + @Excel(name = "已氧化下排重量(KG)", width = 40) + private String yanghua2_actualWeight; + + @Excel(name = "已精切支数", width = 40) + private String jingqie_productionNumber; + + @Excel(name = "已精切重量(KG)", width = 40) + private String jingqie_actualWeight; + + @Excel(name = "已打孔支数", width = 40) + private String dk_productionNumber; + + @Excel(name = "已打孔重量(KG)", width = 40) + private String dk_actualWeight; + + @Excel(name = "已包装支数", width = 40) + private String bz_productionNumber; + + @Excel(name = "已包装重量(KG)", width = 40) + private String bz_actualWeight; + + @Excel(name = "入库支数", width = 40) + private String receiptQuantity; + + @Excel(name = "已入库重量(KG)", width = 40) + private String actualWeight; + + @Excel(name = "交货支数", width = 40) + private String shipmentQuantity; + + @Excel(name = "已交货重量(KG)", width = 40) + private String shipmentActualWeight; + + @Excel(name = "未交货支数", width = 40) + private String noShipmentQuantity; + + @Excel(name = "未交货重量(KG)", width = 40) + private String noActualWeight; + + @Excel(name = "库存总支数", width = 40) + private String existingInventory; + + @Excel(name = "库存总重量(KG)", width = 40) + private String existingActualWeight; + + @Excel(name = "长料报废支数", width = 40) + private String longScrapNumber; + + @Excel(name = "长料报废重量(KG)", width = 40) + private String longScrapWeight; + + @Excel(name = "短料报费支数", width = 40) + private String shortageScrapNumber; + + @Excel(name = "短料报费重量(KG)", width = 40) + private String shortageScrapWeight; + +} \ No newline at end of file diff --git a/appengine/src/main/java/com/currency/appengine/utils/ObjectUtil.java b/appengine/src/main/java/com/currency/appengine/utils/ObjectUtil.java index 4f966b8..e8c9322 100644 --- a/appengine/src/main/java/com/currency/appengine/utils/ObjectUtil.java +++ b/appengine/src/main/java/com/currency/appengine/utils/ObjectUtil.java @@ -7,6 +7,8 @@ import org.apache.commons.lang3.ArrayUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import java.lang.reflect.Field; +import java.math.BigDecimal; import java.util.*; public class ObjectUtil { @@ -57,6 +59,47 @@ public class ObjectUtil { return null; } + public static List convertObjectToListBean(Object obj, Class beanClass) { + List beanList = new ArrayList<>(); + if (obj instanceof List) { + @SuppressWarnings("unchecked") + List> listMap = (List>) obj; + for (Map map : listMap) { + T bean; + try { + bean = beanClass.newInstance(); // 创建Bean实例 + Field[] fields = beanClass.getDeclaredFields(); // 获取Bean的所有字段 + + for (Field field : fields) { + field.setAccessible(true); // 设置字段可访问 + Object value = map.get(field.getName()); // 从Map中获取值 + if (value != null) { + if (value != null && !field.getType().isAssignableFrom(value.getClass())) { + // 进行类型转换 + if (BigDecimal.class.isAssignableFrom(field.getType())) { + value = new BigDecimal(value.toString()); + } else if (Integer.class.isAssignableFrom(field.getType())) { + value = Integer.parseInt(value.toString()); + } else if (Double.class.isAssignableFrom(field.getType())) { + value = Double.parseDouble(value.toString()); + } else { + value = String.valueOf(value); + } + // 其他类型转换... + } + + field.set(bean, value); // 将值设置到Bean的字段中 + } + } + beanList.add(bean); // 将填充好的Bean添加到列表中 + } catch (InstantiationException | IllegalAccessException e) { + e.printStackTrace(); + } + } + } + return beanList; + } + public static List> castListMap(Object obj, Class kCalzz, Class vCalzz) { List> result = new ArrayList<>(); if (obj instanceof List) { diff --git a/appengine/src/main/resources/api_file/api/web管理端API/仓储管理/现有库存量/列表仓库物料.ms b/appengine/src/main/resources/api_file/api/web管理端API/仓储管理/现有库存量/列表仓库物料.ms index 7dda4f2..da4e77a 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/仓储管理/现有库存量/列表仓库物料.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/仓储管理/现有库存量/列表仓库物料.ms @@ -5,7 +5,7 @@ "groupId" : "40879f3a602c40e493f0b273de9fc01e", "name" : "列表仓库物料", "createTime" : null, - "updateTime" : 1728715379207, + "updateTime" : 1732449052120, "lock" : null, "createBy" : null, "updateBy" : null, @@ -51,6 +51,7 @@ String materialCode = body.materialCode; String materialName = body.materialName; String profileModel = body.profileModel; String warehouse = body.warehouse; +String queryType = body['type']; // 1-只查看有库存的 return db.page(""" select @@ -83,9 +84,10 @@ return db.page(""" mwm.create_by, mwm.pieces from mini_warehouse_material mwm - where 1=1 + where 1=1 ?{materialCode != null and materialCode != "", and mwm.material_code like concat('%', #{materialCode}, '%') } ?{materialName != null and materialName != "", and mwm.material_name like concat('%', #{materialName}, '%') } ?{profileModel != null and profileModel != "", and mwm.profile_model like concat('%', #{profileModel}, '%') } ?{warehouse != null and warehouse != "", and mwm.warehouse = #{warehouse} } + ?{queryType != null and queryType != "" and queryType == 1, and mwm.existing_inventory > 0 } """); \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/导出/group.json b/appengine/src/main/resources/api_file/api/web管理端API/导出/group.json new file mode 100644 index 0000000..c3ca067 --- /dev/null +++ b/appengine/src/main/resources/api_file/api/web管理端API/导出/group.json @@ -0,0 +1,14 @@ +{ + "properties" : { }, + "id" : "01a85821982944e8855e0cb8d3d48c72", + "name" : "导出", + "type" : "api", + "parentId" : "c6ba5ea7aca143ef95dffaf14b4960e5", + "path" : "/export", + "createTime" : 1732603484379, + "updateTime" : null, + "createBy" : null, + "updateBy" : null, + "paths" : [ ], + "options" : [ ] +} \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/导出/挤压排产单导出.ms b/appengine/src/main/resources/api_file/api/web管理端API/导出/挤压排产单导出.ms new file mode 100644 index 0000000..9868745 --- /dev/null +++ b/appengine/src/main/resources/api_file/api/web管理端API/导出/挤压排产单导出.ms @@ -0,0 +1,36 @@ +{ + "properties" : { }, + "id" : "ec8de9306e07460eb7f04f43b5e7edcf", + "script" : null, + "groupId" : "01a85821982944e8855e0cb8d3d48c72", + "name" : "挤压排产单导出", + "createTime" : null, + "updateTime" : 1732611077461, + "lock" : null, + "createBy" : null, + "updateBy" : null, + "path" : "/extrusionSchedule", + "method" : "POST", + "parameters" : [ ], + "options" : [ ], + "requestBody" : "", + "headers" : [ ], + "paths" : [ ], + "responseBody" : null, + "description" : null, + "requestBodyDefinition" : null, + "responseBodyDefinition" : null +} +================================ +import 'exportDataPageServiceImpl' as exportDataPageServiceImpl; + +import '@/sql/extrusionSchedule/count' as masterFind; +import response + +int count = masterFind(body); + +body['page'] = 1 +body['size'] = 100; +exportDataPageServiceImpl.magicExport(count, body, "com.currency.appengine.service.export.model.ExtrusionScheduleExport", '/sql/extrusionSchedule/list', '挤压排产', '挤压排产', '挤压排产'); + +response.end(); \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/导出/订单跟踪导出.ms b/appengine/src/main/resources/api_file/api/web管理端API/导出/订单跟踪导出.ms new file mode 100644 index 0000000..b23cf33 --- /dev/null +++ b/appengine/src/main/resources/api_file/api/web管理端API/导出/订单跟踪导出.ms @@ -0,0 +1,36 @@ +{ + "properties" : { }, + "id" : "914ca6c8b3ae43e3ae6029318edff17c", + "script" : null, + "groupId" : "01a85821982944e8855e0cb8d3d48c72", + "name" : "订单跟踪导出", + "createTime" : null, + "updateTime" : 1732610997776, + "lock" : null, + "createBy" : null, + "updateBy" : null, + "path" : "/orderTracking", + "method" : "POST", + "parameters" : [ ], + "options" : [ ], + "requestBody" : "", + "headers" : [ ], + "paths" : [ ], + "responseBody" : null, + "description" : null, + "requestBodyDefinition" : null, + "responseBodyDefinition" : null +} +================================ +import 'exportDataPageServiceImpl' as exportDataPageServiceImpl; + +import '@/sql/orderTracking/count' as masterFind; +import response + +int count = masterFind(body); + +body['page'] = 1 +body['size'] = 100; +exportDataPageServiceImpl.magicExport(count, body, "com.currency.appengine.service.export.model.OrderTrackingExport", '/sql/orderTracking/list', '订单跟踪表', '订单跟踪表', '订单跟踪表'); + +response.end(); \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/产品入库表/产品入库详细列表.ms b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/产品入库表/产品入库详细列表.ms index 7010f47..d414e21 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/产品入库表/产品入库详细列表.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/产品入库表/产品入库详细列表.ms @@ -5,7 +5,7 @@ "groupId" : "4aa6b5de02c244e2981c22bf5a95394d", "name" : "产品入库详细列表", "createTime" : null, - "updateTime" : 1732270231302, + "updateTime" : 1732592493010, "lock" : null, "createBy" : null, "updateBy" : null, @@ -26,7 +26,13 @@ import '@/common/sql' as sql String warehouseProductMaterial = sql("warehouseProductMaterial") warehouseProductMaterial = warehouseProductMaterial.replace('mwp.packing_quantity,', '').replace('mwp.customer_id,', '') -String documentNumber = body.documentNumber; +String documentNumber = body['documentNumber']; + +String orderNo = body['orderNo']; +String materialCode = body['materialCode']; +String profileModel = body['profileModel']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; return db.page(""" select @@ -52,4 +58,10 @@ return db.page(""" left join mini_warehouses mw on mw.warehouse_code = mwp.warehouse where 1=1 ?{documentNumber!=null && documentNumber!="", and mpr.document_number like concat('%', #{documentNumber} ,'%') } + + ?{orderNo != null and orderNo != '', and mwp.order_no like concat('%', #{orderNo}, '%')} + ?{materialCode != null and materialCode != '', and mwp.material_code like concat('%', #{materialCode}, '%')} + ?{profileModel != null and profileModel != '', and mwp.profile_model like concat('%', #{profileModel}, '%')} + ?{customerId != null and customerId != '', and mpr.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and mwp.surface_method = #{surfaceMethod}} """); \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/列表.ms b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/列表.ms index 23fbdf6..b86c7bb 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/列表.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/列表.ms @@ -5,7 +5,7 @@ "groupId" : "f4b3acf704cf4db29258ba70e24f8fc5", "name" : "列表", "createTime" : null, - "updateTime" : 1732243472745, + "updateTime" : 1732611589866, "lock" : null, "createBy" : null, "updateBy" : null, @@ -25,10 +25,10 @@ "expression" : null, "children" : null } ], - "requestBody" : "", + "requestBody" : "{\r\n \"page\": 1,\r\n \"size\": 30\r\n}", "headers" : [ { "name" : "authorization", - "value" : null, + "value" : "5E34C0D7EA601026B93C26119C7E1AD5FD8181534AF63488EA20A16DC159FCC834A620E0A0B1706ADEAA4B0F75B5AF85", "description" : "登录token", "required" : false, "dataType" : "String", @@ -40,7 +40,7 @@ "children" : null } ], "paths" : [ ], - "responseBody" : null, + "responseBody" : "{\n \"code\": -1,\n \"data\": null,\n \"message\": \"系统内部出现错误\"\n}", "description" : null, "requestBodyDefinition" : null, "responseBodyDefinition" : null @@ -66,10 +66,11 @@ var sql = """ left join sys_user su on su.user_id = mes.extrusion_team left join mini_production_machines mpm on mpm.machine_code = mes.extrusion_machine where 1=1 - ?{scheduleNumber!=null && scheduleNumber!="", and mes.schedule_number like concat('%', #{scheduleNumber} ,'%') } - ?{extrusionDate!=null && extrusionDate!="", and date(mes.extrusion_date) = #{extrusionDate} } - ?{extrusionMachine!=null && extrusionMachine!="", and mes.extrusion_machine = #{extrusionMachine} } - ?{extrusionTeam!=null && extrusionTeam!="", and mes.extrusion_team = #{extrusionTeam} } + ?{scheduleNumber!=null && scheduleNumber!="", and mes.schedule_number like concat('%', #{scheduleNumber} ,'%') } + ?{extrusionDate!=null && extrusionDate!="", and date(mes.extrusion_date) = #{extrusionDate} } + ?{extrusionMachine!=null && extrusionMachine!="", and mes.extrusion_machine = #{extrusionMachine} } + ?{extrusionTeam!=null && extrusionTeam!="", and mes.extrusion_team = #{extrusionTeam} } + """ -return db.page(sql); +return db.page(sql) \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/详情列表.ms b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/详情列表.ms index d29c49a..14e3ba5 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/详情列表.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/挤压排产表/详情列表.ms @@ -5,7 +5,7 @@ "groupId" : "f4b3acf704cf4db29258ba70e24f8fc5", "name" : "详情列表", "createTime" : null, - "updateTime" : 1732271133944, + "updateTime" : 1732611995797, "lock" : null, "createBy" : null, "updateBy" : null, @@ -548,6 +548,10 @@ String materialCode = body["materialCode"]; String profileModel = body["profileModel"]; String salesStatus = body["salesStatus"]; +String extrusionDate = body['extrusionDate']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + return db.page(""" select date_format(mes.extrusion_date, '%Y-%m-%d') as extrusion_date, @@ -578,4 +582,8 @@ return db.page(""" ?{materialCode != null and materialCode != '', and msm.material_code like concat('%', #{materialCode}, '%')} ?{profileModel != null and profileModel != '', and msm.profile_model like concat('%', #{profileModel}, '%')} ?{salesStatus != null and salesStatus != '', and mso.status = #{salesStatus}} + + ?{extrusionDate!=null && extrusionDate!="", and date(mes.extrusion_date) = #{extrusionDate} } + ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and msm.surface_method = #{surfaceMethod}} """) \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/生产领料表/领料物料列表.ms b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/生产领料表/领料物料列表.ms index ff155bb..7934a76 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/生产管理/生产领料表/领料物料列表.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/生产管理/生产领料表/领料物料列表.ms @@ -5,7 +5,7 @@ "groupId" : "d4e06c480fb04ecaaaee36cd3ad92aea", "name" : "领料物料列表", "createTime" : null, - "updateTime" : 1732270091770, + "updateTime" : 1732592621097, "lock" : null, "createBy" : null, "updateBy" : null, @@ -27,6 +27,12 @@ import '@/common/sql' as sql String documentNumber = body.documentNumber; String warehouse = body.warehouse; +String orderNo = body['orderNo']; +String materialCode = body['materialCode']; +String profileModel = body['profileModel']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + String warehouseMaterial = sql("warehouseMaterial") return db.page(""" diff --git a/appengine/src/main/resources/api_file/api/web管理端API/采购管理/采购订单管理/采购订单详情列表.ms b/appengine/src/main/resources/api_file/api/web管理端API/采购管理/采购订单管理/采购订单详情列表.ms index fbddd5e..54e5875 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/采购管理/采购订单管理/采购订单详情列表.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/采购管理/采购订单管理/采购订单详情列表.ms @@ -5,7 +5,7 @@ "groupId" : "a2b7765d540449b7bf93e070c1911ce9", "name" : "采购订单详情列表", "createTime" : null, - "updateTime" : 1732265444981, + "updateTime" : 1732592767045, "lock" : null, "createBy" : null, "updateBy" : null, @@ -19,7 +19,7 @@ "responseBody" : "{\n \"code\": 0,\n \"data\": {\n \"count\": 504,\n \"list\": [\n {\n \"id\": 5628,\n \"purchaseOrderNumber\": \"P202407003\",\n \"materialCode\": \"FL00069\",\n \"materialName\": \"除灰挤\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"KG\",\n \"remarks\": null,\n \"purchaseQuantity\": 1000,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 6.5,\n \"amount\": 6500,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432248000,\n \"warehousingQuantity\": 1000,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5629,\n \"purchaseOrderNumber\": \"P202407004\",\n \"materialCode\": \"FL00046\",\n \"materialName\": \"帆布手套\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"帆布手套\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"包\",\n \"remarks\": null,\n \"purchaseQuantity\": 4,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 17.5,\n \"amount\": 70,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432295000,\n \"warehousingQuantity\": 4,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5630,\n \"purchaseOrderNumber\": \"P202407005\",\n \"materialCode\": \"FL00046\",\n \"materialName\": \"帆布手套\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"帆布手套\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"包\",\n \"remarks\": null,\n \"purchaseQuantity\": 4,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 17.5,\n \"amount\": 70,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432375000,\n \"warehousingQuantity\": 4,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5631,\n \"purchaseOrderNumber\": \"P202407006\",\n \"materialCode\": \"FL00057\",\n \"materialName\": \"碎布\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"包\",\n \"remarks\": null,\n \"purchaseQuantity\": 10,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 180,\n \"amount\": 180,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432399000,\n \"warehousingQuantity\": 10,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5632,\n \"purchaseOrderNumber\": \"P202407007\",\n \"materialCode\": \"FL00058\",\n \"materialName\": \"13--15开口扳手\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"13--15\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"PCS\",\n \"remarks\": null,\n \"purchaseQuantity\": 2,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 6,\n \"amount\": 12,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432445000,\n \"warehousingQuantity\": 2,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5633,\n \"purchaseOrderNumber\": \"P202407008\",\n \"materialCode\": \"FL00059\",\n \"materialName\": \"明装五孔插座\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"明装五孔\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"盒\",\n \"remarks\": null,\n \"purchaseQuantity\": 10,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 80,\n \"amount\": 80,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5634,\n \"purchaseOrderNumber\": \"P202407009\",\n \"materialCode\": \"FL00060\",\n \"materialName\": \"30x40厘米不锈钢强电箱\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"30*40\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"PCS\",\n \"remarks\": null,\n \"purchaseQuantity\": 10,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 110,\n \"amount\": 110,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5635,\n \"purchaseOrderNumber\": \"P202407010\",\n \"materialCode\": \"FL00061\",\n \"materialName\": \"M4丝攻\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"M4丝攻\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"套\",\n \"remarks\": null,\n \"purchaseQuantity\": 10,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 5,\n \"amount\": 5,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5636,\n \"purchaseOrderNumber\": \"P202407011\",\n \"materialCode\": \"FL00062\",\n \"materialName\": \"M5丝攻\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"M5丝攻\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"套\",\n \"remarks\": null,\n \"purchaseQuantity\": 10,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 5,\n \"amount\": 5,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5637,\n \"purchaseOrderNumber\": \"P202407012\",\n \"materialCode\": \"FL00063\",\n \"materialName\": \"黑手洗手粉\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"箱\",\n \"remarks\": null,\n \"purchaseQuantity\": 2,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 18,\n \"amount\": 36,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5638,\n \"purchaseOrderNumber\": \"P202407013\",\n \"materialCode\": \"FL00064\",\n \"materialName\": \"拖把\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"把\",\n \"remarks\": null,\n \"purchaseQuantity\": 4,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 13,\n \"amount\": 52,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5639,\n \"purchaseOrderNumber\": \"P202407014\",\n \"materialCode\": \"FL00065\",\n \"materialName\": \"锯片\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"405*25.4\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"块\",\n \"remarks\": null,\n \"purchaseQuantity\": 5,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 300,\n \"amount\": 1500,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432531000,\n \"warehousingQuantity\": 5,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5640,\n \"purchaseOrderNumber\": \"P202407015\",\n \"materialCode\": \"FL00056\",\n \"materialName\": \"拉伸膜\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"卷\",\n \"remarks\": null,\n \"purchaseQuantity\": 4,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 49.75,\n \"amount\": 199,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5642,\n \"purchaseOrderNumber\": \"P202407017\",\n \"materialCode\": \"FL00053\",\n \"materialName\": \"信封\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"PCS\",\n \"remarks\": null,\n \"purchaseQuantity\": 500,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 0.3,\n \"amount\": 150,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5643,\n \"purchaseOrderNumber\": \"P202407018\",\n \"materialCode\": \"FL00054\",\n \"materialName\": \"放行条\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"本\",\n \"remarks\": null,\n \"purchaseQuantity\": 51,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 2,\n \"amount\": 102,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5644,\n \"purchaseOrderNumber\": \"P202407019\",\n \"materialCode\": \"FL00066\",\n \"materialName\": \"五金仓库入库单\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"本\",\n \"remarks\": null,\n \"purchaseQuantity\": 100,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 2.2,\n \"amount\": 220,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5645,\n \"purchaseOrderNumber\": \"P202407020\",\n \"materialCode\": \"FL00055\",\n \"materialName\": \"隔膜泵膜片\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"PCS\",\n \"remarks\": null,\n \"purchaseQuantity\": 2,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 150,\n \"amount\": 300,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729416906000,\n \"warehousingQuantity\": 0,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5646,\n \"purchaseOrderNumber\": \"P202407021\",\n \"materialCode\": \"FL00067\",\n \"materialName\": \"吊顶\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"主龙骨45米、边骨23米、副龙骨60厘米、石膏天花板60*60厘米\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"M\",\n \"remarks\": null,\n \"purchaseQuantity\": 50,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 17,\n \"amount\": 850,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432661000,\n \"warehousingQuantity\": 50,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5647,\n \"purchaseOrderNumber\": \"P202407022\",\n \"materialCode\": \"FL00070\",\n \"materialName\": \"硫酸\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"KG\",\n \"remarks\": null,\n \"purchaseQuantity\": 7810,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 0.54,\n \"amount\": 4217.4,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432729000,\n \"warehousingQuantity\": 7810,\n \"returningQuantity\": 0\n },\n {\n \"id\": 5648,\n \"purchaseOrderNumber\": \"P202407023\",\n \"materialCode\": \"FL00003\",\n \"materialName\": \"磷酸\",\n \"profileModel\": null,\n \"weight\": null,\n \"specification\": \"\",\n \"thickness\": null,\n \"piecesBundle\": null,\n \"materialCategory\": null,\n \"defaultLength\": null,\n \"packagingMethod\": null,\n \"source\": null,\n \"unit\": \"KG\",\n \"remarks\": null,\n \"purchaseQuantity\": 31745,\n \"pieces\": null,\n \"theoreticalWeight\": null,\n \"unitPrice\": 2,\n \"amount\": 63490,\n \"taxRate\": null,\n \"priceWithTax\": null,\n \"amountWithTax\": null,\n \"pricingMethod\": null,\n \"createTime\": 1729416906000,\n \"createBy\": null,\n \"updateTime\": 1729432759000,\n \"warehousingQuantity\": 31745,\n \"returningQuantity\": 0\n }\n ]\n },\n \"message\": \"success\"\n}", "description" : null, "requestBodyDefinition" : { - "name" : "", + "name" : "root", "value" : "", "description" : "", "required" : false, @@ -511,7 +511,7 @@ return db.page(""" left join mini_supplier_info msi on msi.id = mpo.supplier left join sys_user su on su.user_id = mpo.purchaser where 1=1 - ?{documentNumber!=null && documentNumber !="", mpom.purchase_order_number = #{documentNumber}} - ?{materialCode!=null && materialCode !="", mpom.material_code = #{materialCode}} - ?{status!=null && status !="", mpom.status = #{status}} + ?{documentNumber!=null && documentNumber !="", and mpom.purchase_order_number = #{documentNumber}} + ?{materialCode!=null && materialCode !="", and mpom.material_code = #{materialCode}} + ?{status!=null && status !="", and mpom.status = #{status}} """) \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售出货管理/详情列表.ms b/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售出货管理/详情列表.ms index a5273c2..e8389c7 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售出货管理/详情列表.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售出货管理/详情列表.ms @@ -5,7 +5,7 @@ "groupId" : "a170047f79ab4cb1b892edc5cccd823e", "name" : "详情列表", "createTime" : null, - "updateTime" : 1732419716776, + "updateTime" : 1732592442218, "lock" : null, "createBy" : null, "updateBy" : null, @@ -24,6 +24,12 @@ ================================ String documentNumber = body["documentNumber"]; +String orderNo = body['orderNo']; +String materialCode = body['materialCode']; +String profileModel = body['profileModel']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + var sql = """ select mss.customer_id, @@ -61,8 +67,15 @@ var sql = """ left join mini_sales_shipment_materials mssm on mssm.sales_shipment_code = mss.document_number left join mini_warehouse_product mwp on mwp.material_code = mssm.material_code and mwp.warehouse = mssm.warehouse and mwp.sales_order_code = mssm.sales_order_code and mwp.order_no = mssm.order_no + left join mini_sales_orders mso on mwp.sales_order_code = mso.document_number where 1 = 1 ?{documentNumber != null and documentNumber != '', and mss.document_number like concat('%', #{documentNumber}, '%')} + + ?{orderNo != null and orderNo != '', and mwp.order_no like concat('%', #{orderNo}, '%')} + ?{materialCode != null and materialCode != '', and mwp.material_code like concat('%', #{materialCode}, '%')} + ?{profileModel != null and profileModel != '', and mwp.profile_model like concat('%', #{profileModel}, '%')} + ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and mwp.surface_method = #{surfaceMethod}} """ return db.page(sql); \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/订单跟踪.ms b/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/订单跟踪.ms index ca8eb1d..56aa3c2 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/订单跟踪.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/订单跟踪.ms @@ -5,7 +5,7 @@ "groupId" : "e631b317606f4246ac82585a7c1f1c5b", "name" : "订单跟踪", "createTime" : null, - "updateTime" : 1732420582740, + "updateTime" : 1732610542034, "lock" : null, "createBy" : null, "updateBy" : null, @@ -13,280 +13,322 @@ "method" : "POST", "parameters" : [ ], "options" : [ ], - "requestBody" : "{\r\n \"page\": 1,\r\n \"size\": 10\r\n}", + "requestBody" : "{\r\n \"page\": 1,\r\n \"size\": 30\r\n}", "headers" : [ ], "paths" : [ ], - "responseBody" : "{\n \"code\": 0,\n \"data\": {\n \"count\": 2003,\n \"list\": [\n {\n \"salesOrderCode\": \"SRJ20240702-39301\",\n \"orderNo\": \"39301\",\n \"materialCode\": \"KLS-001-001\",\n \"materialName\": \"KLS-001\",\n \"profileModel\": \"KLS-001\",\n \"specification\": \"20.9*50.2\",\n \"thickness\": 1.75,\n \"weight\": 0.735,\n \"orderLength\": 3.6,\n \"orderTotalQuantity\": 257,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 680.022,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 257,\n \"productionLength\": 3.6,\n \"productionPieces\": 259,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 265,\n \"actualWeight\": 701.19,\n \"shipmentQuantity\": 265,\n \"shipmentActualWeight\": 701.19,\n \"noShipmentQuantity\": -265,\n \"noActualWeight\": -701.19,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39302\",\n \"orderNo\": \"39302\",\n \"materialCode\": \"KLS-001-001\",\n \"materialName\": \"KLS-001\",\n \"profileModel\": \"KLS-001\",\n \"specification\": \"20.9*50.2\",\n \"thickness\": 1.75,\n \"weight\": 0.735,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 61,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 134.505,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 61,\n \"productionLength\": 3,\n \"productionPieces\": 62,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 65,\n \"actualWeight\": 143.32,\n \"shipmentQuantity\": 65,\n \"shipmentActualWeight\": 143.32,\n \"noShipmentQuantity\": -65,\n \"noActualWeight\": -143.32,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39303\",\n \"orderNo\": \"39303\",\n \"materialCode\": \"KLS-001-001\",\n \"materialName\": \"KLS-001\",\n \"profileModel\": \"KLS-001\",\n \"specification\": \"20.9*50.2\",\n \"thickness\": 1.75,\n \"weight\": 0.735,\n \"orderLength\": 4.2,\n \"orderTotalQuantity\": 20,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 61.74,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 20,\n \"productionLength\": 4.2,\n \"productionPieces\": 21,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 22,\n \"actualWeight\": 67.91,\n \"shipmentQuantity\": 22,\n \"shipmentActualWeight\": 67.91,\n \"noShipmentQuantity\": -22,\n \"noActualWeight\": -67.91,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39304\",\n \"orderNo\": \"39304\",\n \"materialCode\": \"KLS-002A-001\",\n \"materialName\": \"KLS-002A\",\n \"profileModel\": \"KLS-002A\",\n \"specification\": \"55.1*54\",\n \"thickness\": 2,\n \"weight\": 1.6,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 8,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 38.4,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 8,\n \"productionLength\": 3,\n \"productionPieces\": 8,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 10,\n \"actualWeight\": 52,\n \"shipmentQuantity\": 10,\n \"shipmentActualWeight\": 52,\n \"noShipmentQuantity\": -10,\n \"noActualWeight\": -52,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39305\",\n \"orderNo\": \"39305\",\n \"materialCode\": \"KLS-003-001\",\n \"materialName\": \"KLS-003\",\n \"profileModel\": \"KLS-003\",\n \"specification\": \"55.1*54\",\n \"thickness\": 2,\n \"weight\": 2.11,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 8,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 50.64,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 16,\n \"productionLength\": 3,\n \"productionPieces\": 8,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 8,\n \"actualWeight\": 55,\n \"shipmentQuantity\": 8,\n \"shipmentActualWeight\": 55,\n \"noShipmentQuantity\": -8,\n \"noActualWeight\": -55,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39306\",\n \"orderNo\": \"39306\",\n \"materialCode\": \"KLS-004-001\",\n \"materialName\": \"KLS-004\",\n \"profileModel\": \"KLS-004\",\n \"specification\": \"51.23*51.03\",\n \"thickness\": 1.08,\n \"weight\": 0.316,\n \"orderLength\": 3.6,\n \"orderTotalQuantity\": 257,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 292.3632,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 257,\n \"productionLength\": 3.6,\n \"productionPieces\": 260,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 263,\n \"actualWeight\": 306,\n \"shipmentQuantity\": 263,\n \"shipmentActualWeight\": 306,\n \"noShipmentQuantity\": -263,\n \"noActualWeight\": -306,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39307\",\n \"orderNo\": \"39307\",\n \"materialCode\": \"KLS-004-001\",\n \"materialName\": \"KLS-004\",\n \"profileModel\": \"KLS-004\",\n \"specification\": \"51.23*51.03\",\n \"thickness\": 1.08,\n \"weight\": 0.316,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 61,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 57.828,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 61,\n \"productionLength\": 3,\n \"productionPieces\": 62,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 60,\n \"actualWeight\": 57.99,\n \"shipmentQuantity\": 60,\n \"shipmentActualWeight\": 57.99,\n \"noShipmentQuantity\": -60,\n \"noActualWeight\": -57.99,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39308\",\n \"orderNo\": \"39308\",\n \"materialCode\": \"KLS-004-001\",\n \"materialName\": \"KLS-004\",\n \"profileModel\": \"KLS-004\",\n \"specification\": \"51.23*51.03\",\n \"thickness\": 1.08,\n \"weight\": 0.316,\n \"orderLength\": 4.2,\n \"orderTotalQuantity\": 20,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 26.544,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 20,\n \"productionLength\": 4.2,\n \"productionPieces\": 20,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 20,\n \"actualWeight\": 27,\n \"shipmentQuantity\": 20,\n \"shipmentActualWeight\": 27,\n \"noShipmentQuantity\": -20,\n \"noActualWeight\": -27,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39309\",\n \"orderNo\": \"39309\",\n \"materialCode\": \"KLS-005-001\",\n \"materialName\": \"KLS-005\",\n \"profileModel\": \"KLS-005\",\n \"specification\": \"21.85*19.7\",\n \"thickness\": 1.05,\n \"weight\": 0.274,\n \"orderLength\": 3.6,\n \"orderTotalQuantity\": 257,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 253.5048,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 257,\n \"productionLength\": 3.6,\n \"productionPieces\": 260,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 161,\n \"actualWeight\": 158.81,\n \"shipmentQuantity\": 161,\n \"shipmentActualWeight\": 158.81,\n \"noShipmentQuantity\": -161,\n \"noActualWeight\": -158.81,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39310\",\n \"orderNo\": \"39310\",\n \"materialCode\": \"KLS-005-001\",\n \"materialName\": \"KLS-005\",\n \"profileModel\": \"KLS-005\",\n \"specification\": \"21.85*19.7\",\n \"thickness\": 1.05,\n \"weight\": 0.274,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 61,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 50.142,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 61,\n \"productionLength\": 3,\n \"productionPieces\": 62,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 62,\n \"actualWeight\": 50.96,\n \"shipmentQuantity\": 62,\n \"shipmentActualWeight\": 50.96,\n \"noShipmentQuantity\": -62,\n \"noActualWeight\": -50.96,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n }\n ]\n },\n \"message\": \"success\"\n}", + "responseBody" : "{\n \"code\": 0,\n \"data\": {\n \"count\": 2089,\n \"list\": [\n {\n \"salesOrderCode\": \"SRJ20240702-39301\",\n \"orderNo\": \"39301\",\n \"materialCode\": \"KLS-001-001\",\n \"materialName\": \"KLS-001\",\n \"profileModel\": \"KLS-001\",\n \"specification\": \"20.9*50.2\",\n \"thickness\": 1.75,\n \"weight\": 0.735,\n \"orderLength\": 3.6,\n \"orderTotalQuantity\": 257,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 680.022,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 257,\n \"productionLength\": 3.6,\n \"productionPieces\": 259,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 265,\n \"actualWeight\": 701.19,\n \"shipmentQuantity\": 265,\n \"shipmentActualWeight\": 701.19,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 265,\n \"existingActualWeight\": 701.19\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39302\",\n \"orderNo\": \"39302\",\n \"materialCode\": \"KLS-001-001\",\n \"materialName\": \"KLS-001\",\n \"profileModel\": \"KLS-001\",\n \"specification\": \"20.9*50.2\",\n \"thickness\": 1.75,\n \"weight\": 0.735,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 61,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 134.505,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 122,\n \"productionLength\": 3,\n \"productionPieces\": 62,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 65,\n \"actualWeight\": 143.32,\n \"shipmentQuantity\": 65,\n \"shipmentActualWeight\": 143.32,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 65,\n \"existingActualWeight\": 143.32\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39303\",\n \"orderNo\": \"39303\",\n \"materialCode\": \"KLS-001-001\",\n \"materialName\": \"KLS-001\",\n \"profileModel\": \"KLS-001\",\n \"specification\": \"20.9*50.2\",\n \"thickness\": 1.75,\n \"weight\": 0.735,\n \"orderLength\": 4.2,\n \"orderTotalQuantity\": 20,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 61.74,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 40,\n \"productionLength\": 4.2,\n \"productionPieces\": 21,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 22,\n \"actualWeight\": 67.91,\n \"shipmentQuantity\": 22,\n \"shipmentActualWeight\": 67.91,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 22,\n \"existingActualWeight\": 67.91\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39304\",\n \"orderNo\": \"39304\",\n \"materialCode\": \"KLS-002A-001\",\n \"materialName\": \"KLS-002A\",\n \"profileModel\": \"KLS-002A\",\n \"specification\": \"55.1*54\",\n \"thickness\": 2,\n \"weight\": 1.6,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 8,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 38.4,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 16,\n \"productionLength\": 3,\n \"productionPieces\": 8,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 10,\n \"actualWeight\": 52,\n \"shipmentQuantity\": 10,\n \"shipmentActualWeight\": 52,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 10,\n \"existingActualWeight\": 52\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39305\",\n \"orderNo\": \"39305\",\n \"materialCode\": \"KLS-003-001\",\n \"materialName\": \"KLS-003\",\n \"profileModel\": \"KLS-003\",\n \"specification\": \"55.1*54\",\n \"thickness\": 2,\n \"weight\": 2.11,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 8,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 50.64,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 16,\n \"productionLength\": 3,\n \"productionPieces\": 8,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 8,\n \"actualWeight\": 55,\n \"shipmentQuantity\": 8,\n \"shipmentActualWeight\": 55,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 8,\n \"existingActualWeight\": 55\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39306\",\n \"orderNo\": \"39306\",\n \"materialCode\": \"KLS-004-001\",\n \"materialName\": \"KLS-004\",\n \"profileModel\": \"KLS-004\",\n \"specification\": \"51.23*51.03\",\n \"thickness\": 1.08,\n \"weight\": 0.316,\n \"orderLength\": 3.6,\n \"orderTotalQuantity\": 257,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 292.3632,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 514,\n \"productionLength\": 3.6,\n \"productionPieces\": 260,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 263,\n \"actualWeight\": 306,\n \"shipmentQuantity\": 263,\n \"shipmentActualWeight\": 306,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 263,\n \"existingActualWeight\": 306\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39307\",\n \"orderNo\": \"39307\",\n \"materialCode\": \"KLS-004-001\",\n \"materialName\": \"KLS-004\",\n \"profileModel\": \"KLS-004\",\n \"specification\": \"51.23*51.03\",\n \"thickness\": 1.08,\n \"weight\": 0.316,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 61,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 57.828,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 122,\n \"productionLength\": 3,\n \"productionPieces\": 62,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 60,\n \"actualWeight\": 57.99,\n \"shipmentQuantity\": 60,\n \"shipmentActualWeight\": 57.99,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 60,\n \"existingActualWeight\": 57.99\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39308\",\n \"orderNo\": \"39308\",\n \"materialCode\": \"KLS-004-001\",\n \"materialName\": \"KLS-004\",\n \"profileModel\": \"KLS-004\",\n \"specification\": \"51.23*51.03\",\n \"thickness\": 1.08,\n \"weight\": 0.316,\n \"orderLength\": 4.2,\n \"orderTotalQuantity\": 20,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 26.544,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 40,\n \"productionLength\": 4.2,\n \"productionPieces\": 20,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 20,\n \"actualWeight\": 27,\n \"shipmentQuantity\": 20,\n \"shipmentActualWeight\": 27,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 20,\n \"existingActualWeight\": 27\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39309\",\n \"orderNo\": \"39309\",\n \"materialCode\": \"KLS-005-001\",\n \"materialName\": \"KLS-005\",\n \"profileModel\": \"KLS-005\",\n \"specification\": \"21.85*19.7\",\n \"thickness\": 1.05,\n \"weight\": 0.274,\n \"orderLength\": 3.6,\n \"orderTotalQuantity\": 257,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 253.5048,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 514,\n \"productionLength\": 3.6,\n \"productionPieces\": 260,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 161,\n \"actualWeight\": 158.81,\n \"shipmentQuantity\": 161,\n \"shipmentActualWeight\": 158.81,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 161,\n \"existingActualWeight\": 158.81\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39310\",\n \"orderNo\": \"39310\",\n \"materialCode\": \"KLS-005-001\",\n \"materialName\": \"KLS-005\",\n \"profileModel\": \"KLS-005\",\n \"specification\": \"21.85*19.7\",\n \"thickness\": 1.05,\n \"weight\": 0.274,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 61,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 50.142,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 61,\n \"productionLength\": 3,\n \"productionPieces\": 62,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 62,\n \"actualWeight\": 50.96,\n \"shipmentQuantity\": 62,\n \"shipmentActualWeight\": 50.96,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 62,\n \"existingActualWeight\": 50.96\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39311\",\n \"orderNo\": \"39311\",\n \"materialCode\": \"KLS-005-001\",\n \"materialName\": \"KLS-005\",\n \"profileModel\": \"KLS-005\",\n \"specification\": \"21.85*19.7\",\n \"thickness\": 1.05,\n \"weight\": 0.274,\n \"orderLength\": 4.2,\n \"orderTotalQuantity\": 20,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 23.016,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 20,\n \"productionLength\": 4.2,\n \"productionPieces\": 20,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 20,\n \"actualWeight\": 23.02,\n \"shipmentQuantity\": 20,\n \"shipmentActualWeight\": 23.02,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 20,\n \"existingActualWeight\": 23.02\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39312\",\n \"orderNo\": \"39312\",\n \"materialCode\": \"KLS-006A-001\",\n \"materialName\": \"KLS-006A\",\n \"profileModel\": \"KLS-006A\",\n \"specification\": \"48.2*21.1\",\n \"thickness\": 1.2,\n \"weight\": 0.608,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 16,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 29.184,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 16,\n \"productionLength\": 3,\n \"productionPieces\": 17,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 20,\n \"actualWeight\": 36.48,\n \"shipmentQuantity\": 20,\n \"shipmentActualWeight\": 36.48,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 20,\n \"existingActualWeight\": 36.48\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39313\",\n \"orderNo\": \"39313\",\n \"materialCode\": \"KLS-009-001\",\n \"materialName\": \"KLS-009\",\n \"profileModel\": \"KLS-009\",\n \"specification\": \"12.2*14\",\n \"thickness\": 1.3,\n \"weight\": 0.14,\n \"orderLength\": 4,\n \"orderTotalQuantity\": 1430,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 800.8,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 1430,\n \"productionLength\": 4,\n \"productionPieces\": 1442,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 1439,\n \"actualWeight\": 834.01,\n \"shipmentQuantity\": 0,\n \"shipmentActualWeight\": 0,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39314\",\n \"orderNo\": \"39314\",\n \"materialCode\": \"KLS-011-001\",\n \"materialName\": \"1/4弯园1050*1050/R530\",\n \"profileModel\": \"KLS-011\",\n \"specification\": \"17.92*37.8\",\n \"thickness\": 1,\n \"weight\": 0.382,\n \"orderLength\": 1.77,\n \"orderTotalQuantity\": 1000,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 676.14,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 1000,\n \"productionLength\": 1.77,\n \"productionPieces\": 1012,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 1012,\n \"actualWeight\": 699.75,\n \"shipmentQuantity\": 1012,\n \"shipmentActualWeight\": 699.75,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 1012,\n \"existingActualWeight\": 699.75\n },\n {\n \"salesOrderCode\": \"SRJ20240702-39315\",\n \"orderNo\": \"39315\",\n \"materialCode\": \"KLS-012-001\",\n \"materialName\": \"KLS-012\",\n \"profileModel\": \"KLS-012\",\n \"specification\": \"33*42.4\",\n \"thickness\": 1.2,\n \"weight\": 0.765,\n \"orderLength\": 3,\n \"orderTotalQuantity\": 18,\n \"surfaceMethod\": \"哑银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 41.31,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 18,\n \"productionLength\": 3,\n \"productionPieces\": 19,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 18,\n \"actualWeight\": 67,\n \"shipmentQuantity\": 18,\n \"shipmentActualWeight\": 67,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 18,\n \"existingActualWeight\": 67\n },\n {\n \"salesOrderCode\": \"GJL20240628-39401\",\n \"orderNo\": \"39401\",\n \"materialCode\": \"G003-001\",\n \"materialName\": \"贴无字膜收缩\",\n \"profileModel\": \"G003\",\n \"specification\": \"40*3.5\",\n \"thickness\": 0,\n \"weight\": 0.229,\n \"orderLength\": 2.8,\n \"orderTotalQuantity\": 300,\n \"surfaceMethod\": \"氧化拉丝银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 192.36,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 300,\n \"productionLength\": 2.91,\n \"productionPieces\": 330,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 621,\n \"actualWeight\": 398.56,\n \"shipmentQuantity\": 621,\n \"shipmentActualWeight\": 398.56,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 621,\n \"existingActualWeight\": 398.56\n },\n {\n \"salesOrderCode\": \"GJL20240628-39402\",\n \"orderNo\": \"39402\",\n \"materialCode\": \"G003-001\",\n \"materialName\": \"贴无字膜收缩\",\n \"profileModel\": \"G003\",\n \"specification\": \"40*3.5\",\n \"thickness\": 0,\n \"weight\": 0.229,\n \"orderLength\": 2.4,\n \"orderTotalQuantity\": 50,\n \"surfaceMethod\": \"氧化拉丝银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 27.48,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 50,\n \"productionLength\": 2.51,\n \"productionPieces\": 65,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 78,\n \"actualWeight\": 43,\n \"shipmentQuantity\": 0,\n \"shipmentActualWeight\": 0,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 0,\n \"existingActualWeight\": 0\n },\n {\n \"salesOrderCode\": \"NBW20240630-39501\",\n \"orderNo\": \"39501\",\n \"materialCode\": \"A39B-003\",\n \"materialName\": \"A39B\",\n \"profileModel\": \"A39B\",\n \"specification\": \"见图\",\n \"thickness\": 1.3,\n \"weight\": 0.68,\n \"orderLength\": 5.4,\n \"orderTotalQuantity\": 130,\n \"surfaceMethod\": \"喷砂闪银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 477.36,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 130,\n \"productionLength\": 5.4,\n \"productionPieces\": 130,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 110,\n \"actualWeight\": 403.92,\n \"shipmentQuantity\": 110,\n \"shipmentActualWeight\": 403.92,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 110,\n \"existingActualWeight\": 403.92\n },\n {\n \"salesOrderCode\": \"NBW20240630-39502\",\n \"orderNo\": \"39502\",\n \"materialCode\": \"OL-HD-2-001\",\n \"materialName\": \"OL-HD-2\",\n \"profileModel\": \"OL-HD-2\",\n \"specification\": \"16.6*25\",\n \"thickness\": 1.2,\n \"weight\": 0.218,\n \"orderLength\": 4.1,\n \"orderTotalQuantity\": 130,\n \"surfaceMethod\": \"喷砂闪银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 116.194,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 130,\n \"productionLength\": 4.1,\n \"productionPieces\": 133,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 141,\n \"actualWeight\": 132.99,\n \"shipmentQuantity\": 141,\n \"shipmentActualWeight\": 132.99,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 141,\n \"existingActualWeight\": 132.99\n },\n {\n \"salesOrderCode\": \"NBW20240630-39503\",\n \"orderNo\": \"39503\",\n \"materialCode\": \"H283-001\",\n \"materialName\": \"OL-HD-7代\",\n \"profileModel\": \"H283\",\n \"specification\": \"见图\",\n \"thickness\": 1.3,\n \"weight\": 0.296,\n \"orderLength\": 4.1,\n \"orderTotalQuantity\": 248,\n \"surfaceMethod\": \"喷砂闪银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 300.9728,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 248,\n \"productionLength\": 4.1,\n \"productionPieces\": 248,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 248,\n \"actualWeight\": 310,\n \"shipmentQuantity\": 248,\n \"shipmentActualWeight\": 310,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 248,\n \"existingActualWeight\": 310\n },\n {\n \"salesOrderCode\": \"NBW20240630-39504\",\n \"orderNo\": \"39504\",\n \"materialCode\": \"H282-003\",\n \"materialName\": \"H282\",\n \"profileModel\": \"H282\",\n \"specification\": \"见图\",\n \"thickness\": 1.3,\n \"weight\": 0.402,\n \"orderLength\": 4.1,\n \"orderTotalQuantity\": 248,\n \"surfaceMethod\": \"喷砂闪银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 408.7536,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 248,\n \"productionLength\": 4.1,\n \"productionPieces\": 248,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 248,\n \"actualWeight\": 410,\n \"shipmentQuantity\": 248,\n \"shipmentActualWeight\": 410,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 248,\n \"existingActualWeight\": 410\n },\n {\n \"salesOrderCode\": \"NBW20240630-39505\",\n \"orderNo\": \"39505\",\n \"materialCode\": \"H283-001\",\n \"materialName\": \"OL-HD-7代\",\n \"profileModel\": \"H283\",\n \"specification\": \"见图\",\n \"thickness\": 1.3,\n \"weight\": 0.296,\n \"orderLength\": 4,\n \"orderTotalQuantity\": 100,\n \"surfaceMethod\": \"喷砂闪银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 118.4,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 100,\n \"productionLength\": 4,\n \"productionPieces\": 100,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 100,\n \"actualWeight\": 120,\n \"shipmentQuantity\": 100,\n \"shipmentActualWeight\": 120,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 100,\n \"existingActualWeight\": 120\n },\n {\n \"salesOrderCode\": \"NBW20240630-39506\",\n \"orderNo\": \"39506\",\n \"materialCode\": \"H282-003\",\n \"materialName\": \"H282\",\n \"profileModel\": \"H282\",\n \"specification\": \"见图\",\n \"thickness\": 1.3,\n \"weight\": 0.402,\n \"orderLength\": 4,\n \"orderTotalQuantity\": 100,\n \"surfaceMethod\": \"喷砂闪银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 160.8,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 100,\n \"productionLength\": 4,\n \"productionPieces\": 103,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 106,\n \"actualWeight\": 170.45,\n \"shipmentQuantity\": 106,\n \"shipmentActualWeight\": 170.45,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 106,\n \"existingActualWeight\": 170.45\n },\n {\n \"salesOrderCode\": \"GJL20240630-39601\",\n \"orderNo\": \"39601\",\n \"materialCode\": \"G-004-001\",\n \"materialName\": \"贴无字膜收缩\",\n \"profileModel\": \"G-004\",\n \"specification\": \"35*3.5\",\n \"thickness\": 0,\n \"weight\": 0.202,\n \"orderLength\": 2.7,\n \"orderTotalQuantity\": 600,\n \"surfaceMethod\": \"氧化拉丝银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 327.24,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 600,\n \"productionLength\": 2.81,\n \"productionPieces\": 630,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 640,\n \"actualWeight\": 349.06,\n \"shipmentQuantity\": 640,\n \"shipmentActualWeight\": 349.06,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 640,\n \"existingActualWeight\": 349.06\n },\n {\n \"salesOrderCode\": \"GJL20240630-39602\",\n \"orderNo\": \"39602\",\n \"materialCode\": \"G-004-001\",\n \"materialName\": \"贴无字膜收缩\",\n \"profileModel\": \"G-004\",\n \"specification\": \"35*3.5\",\n \"thickness\": 0,\n \"weight\": 0.202,\n \"orderLength\": 2.5,\n \"orderTotalQuantity\": 1000,\n \"surfaceMethod\": \"氧化拉丝银\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 505,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 1000,\n \"productionLength\": 2.61,\n \"productionPieces\": 1050,\n \"sawingMethod\": \"一开一\",\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 1056,\n \"actualWeight\": 533.28,\n \"shipmentQuantity\": 1056,\n \"shipmentActualWeight\": 533.28,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 1056,\n \"existingActualWeight\": 533.28\n },\n {\n \"salesOrderCode\": \"WTME20240702-39701W\",\n \"orderNo\": \"39701W\",\n \"materialCode\": \"LCZ110-001\",\n \"materialName\": \"LCZ110\",\n \"profileModel\": \"LCZ110\",\n \"specification\": \"见图纸\",\n \"thickness\": 1,\n \"weight\": 0.51,\n \"orderLength\": 1.829,\n \"orderTotalQuantity\": 214,\n \"surfaceMethod\": \"哑黑\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 199.6171,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 214,\n \"productionLength\": 3.768,\n \"productionPieces\": 214,\n \"sawingMethod\": null,\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 228,\n \"actualWeight\": 212.68,\n \"shipmentQuantity\": 228,\n \"shipmentActualWeight\": 212.68,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 228,\n \"existingActualWeight\": 212.68\n },\n {\n \"salesOrderCode\": \"WTME20240702-39702W\",\n \"orderNo\": \"39702W\",\n \"materialCode\": \"LCT036-001\",\n \"materialName\": \"LCT036\",\n \"profileModel\": \"LCT036\",\n \"specification\": \"见图纸\",\n \"thickness\": 1,\n \"weight\": 0.576,\n \"orderLength\": 1.799,\n \"orderTotalQuantity\": 180,\n \"surfaceMethod\": \"哑黑\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 186.5203,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 180,\n \"productionLength\": 3.708,\n \"productionPieces\": 180,\n \"sawingMethod\": null,\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 191,\n \"actualWeight\": 197.92,\n \"shipmentQuantity\": 191,\n \"shipmentActualWeight\": 197.92,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 191,\n \"existingActualWeight\": 197.92\n },\n {\n \"salesOrderCode\": \"WTME20240702-39703W\",\n \"orderNo\": \"39703W\",\n \"materialCode\": \"LCT037-001\",\n \"materialName\": \"LCT037\",\n \"profileModel\": \"LCT037\",\n \"specification\": \"见图纸\",\n \"thickness\": 1,\n \"weight\": 0.427,\n \"orderLength\": 1.829,\n \"orderTotalQuantity\": 240,\n \"surfaceMethod\": \"哑黑\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 187.4359,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 240,\n \"productionLength\": 3.768,\n \"productionPieces\": 240,\n \"sawingMethod\": null,\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 243,\n \"actualWeight\": 189.78,\n \"shipmentQuantity\": 243,\n \"shipmentActualWeight\": 189.78,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 243,\n \"existingActualWeight\": 189.78\n },\n {\n \"salesOrderCode\": \"ZL20240702-39801\",\n \"orderNo\": \"39801\",\n \"materialCode\": \"C0103-001\",\n \"materialName\": \"贴膜\",\n \"profileModel\": \"C0103\",\n \"specification\": \"37.7*49\",\n \"thickness\": 0,\n \"weight\": 0.192,\n \"orderLength\": 4.3,\n \"orderTotalQuantity\": 2000,\n \"surfaceMethod\": \"深琥珀不抛光\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 1651.2,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 2000,\n \"productionLength\": 4.3,\n \"productionPieces\": 2080,\n \"sawingMethod\": null,\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 2085,\n \"actualWeight\": 2033.75,\n \"shipmentQuantity\": 2085,\n \"shipmentActualWeight\": 2033.75,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 2085,\n \"existingActualWeight\": 2033.75\n },\n {\n \"salesOrderCode\": \"ZL20240702-39802\",\n \"orderNo\": \"39802\",\n \"materialCode\": \"C0103-001\",\n \"materialName\": \"贴膜\",\n \"profileModel\": \"C0103\",\n \"specification\": \"37.7*49\",\n \"thickness\": 0,\n \"weight\": 0.192,\n \"orderLength\": 3.9,\n \"orderTotalQuantity\": 1000,\n \"surfaceMethod\": \"深琥珀不抛光\",\n \"deliveryDate\": 1725206400000,\n \"theoreticalWeight\": 748.8,\n \"producedPieces\": 0,\n \"producedLength\": 0,\n \"plannedPieces\": 1000,\n \"productionLength\": 3.9,\n \"productionPieces\": 1050,\n \"sawingMethod\": null,\n \"longScrapNumber\": 0,\n \"longScrapWeight\": 0,\n \"shortageScrapNumber\": 0,\n \"shortageScrapWeight\": 0,\n \"jiya_actualWeight\": 0,\n \"jiya_productionNumber\": 0,\n \"jiya_productionWeight\": 0,\n \"jingpin_actualWeight\": 0,\n \"jingpin_productionNumber\": 0,\n \"jingpin_productionWeight\": 0,\n \"yanghau1_actualWeight\": 0,\n \"yanghau1_productionNumber\": 0,\n \"yanghau1_productionWeight\": 0,\n \"yanghua2_actualWeight\": 0,\n \"yanghua2_productionNumber\": 0,\n \"yanghua2_productionWeight\": 0,\n \"jingqie_actualWeight\": 0,\n \"jingqie_productionNumber\": 0,\n \"jingqie_productionWeight\": 0,\n \"dk_actualWeight\": 0,\n \"dk_productionNumber\": 0,\n \"dk_productionWeight\": 0,\n \"bz_actualWeight\": 0,\n \"bz_productionNumber\": 0,\n \"bz_productionWeight\": 0,\n \"receiptQuantity\": 1099,\n \"actualWeight\": 868.71,\n \"shipmentQuantity\": 1099,\n \"shipmentActualWeight\": 868.71,\n \"noShipmentQuantity\": 0,\n \"noActualWeight\": 0,\n \"existingInventory\": 1099,\n \"existingActualWeight\": 868.71\n }\n ]\n },\n \"message\": \"success\"\n}", "description" : null, "requestBodyDefinition" : null, "responseBodyDefinition" : null } ================================ -// ============================== -// 1.查询销售单明细 -// ============================== -var sql = """ - select - msom.sales_order_code, - msom.order_no, - msom.material_code, - msom.material_name, - msom.profile_model, - msom.specification, - msom.thickness, - msom.weight, - msom.order_length, - msom.order_total_quantity, - msom.surface_method, - msom.delivery_date, - msom.theoretical_weight, - msom.produced_pieces, - msom.produced_length - from mini_sales_order_materials msom -""" +// String salesOrderCode = body['salesOrderCode']; +// String orderNo = body['orderNo']; +// String materialCode = body['materialCode']; +// String profileModel = body['profileModel']; +// String customerId = body['customerId']; +// String surfaceMethod = body['surfaceMethod']; -Map pages = db.page(sql); +// // ============================== +// // 1.查询销售单明细 +// // ============================== +// var sql = """ +// select +// msom.sales_order_code, +// msom.order_no, +// msom.material_code, +// msom.material_name, +// msom.profile_model, +// msom.specification, +// msom.thickness, +// msom.weight, +// msom.order_length, +// msom.order_total_quantity, +// msom.surface_method, +// msom.delivery_date, +// msom.theoretical_weight, +// msom.produced_pieces, +// msom.produced_length +// from mini_sales_order_materials msom +// left join mini_sales_orders mso on mso.document_number = msom.sales_order_code +// where 1=1 +// ?{orderNo != null and orderNo != '', and msom.order_no like concat('%', #{orderNo}, '%')} +// ?{materialCode != null and materialCode != '', and msom.material_code like concat('%', #{materialCode}, '%')} +// ?{profileModel != null and profileModel != '', and msom.profile_model like concat('%', #{profileModel}, '%')} +// ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} +// ?{surfaceMethod != null and surfaceMethod != '', and msom.surface_method = #{surfaceMethod}} +// ?{salesOrderCode != null and salesOrderCode != '', and msom.sales_order_code = #{salesOrderCode}} +// """ -List salesOrderList = pages.list; +// Map pages = db.page(sql); -// ============================== -// 2.查询生产计划数据 -// ============================== -var sql2 = """ - select - sales_order_code, - order_no, - sum(planned_pieces) as planned_pieces - from mini_production_schedule - where 1=1 and (sales_order_code, order_no) in ( - - (#{item.salesOrderCode}, #{item.orderNo}) - - ) - group by sales_order_code, order_no -""" -List productionScheduleList = db.select(sql2) +// List salesOrderList = pages.list; +// if (pages.count == 0) { +// return { +// count: 0, +// list: [] +// } +// } -// ============================== -// 3.查询挤压排产数据 -// ============================== -var sql3 = """ - select - sales_order_code, - order_no, - sum(production_length) as production_length, - sum(production_pieces) as production_pieces, - max(sawing_method) as sawing_method - from mini_extrusion_schedule_detail - where 1=1 and (sales_order_code, order_no) in ( - - (#{item.salesOrderCode}, #{item.orderNo}) - - ) - group by sales_order_code, order_no -""" -List extrusionScheduleDetail = db.select(sql3) +// // ============================== +// // 2.查询生产计划数据 +// // ============================== +// var sql2 = """ +// select +// sales_order_code, +// order_no, +// sum(planned_pieces) as planned_pieces +// from mini_production_schedule +// where 1=1 and (sales_order_code, order_no) in ( +// +// (#{item.salesOrderCode}, #{item.orderNo}) +// +// ) +// group by sales_order_code, order_no +// """ +// List productionScheduleList = db.select(sql2) -// ============================== -// 4.查询报工数据 -// ============================== -var sql4 = """ - select - mpr.sales_order_code, - mpr.order_no, - mpr.current_process, - (sum(mesd.production_length) * sum(production_number) * sum(production_weight)) as actual_weight_mesd, - (sum(msom.order_length) * sum(production_number) * sum(production_weight)) as actual_weight_msom, - sum(production_number) as production_number, - max(production_weight) as production_weight - from mini_process_report mpr - left join mini_extrusion_schedule_detail mesd - on mpr.sales_order_code = mesd.sales_order_code and mpr.order_no = mesd.order_no - left join mini_sales_order_materials msom - on mpr.sales_order_code = msom.sales_order_code and mpr.order_no = msom.order_no - where 1=1 and (mpr.sales_order_code, mpr.order_no) in ( - - (#{item.salesOrderCode}, #{item.orderNo}) - - ) - group by mpr.sales_order_code, mpr.order_no, mpr.current_process -""" +// // ============================== +// // 3.查询挤压排产数据 +// // ============================== +// var sql3 = """ +// select +// sales_order_code, +// order_no, +// group_concat(schedule_number order by schedule_number separator ', ') as schedule_number, +// sum(production_length) as production_length, +// sum(production_pieces) as production_pieces, +// max(sawing_method) as sawing_method +// from mini_extrusion_schedule_detail +// where 1=1 and (sales_order_code, order_no) in ( +// +// (#{item.salesOrderCode}, #{item.orderNo}) +// +// ) +// group by sales_order_code, order_no +// """ +// List extrusionScheduleDetail = db.select(sql3) -List processReportList = db.select(sql4) +// // ============================== +// // 4.查询报工数据 +// // ============================== +// var sql4 = """ +// select +// mpr.sales_order_code, +// mpr.order_no, +// mpr.current_process, +// (sum(mesd.production_length) * sum(production_number) * sum(production_weight)) as actual_weight_mesd, +// (sum(msom.order_length) * sum(production_number) * sum(production_weight)) as actual_weight_msom, +// sum(production_number) as production_number, +// max(production_weight) as production_weight +// from mini_process_report mpr +// left join mini_extrusion_schedule_detail mesd +// on mpr.sales_order_code = mesd.sales_order_code and mpr.order_no = mesd.order_no +// left join mini_sales_order_materials msom +// on mpr.sales_order_code = msom.sales_order_code and mpr.order_no = msom.order_no +// where 1=1 and (mpr.sales_order_code, mpr.order_no) in ( +// +// (#{item.salesOrderCode}, #{item.orderNo}) +// +// ) +// group by mpr.sales_order_code, mpr.order_no, mpr.current_process +// """ -// 处理数据 -// actualWeightMesd 排产长度计算 -// actualWeightMsom 订单长度计算 -var processReportFinalList = [] -var arr = ['jingqie','dk','bz'] -processReportList.group(it => it.salesOrderCode + "_" + it.orderNo, // 根据api_group_id 分组 - list => list.group(item => item.currentProcess, - obj => obj - ) -).each((key, value) => { - var jsonObj = {} - value.each((key1, value1) => { - var val = value1[0]; - jsonObj["salesOrderCode"] = val.salesOrderCode; - jsonObj["orderNo"] = val.orderNo; - if (arr.contains(key1)) { - jsonObj[key1 + "_actualWeight"] = val.actualWeightMsom; - } else { - jsonObj[key1 + "_actualWeight"] = val.actualWeightMesd; - } + +// List processReportList = db.select(sql4) + +// // 处理数据 +// // actualWeightMesd 排产长度计算 +// // actualWeightMsom 订单长度计算 +// var processReportFinalList = [] +// var arr = ['jingqie','dk','bz'] +// processReportList.group(it => it.salesOrderCode + "_" + it.orderNo, // 根据api_group_id 分组 +// list => list.group(item => item.currentProcess, +// obj => obj +// ) +// ).each((key, value) => { +// var jsonObj = {} +// value.each((key1, value1) => { +// var val = value1[0]; +// jsonObj["salesOrderCode"] = val.salesOrderCode; +// jsonObj["orderNo"] = val.orderNo; +// if (arr.contains(key1)) { +// jsonObj[key1 + "_actualWeight"] = val.actualWeightMsom; +// } else { +// jsonObj[key1 + "_actualWeight"] = val.actualWeightMesd; +// } - jsonObj[key1 + "_productionNumber"] = val.productionNumber; - jsonObj[key1 + "_productionWeight"] = val.productionWeight; - }) - processReportFinalList.push(jsonObj) -}) +// jsonObj[key1 + "_productionNumber"] = val.productionNumber; +// jsonObj[key1 + "_productionWeight"] = val.productionWeight; +// }) +// processReportFinalList.push(jsonObj) +// }) + + +// // ============================== +// // 5.查询长料报废数据 +// // 挤压、精品、氧化上排、氧化下排工序 +// // ============================== +// var sql5 = """ +// select +// sales_order_code, +// order_no, +// sum(scrap_number) as long_scrap_number, +// sum(scrap_weight) as long_scrap_weight +// from mini_process_report mpr +// where 1=1 and mpr.current_process in ('jiya','jinpin','yanghua1','yanghua2') +// and (mpr.sales_order_code, mpr.order_no) in ( +// +// (#{item.salesOrderCode}, #{item.orderNo}) +// +// ) +// group by mpr.sales_order_code, mpr.order_no +// """ +// List processReportLongList = db.select(sql5) + +// // ============================== +// // 6.查询短料报废数据 +// // 精切,打孔,包装工序 +// // ============================== +// var sql6 = """ +// select +// sales_order_code, +// order_no, +// sum(scrap_number) as shortage_scrap_number, +// sum(scrap_weight) as shortage_scrap_weight +// from mini_process_report mpr +// where 1=1 and mpr.current_process in ('jingqie','dk','bz') +// and (mpr.sales_order_code, mpr.order_no) in ( +// +// (#{item.salesOrderCode}, #{item.orderNo}) +// +// ) +// group by mpr.sales_order_code, mpr.order_no +// """ +// List processReportShortageList = db.select(sql6) +// // ============================== +// // 7.入库状况 +// // ============================== +// var sql7 = """ +// select +// mpr.sales_order_code, +// mpr.order_no, +// sum(mpr.receipt_quantity) as receipt_quantity, +// sum(mpr.actual_weight) as actual_weight +// from +// mini_product_receipt mpr +// where 1=1 +// and (mpr.sales_order_code, mpr.order_no) in ( +// +// (#{item.salesOrderCode}, #{item.orderNo}) +// +// ) +// group by mpr.sales_order_code, mpr.order_no +// """ +// List productReceiptList = db.select(sql7) -// ============================== -// 5.查询长料报废数据 -// 挤压、精品、氧化上排、氧化下排工序 -// ============================== -var sql5 = """ - select - sales_order_code, - order_no, - sum(scrap_number) as long_scrap_number, - sum(scrap_weight) as long_scrap_weight - from mini_process_report mpr - where 1=1 and mpr.current_process in ('jiya','jinpin','yanghua1','yanghua2') - and (mpr.sales_order_code, mpr.order_no) in ( - - (#{item.salesOrderCode}, #{item.orderNo}) - - ) - group by mpr.sales_order_code, mpr.order_no -""" -List processReportLongList = db.select(sql5) +// // ============================== +// // 8.出库和库存数据 +// // ============================== +// // (sum(mwp.existing_inventory) - sum(mssm.shipment_quantity)) as no_shipment_quantity, +// // (sum(mwp.actual_weight) - sum(mssm.actual_weight)) as no_actual_weight, +// var sql8 = """ +// select +// mssm.sales_order_code, +// mssm.order_no, +// sum(mssm.shipment_quantity) as shipment_quantity, +// sum(mssm.actual_weight) as shipment_actual_weight, +// sum(mwp.existing_inventory) as no_shipment_quantity, +// sum(mwp.actual_weight) as no_actual_weight, +// (sum(mwp.existing_inventory) + sum(mssm.shipment_quantity)) as existing_inventory, +// (sum(mwp.actual_weight) + sum(mssm.actual_weight)) as existing_actual_weight +// from +// mini_sales_shipment_materials mssm +// left join mini_warehouse_product mwp on +// mwp.order_no = mssm.order_no +// and mwp.sales_order_code = mssm.sales_order_code +// where 1=1 +// and (mssm.sales_order_code, mssm.order_no) in ( +// +// (#{item.salesOrderCode}, #{item.orderNo}) +// +// ) +// group by mssm.sales_order_code, mssm.order_no +// """ +// List salesShipmenList = db.select(sql8) -// ============================== -// 6.查询短料报废数据 -// 精切,打孔,包装工序 -// ============================== -var sql6 = """ - select - sales_order_code, - order_no, - sum(scrap_number) as shortage_scrap_number, - sum(scrap_weight) as shortage_scrap_weight - from mini_process_report mpr - where 1=1 and mpr.current_process in ('jingqie','dk','bz') - and (mpr.sales_order_code, mpr.order_no) in ( - - (#{item.salesOrderCode}, #{item.orderNo}) - - ) - group by mpr.sales_order_code, mpr.order_no -""" -List processReportShortageList = db.select(sql6) +// var result = select +// a.*, +// b.plannedPieces, +// c.productionLength, +// c.productionPieces, +// c.sawingMethod, +// ifnull(e.longScrapNumber, 0) longScrapNumber, +// ifnull(e.longScrapWeight, 0) longScrapWeight, +// ifnull(f.shortageScrapNumber, 0) shortageScrapNumber, +// ifnull(f.shortageScrapWeight, 0) shortageScrapWeight, +// ifnull(d.jiya_actualWeight, 0) jiya_actualWeight, +// ifnull(d.jiya_productionNumber, 0) jiya_productionNumber, +// ifnull(d.jiya_productionWeight, 0) jiya_productionWeight, +// ifnull(d.jingpin_actualWeight, 0) jingpin_actualWeight, +// ifnull(d.jingpin_productionNumber, 0) jingpin_productionNumber, +// ifnull(d.jingpin_productionWeight, 0) jingpin_productionWeight, +// ifnull(d.yanghau1_actualWeight, 0) yanghau1_actualWeight, +// ifnull(d.yanghau1_productionNumber, 0) yanghau1_productionNumber, +// ifnull(d.yanghau1_productionWeight, 0) yanghau1_productionWeight, +// ifnull(d.yanghua2_actualWeight, 0) yanghua2_actualWeight, +// ifnull(d.yanghua2_productionNumber, 0) yanghua2_productionNumber, +// ifnull(d.yanghua2_productionWeight, 0) yanghua2_productionWeight, +// ifnull(d.jingqie_actualWeight, 0) jingqie_actualWeight, +// ifnull(d.jingqie_productionNumber, 0) jingqie_productionNumber, +// ifnull(d.jingqie_productionWeight, 0) jingqie_productionWeight, +// ifnull(d.dk_actualWeight, 0) dk_actualWeight, +// ifnull(d.dk_productionNumber, 0) dk_productionNumber, +// ifnull(d.dk_productionWeight, 0) dk_productionWeight, +// ifnull(d.bz_actualWeight, 0) bz_actualWeight, +// ifnull(d.bz_productionNumber, 0) bz_productionNumber, +// ifnull(d.bz_productionWeight, 0) bz_productionWeight, +// ifnull(g.receiptQuantity, 0) receiptQuantity, +// ifnull(g.actualWeight, 0) actualWeight, +// ifnull(h.shipmentQuantity, 0) shipmentQuantity, +// ifnull(h.shipmentActualWeight, 0) shipmentActualWeight, +// ifnull(h.noShipmentQuantity, 0) noShipmentQuantity, +// ifnull(h.noActualWeight, 0) noActualWeight, +// ifnull(h.existingInventory, 0) existingInventory, +// ifnull(h.existingActualWeight, 0) existingActualWeight +// from salesOrderList a +// left join productionScheduleList b on a.salesOrderCode = b.salesOrderCode and a.orderNo = b.orderNo +// left join extrusionScheduleDetail c on a.salesOrderCode = c.salesOrderCode and a.orderNo = c.orderNo +// left join processReportFinalList d on a.salesOrderCode = d.salesOrderCode and a.orderNo = d.orderNo +// left join processReportLongList e on a.salesOrderCode = e.salesOrderCode and a.orderNo = e.orderNo +// left join processReportShortageList f on a.salesOrderCode = f.salesOrderCode and a.orderNo = f.orderNo +// left join productReceiptList g on a.salesOrderCode = g.salesOrderCode and a.orderNo = g.orderNo +// left join salesShipmenList h on a.salesOrderCode = h.salesOrderCode and a.orderNo = h.orderNo +// return { +// count: pages.count, +// list: result +// } -// ============================== -// 7.入库状况 -// ============================== -var sql7 = """ - select - mpr.sales_order_code, - mpr.order_no, - sum(mpr.receipt_quantity) as receipt_quantity, - sum(mpr.actual_weight) as actual_weight - from - mini_product_receipt mpr - where 1=1 - and (mpr.sales_order_code, mpr.order_no) in ( - - (#{item.salesOrderCode}, #{item.orderNo}) - - ) - group by mpr.sales_order_code, mpr.order_no -""" -List productReceiptList = db.select(sql7) -// ============================== -// 8.出库和库存数据 -// ============================== - // (sum(mwp.existing_inventory) - sum(mssm.shipment_quantity)) as no_shipment_quantity, - // (sum(mwp.actual_weight) - sum(mssm.actual_weight)) as no_actual_weight, -var sql8 = """ - select - mssm.sales_order_code, - mssm.order_no, - sum(mssm.shipment_quantity) as shipment_quantity, - sum(mssm.actual_weight) as shipment_actual_weight, - sum(mwp.existing_inventory) as no_shipment_quantity, - sum(mwp.actual_weight) as no_actual_weight, - (sum(mwp.existing_inventory) + sum(mssm.shipment_quantity)) as existing_inventory, - (sum(mwp.actual_weight) + sum(mssm.actual_weight)) as existing_actual_weight - from - mini_sales_shipment_materials mssm - left join mini_warehouse_product mwp on - mwp.order_no = mssm.order_no - and mwp.sales_order_code = mssm.sales_order_code - where 1=1 - and (mssm.sales_order_code, mssm.order_no) in ( - - (#{item.salesOrderCode}, #{item.orderNo}) - - ) - group by mssm.sales_order_code, mssm.order_no -""" -List salesShipmenList = db.select(sql8) +import '@/sql/orderTracking/count' as masterFind; +import '@/sql/orderTracking/list' as orderTracking; +int count = masterFind(body); + +if (count == 0) { + return { + count: 0, + list: [] + } +} + +var result = orderTracking(body) -var result = select - a.*, - b.plannedPieces, - c.productionLength, - c.productionPieces, - c.sawingMethod, - ifnull(e.longScrapNumber, 0) longScrapNumber, - ifnull(e.longScrapWeight, 0) longScrapWeight, - ifnull(f.shortageScrapNumber, 0) shortageScrapNumber, - ifnull(f.shortageScrapWeight, 0) shortageScrapWeight, - ifnull(d.jiya_actualWeight, 0) jiya_actualWeight, - ifnull(d.jiya_productionNumber, 0) jiya_productionNumber, - ifnull(d.jiya_productionWeight, 0) jiya_productionWeight, - ifnull(d.jingpin_actualWeight, 0) jingpin_actualWeight, - ifnull(d.jingpin_productionNumber, 0) jingpin_productionNumber, - ifnull(d.jingpin_productionWeight, 0) jingpin_productionWeight, - ifnull(d.yanghau1_actualWeight, 0) yanghau1_actualWeight, - ifnull(d.yanghau1_productionNumber, 0) yanghau1_productionNumber, - ifnull(d.yanghau1_productionWeight, 0) yanghau1_productionWeight, - ifnull(d.yanghua2_actualWeight, 0) yanghua2_actualWeight, - ifnull(d.yanghua2_productionNumber, 0) yanghua2_productionNumber, - ifnull(d.yanghua2_productionWeight, 0) yanghua2_productionWeight, - ifnull(d.jingqie_actualWeight, 0) jingqie_actualWeight, - ifnull(d.jingqie_productionNumber, 0) jingqie_productionNumber, - ifnull(d.jingqie_productionWeight, 0) jingqie_productionWeight, - ifnull(d.dk_actualWeight, 0) dk_actualWeight, - ifnull(d.dk_productionNumber, 0) dk_productionNumber, - ifnull(d.dk_productionWeight, 0) dk_productionWeight, - ifnull(d.bz_actualWeight, 0) bz_actualWeight, - ifnull(d.bz_productionNumber, 0) bz_productionNumber, - ifnull(d.bz_productionWeight, 0) bz_productionWeight, - ifnull(g.receiptQuantity, 0) receiptQuantity, - ifnull(g.actualWeight, 0) actualWeight, - ifnull(h.shipmentQuantity, 0) shipmentQuantity, - ifnull(h.shipmentActualWeight, 0) shipmentActualWeight, - ifnull(h.noShipmentQuantity, 0) noShipmentQuantity, - ifnull(h.noActualWeight, 0) noActualWeight, - ifnull(h.existingInventory, 0) existingInventory, - ifnull(h.existingActualWeight, 0) existingActualWeight - from salesOrderList a - left join productionScheduleList b on a.salesOrderCode = b.salesOrderCode and a.orderNo = b.orderNo - left join extrusionScheduleDetail c on a.salesOrderCode = c.salesOrderCode and a.orderNo = c.orderNo - left join processReportList d on a.salesOrderCode = d.salesOrderCode and a.orderNo = d.orderNo - left join processReportLongList e on a.salesOrderCode = e.salesOrderCode and a.orderNo = e.orderNo - left join processReportShortageList f on a.salesOrderCode = f.salesOrderCode and a.orderNo = f.orderNo - left join productReceiptList g on a.salesOrderCode = g.salesOrderCode and a.orderNo = g.orderNo - left join salesShipmenList h on a.salesOrderCode = h.salesOrderCode and a.orderNo = h.orderNo return { - count: pages.count, + count: count, list: result -} +} \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/详情列表.ms b/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/详情列表.ms index b1af4f7..ea990a5 100644 --- a/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/详情列表.ms +++ b/appengine/src/main/resources/api_file/api/web管理端API/销售管理/销售订单管理/详情列表.ms @@ -5,7 +5,7 @@ "groupId" : "e631b317606f4246ac82585a7c1f1c5b", "name" : "详情列表", "createTime" : null, - "updateTime" : 1732266000158, + "updateTime" : 1732591664784, "lock" : null, "createBy" : null, "updateBy" : null, @@ -25,6 +25,12 @@ String salesOrderCode = body.salesOrderCode; String status = body.status; +String orderNo = body['orderNo']; +String materialCode = body['materialCode']; +String profileModel = body['profileModel']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + return db.page(""" select msom.id, @@ -78,8 +84,11 @@ return db.page(""" left join sys_user su on su.user_id = mso.salesperson left join mini_customer_info mci on mci.customer_code = mso.customer_id where 1=1 - ?{salesOrderCode != null and salesOrderCode != "", - and msom.sales_order_code list concat('%',#{salesOrderCode},'%') } - ?{status != null and status != "", - and msom.status = #{status} } + ?{salesOrderCode != null and salesOrderCode != "", and msom.sales_order_code list concat('%',#{salesOrderCode},'%') } + ?{status != null and status != "", and msom.status = #{status} } + ?{orderNo != null and orderNo != '', and msom.order_no like concat('%', #{orderNo}, '%')} + ?{materialCode != null and materialCode != '', and msom.material_code like concat('%', #{materialCode}, '%')} + ?{profileModel != null and profileModel != '', and msom.profile_model like concat('%', #{profileModel}, '%')} + ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and msom.surface_method = #{surfaceMethod}} """) \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/function/数据处理/挤压排产/group.json b/appengine/src/main/resources/api_file/function/数据处理/挤压排产/group.json new file mode 100644 index 0000000..7130018 --- /dev/null +++ b/appengine/src/main/resources/api_file/function/数据处理/挤压排产/group.json @@ -0,0 +1,14 @@ +{ + "properties" : { }, + "id" : "753fe736c4d7438090c366180c352d95", + "name" : "挤压排产", + "type" : "function", + "parentId" : "414d04bbdc2e4cb5a23145a0bfe0e649", + "path" : "extrusionSchedule", + "createTime" : 1732610226287, + "updateTime" : null, + "createBy" : null, + "updateBy" : null, + "paths" : [ ], + "options" : [ ] +} \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/function/数据处理/挤压排产/挤压排产列表.ms b/appengine/src/main/resources/api_file/function/数据处理/挤压排产/挤压排产列表.ms new file mode 100644 index 0000000..012f283 --- /dev/null +++ b/appengine/src/main/resources/api_file/function/数据处理/挤压排产/挤压排产列表.ms @@ -0,0 +1,69 @@ +{ + "properties" : { }, + "id" : "7f8e4140006446d28b625fcb7aa6b967", + "script" : null, + "groupId" : "753fe736c4d7438090c366180c352d95", + "name" : "挤压排产列表", + "createTime" : null, + "updateTime" : 1732611845401, + "lock" : null, + "createBy" : null, + "updateBy" : null, + "path" : "/list", + "description" : null, + "returnType" : null, + "mappingPath" : null, + "parameters" : [ ] +} +================================ +import '@/common/sql' as sql + +String salesOrdeSelect = sql("salesOrder") +String scheduleNumber = body["scheduleNumber"]; +String salesOrderCode = body["salesOrderCode"]; +String orderNo = body["orderNo"]; +String materialCode = body["materialCode"]; +String profileModel = body["profileModel"]; +String salesStatus = body["salesStatus"]; + +String extrusionDate = body['extrusionDate']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + +var list = db.page(""" + select + date_format(mes.extrusion_date, '%Y-%m-%d') as extrusion_date, + mes.extrusion_machine, + mpm.machine_name as extrusion_machine_name, + mes.extrusion_team, + su.user_name as extrusion_team_name, + mesd.schedule_number, + mesd.production_length, + mesd.production_pieces, + mesd.sawing_method, + su2.user_name as salesperson_name, + ${salesOrdeSelect} + from + mini_extrusion_schedule_detail mesd + left join mini_extrusion_schedule mes on mes.schedule_number = mesd.schedule_number + left join sys_user su on su.user_id = mes.extrusion_team + left join mini_production_machines mpm on mpm.machine_code = mes.extrusion_machine + + left join mini_sales_order_materials msm + on mesd.sales_order_code = msm.sales_order_code and mesd.material_code = msm.material_code and mesd.order_no = msm.order_no + left join mini_sales_orders mso on mso.document_number = msm.sales_order_code + left join sys_user su2 on su2.user_id = mso.salesperson + where 1=1 + ?{scheduleNumber != null and scheduleNumber != '', and mesd.schedule_number like concat('%', #{scheduleNumber}, '%')} + ?{salesOrderCode != null and salesOrderCode != '', and msm.sales_order_code like concat('%', #{salesOrderCode}, '%')} + ?{orderNo != null and orderNo != '', and msm.order_no like concat('%', #{orderNo}, '%')} + ?{materialCode != null and materialCode != '', and msm.material_code like concat('%', #{materialCode}, '%')} + ?{profileModel != null and profileModel != '', and msm.profile_model like concat('%', #{profileModel}, '%')} + ?{salesStatus != null and salesStatus != '', and mso.status = #{salesStatus}} + + ?{extrusionDate!=null && extrusionDate!="", and date(mes.extrusion_date) = #{extrusionDate} } + ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and msm.surface_method = #{surfaceMethod}} +""") + +return list.list diff --git a/appengine/src/main/resources/api_file/function/数据处理/挤压排产/挤压排产总数.ms b/appengine/src/main/resources/api_file/function/数据处理/挤压排产/挤压排产总数.ms new file mode 100644 index 0000000..671cdcd --- /dev/null +++ b/appengine/src/main/resources/api_file/function/数据处理/挤压排产/挤压排产总数.ms @@ -0,0 +1,69 @@ +{ + "properties" : { }, + "id" : "78482de7c59040fe9939e6628c02ee0f", + "script" : null, + "groupId" : "753fe736c4d7438090c366180c352d95", + "name" : "挤压排产总数", + "createTime" : null, + "updateTime" : 1732611825930, + "lock" : null, + "createBy" : null, + "updateBy" : null, + "path" : "/count", + "description" : null, + "returnType" : null, + "mappingPath" : null, + "parameters" : [ { + "name" : "body", + "value" : null, + "description" : null, + "required" : false, + "dataType" : "String", + "type" : null, + "defaultValue" : null, + "validateType" : null, + "error" : null, + "expression" : null, + "children" : null + } ] +} +================================ +import '@/common/sql' as sql + +String salesOrdeSelect = sql("salesOrder") +String scheduleNumber = body["scheduleNumber"]; +String salesOrderCode = body["salesOrderCode"]; +String orderNo = body["orderNo"]; +String materialCode = body["materialCode"]; +String profileModel = body["profileModel"]; +String salesStatus = body["salesStatus"]; + +String extrusionDate = body['extrusionDate']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + +return db.selectInt(""" + select + count(1) + from + mini_extrusion_schedule_detail mesd + left join mini_extrusion_schedule mes on mes.schedule_number = mesd.schedule_number + left join sys_user su on su.user_id = mes.extrusion_team + left join mini_production_machines mpm on mpm.machine_code = mes.extrusion_machine + + left join mini_sales_order_materials msm + on mesd.sales_order_code = msm.sales_order_code and mesd.material_code = msm.material_code and mesd.order_no = msm.order_no + left join mini_sales_orders mso on mso.document_number = msm.sales_order_code + left join sys_user su2 on su2.user_id = mso.salesperson + where 1=1 + ?{scheduleNumber != null and scheduleNumber != '', and mesd.schedule_number like concat('%', #{scheduleNumber}, '%')} + ?{salesOrderCode != null and salesOrderCode != '', and msm.sales_order_code like concat('%', #{salesOrderCode}, '%')} + ?{orderNo != null and orderNo != '', and msm.order_no like concat('%', #{orderNo}, '%')} + ?{materialCode != null and materialCode != '', and msm.material_code like concat('%', #{materialCode}, '%')} + ?{profileModel != null and profileModel != '', and msm.profile_model like concat('%', #{profileModel}, '%')} + ?{salesStatus != null and salesStatus != '', and mso.status = #{salesStatus}} + + ?{extrusionDate!=null && extrusionDate!="", and date(mes.extrusion_date) = #{extrusionDate} } + ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and msm.surface_method = #{surfaceMethod}} +""") \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/group.json b/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/group.json new file mode 100644 index 0000000..40f633e --- /dev/null +++ b/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/group.json @@ -0,0 +1,14 @@ +{ + "properties" : { }, + "id" : "ac6602436d574b049dcf80eee3ff5d8d", + "name" : "订单跟踪", + "type" : "function", + "parentId" : "414d04bbdc2e4cb5a23145a0bfe0e649", + "path" : "orderTracking", + "createTime" : null, + "updateTime" : 1732601307816, + "createBy" : null, + "updateBy" : null, + "paths" : [ ], + "options" : [ ] +} \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/订单跟踪列表.ms b/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/订单跟踪列表.ms new file mode 100644 index 0000000..fa42a4e --- /dev/null +++ b/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/订单跟踪列表.ms @@ -0,0 +1,318 @@ +{ + "properties" : { }, + "id" : "b9d2add17088436ea92dd36fd1462557", + "script" : null, + "groupId" : "ac6602436d574b049dcf80eee3ff5d8d", + "name" : "订单跟踪列表", + "createTime" : null, + "updateTime" : 1732609621796, + "lock" : null, + "createBy" : null, + "updateBy" : null, + "path" : "/list", + "description" : null, + "returnType" : null, + "mappingPath" : null, + "parameters" : [ { + "name" : "salesOrderList", + "value" : null, + "description" : null, + "required" : false, + "dataType" : "String", + "type" : "java.lang.Object", + "defaultValue" : null, + "validateType" : null, + "error" : null, + "expression" : null, + "children" : null + } ] +} +================================ +String salesOrderCode = body['salesOrderCode']; +String orderNo = body['orderNo']; +String materialCode = body['materialCode']; +String profileModel = body['profileModel']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + +println("订单跟踪列表") +println(body) + +// ============================== +// 1.查询销售单明细 +// ============================== +var sql = """ + select + msom.sales_order_code, + msom.order_no, + msom.material_code, + msom.material_name, + msom.profile_model, + msom.specification, + msom.thickness, + msom.weight, + msom.order_length, + msom.order_total_quantity, + msom.surface_method, + msom.delivery_date, + msom.theoretical_weight, + msom.produced_pieces, + msom.produced_length + from mini_sales_order_materials msom + left join mini_sales_orders mso on mso.document_number = msom.sales_order_code + where 1=1 + ?{orderNo != null and orderNo != '', and msom.order_no like concat('%', #{orderNo}, '%')} + ?{materialCode != null and materialCode != '', and msom.material_code like concat('%', #{materialCode}, '%')} + ?{profileModel != null and profileModel != '', and msom.profile_model like concat('%', #{profileModel}, '%')} + ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and msom.surface_method = #{surfaceMethod}} + ?{salesOrderCode != null and salesOrderCode != '', and msom.sales_order_code = #{salesOrderCode}} +""" + +Map pages = db.page(sql); + +List salesOrderList = pages.list; + +if (salesOrderList.size() == 0) { + return [] +} + +// ============================== +// 2.查询生产计划数据 +// ============================== +var sql2 = """ + select + sales_order_code, + order_no, + sum(planned_pieces) as planned_pieces + from mini_production_schedule + where 1=1 and (sales_order_code, order_no) in ( + + (#{item.salesOrderCode}, #{item.orderNo}) + + ) + group by sales_order_code, order_no +""" +List productionScheduleList = db.select(sql2) + + +// ============================== +// 3.查询挤压排产数据 +// ============================== +var sql3 = """ + select + sales_order_code, + order_no, + group_concat(schedule_number order by schedule_number separator ', ') as schedule_number, + sum(production_length) as production_length, + sum(production_pieces) as production_pieces, + max(sawing_method) as sawing_method + from mini_extrusion_schedule_detail + where 1=1 and (sales_order_code, order_no) in ( + + (#{item.salesOrderCode}, #{item.orderNo}) + + ) + group by sales_order_code, order_no +""" +List extrusionScheduleDetail = db.select(sql3) + + +// ============================== +// 4.查询报工数据 +// ============================== +var sql4 = """ + select + mpr.sales_order_code, + mpr.order_no, + mpr.current_process, + round((sum(mesd.production_length) * sum(production_number) * sum(production_weight)), 4) as actual_weight_mesd, + round((sum(msom.order_length) * sum(production_number) * sum(production_weight)), 4) as actual_weight_msom, + sum(production_number) as production_number, + max(production_weight) as production_weight + from mini_process_report mpr + left join mini_extrusion_schedule_detail mesd + on mpr.sales_order_code = mesd.sales_order_code and mpr.order_no = mesd.order_no + left join mini_sales_order_materials msom + on mpr.sales_order_code = msom.sales_order_code and mpr.order_no = msom.order_no + where 1=1 and (mpr.sales_order_code, mpr.order_no) in ( + + (#{item.salesOrderCode}, #{item.orderNo}) + + ) + group by mpr.sales_order_code, mpr.order_no, mpr.current_process +""" + + +List processReportList = db.select(sql4) + +// 处理数据 +// actualWeightMesd 排产长度计算 +// actualWeightMsom 订单长度计算 +var processReportFinalList = [] +var arr = ['jingqie','dk','bz'] +processReportList.group(it => it.salesOrderCode + "_" + it.orderNo, // 根据api_group_id 分组 + list => list.group(item => item.currentProcess, + obj => obj + ) +).each((key, value) => { + var jsonObj = {} + value.each((key1, value1) => { + var val = value1[0]; + jsonObj["salesOrderCode"] = val.salesOrderCode; + jsonObj["orderNo"] = val.orderNo; + if (arr.contains(key1)) { + jsonObj[key1 + "_actualWeight"] = val.actualWeightMsom; + } else { + jsonObj[key1 + "_actualWeight"] = val.actualWeightMesd; + } + + jsonObj[key1 + "_productionNumber"] = val.productionNumber; + jsonObj[key1 + "_productionWeight"] = val.productionWeight; + }) + processReportFinalList.push(jsonObj) +}) + + +// ============================== +// 5.查询长料报废数据 +// 挤压、精品、氧化上排、氧化下排工序 +// ============================== +var sql5 = """ + select + sales_order_code, + order_no, + sum(scrap_number) as long_scrap_number, + sum(scrap_weight) as long_scrap_weight + from mini_process_report mpr + where 1=1 and mpr.current_process in ('jiya','jinpin','yanghua1','yanghua2') + and (mpr.sales_order_code, mpr.order_no) in ( + + (#{item.salesOrderCode}, #{item.orderNo}) + + ) + group by mpr.sales_order_code, mpr.order_no +""" +List processReportLongList = db.select(sql5) + +// ============================== +// 6.查询短料报废数据 +// 精切,打孔,包装工序 +// ============================== +var sql6 = """ + select + sales_order_code, + order_no, + sum(scrap_number) as shortage_scrap_number, + sum(scrap_weight) as shortage_scrap_weight + from mini_process_report mpr + where 1=1 and mpr.current_process in ('jingqie','dk','bz') + and (mpr.sales_order_code, mpr.order_no) in ( + + (#{item.salesOrderCode}, #{item.orderNo}) + + ) + group by mpr.sales_order_code, mpr.order_no +""" +List processReportShortageList = db.select(sql6) + +// ============================== +// 7.入库状况 +// ============================== +var sql7 = """ + select + mpr.sales_order_code, + mpr.order_no, + sum(mpr.receipt_quantity) as receipt_quantity, + sum(mpr.actual_weight) as actual_weight + from + mini_product_receipt mpr + where 1=1 + and (mpr.sales_order_code, mpr.order_no) in ( + + (#{item.salesOrderCode}, #{item.orderNo}) + + ) + group by mpr.sales_order_code, mpr.order_no +""" +List productReceiptList = db.select(sql7) + +// ============================== +// 8.出库和库存数据 +// ============================== + // (sum(mwp.existing_inventory) - sum(mssm.shipment_quantity)) as no_shipment_quantity, + // (sum(mwp.actual_weight) - sum(mssm.actual_weight)) as no_actual_weight, +var sql8 = """ + select + mssm.sales_order_code, + mssm.order_no, + sum(mssm.shipment_quantity) as shipment_quantity, + sum(mssm.actual_weight) as shipment_actual_weight, + sum(mwp.existing_inventory) as no_shipment_quantity, + sum(mwp.actual_weight) as no_actual_weight, + round((sum(mwp.existing_inventory) + sum(mssm.shipment_quantity)), 4) as existing_inventory, + round((sum(mwp.actual_weight) + sum(mssm.actual_weight)), 4) as existing_actual_weight + from + mini_sales_shipment_materials mssm + left join mini_warehouse_product mwp on + mwp.order_no = mssm.order_no + and mwp.sales_order_code = mssm.sales_order_code + where 1=1 + and (mssm.sales_order_code, mssm.order_no) in ( + + (#{item.salesOrderCode}, #{item.orderNo}) + + ) + group by mssm.sales_order_code, mssm.order_no +""" +List salesShipmenList = db.select(sql8) + +var result = select + a.*, + b.plannedPieces, + c.productionLength, + c.productionPieces, + c.sawingMethod, + ifnull(e.longScrapNumber, 0) longScrapNumber, + ifnull(e.longScrapWeight, 0) longScrapWeight, + ifnull(f.shortageScrapNumber, 0) shortageScrapNumber, + ifnull(f.shortageScrapWeight, 0) shortageScrapWeight, + ifnull(d.jiya_actualWeight, 0) jiya_actualWeight, + ifnull(d.jiya_productionNumber, 0) jiya_productionNumber, + ifnull(d.jiya_productionWeight, 0) jiya_productionWeight, + ifnull(d.jingpin_actualWeight, 0) jingpin_actualWeight, + ifnull(d.jingpin_productionNumber, 0) jingpin_productionNumber, + ifnull(d.jingpin_productionWeight, 0) jingpin_productionWeight, + ifnull(d.yanghau1_actualWeight, 0) yanghau1_actualWeight, + ifnull(d.yanghau1_productionNumber, 0) yanghau1_productionNumber, + ifnull(d.yanghau1_productionWeight, 0) yanghau1_productionWeight, + ifnull(d.yanghua2_actualWeight, 0) yanghua2_actualWeight, + ifnull(d.yanghua2_productionNumber, 0) yanghua2_productionNumber, + ifnull(d.yanghua2_productionWeight, 0) yanghua2_productionWeight, + ifnull(d.jingqie_actualWeight, 0) jingqie_actualWeight, + ifnull(d.jingqie_productionNumber, 0) jingqie_productionNumber, + ifnull(d.jingqie_productionWeight, 0) jingqie_productionWeight, + ifnull(d.dk_actualWeight, 0) dk_actualWeight, + ifnull(d.dk_productionNumber, 0) dk_productionNumber, + ifnull(d.dk_productionWeight, 0) dk_productionWeight, + ifnull(d.bz_actualWeight, 0) bz_actualWeight, + ifnull(d.bz_productionNumber, 0) bz_productionNumber, + ifnull(d.bz_productionWeight, 0) bz_productionWeight, + ifnull(g.receiptQuantity, 0) receiptQuantity, + ifnull(g.actualWeight, 0) actualWeight, + ifnull(h.shipmentQuantity, 0) shipmentQuantity, + ifnull(h.shipmentActualWeight, 0) shipmentActualWeight, + ifnull(h.noShipmentQuantity, 0) noShipmentQuantity, + ifnull(h.noActualWeight, 0) noActualWeight, + ifnull(h.existingInventory, 0) existingInventory, + ifnull(h.existingActualWeight, 0) existingActualWeight + from salesOrderList a + left join productionScheduleList b on a.salesOrderCode = b.salesOrderCode and a.orderNo = b.orderNo + left join extrusionScheduleDetail c on a.salesOrderCode = c.salesOrderCode and a.orderNo = c.orderNo + left join processReportFinalList d on a.salesOrderCode = d.salesOrderCode and a.orderNo = d.orderNo + left join processReportLongList e on a.salesOrderCode = e.salesOrderCode and a.orderNo = e.orderNo + left join processReportShortageList f on a.salesOrderCode = f.salesOrderCode and a.orderNo = f.orderNo + left join productReceiptList g on a.salesOrderCode = g.salesOrderCode and a.orderNo = g.orderNo + left join salesShipmenList h on a.salesOrderCode = h.salesOrderCode and a.orderNo = h.orderNo + +return result \ No newline at end of file diff --git a/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/订单跟踪总数.ms b/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/订单跟踪总数.ms new file mode 100644 index 0000000..c6e2350 --- /dev/null +++ b/appengine/src/main/resources/api_file/function/数据处理/订单跟踪/订单跟踪总数.ms @@ -0,0 +1,52 @@ +{ + "properties" : { }, + "id" : "d96963a3d8d94fb2acb55a09d05266f9", + "script" : null, + "groupId" : "ac6602436d574b049dcf80eee3ff5d8d", + "name" : "订单跟踪总数", + "createTime" : null, + "updateTime" : 1732603321523, + "lock" : null, + "createBy" : null, + "updateBy" : null, + "path" : "/count", + "description" : null, + "returnType" : null, + "mappingPath" : null, + "parameters" : [ { + "name" : "body", + "value" : null, + "description" : null, + "required" : false, + "dataType" : "String", + "type" : "java.util.Map", + "defaultValue" : null, + "validateType" : null, + "error" : null, + "expression" : null, + "children" : null + } ] +} +================================ +String salesOrderCode = body['salesOrderCode']; +String orderNo = body['orderNo']; +String materialCode = body['materialCode']; +String profileModel = body['profileModel']; +String customerId = body['customerId']; +String surfaceMethod = body['surfaceMethod']; + +var sql = """ + select + count(1) + from mini_sales_order_materials msom + left join mini_sales_orders mso on mso.document_number = msom.sales_order_code + where 1=1 + ?{orderNo != null and orderNo != '', and msom.order_no like concat('%', #{orderNo}, '%')} + ?{materialCode != null and materialCode != '', and msom.material_code like concat('%', #{materialCode}, '%')} + ?{profileModel != null and profileModel != '', and msom.profile_model like concat('%', #{profileModel}, '%')} + ?{customerId != null and customerId != '', and mso.customer_id = #{customerId}} + ?{surfaceMethod != null and surfaceMethod != '', and msom.surface_method = #{surfaceMethod}} + ?{salesOrderCode != null and salesOrderCode != '', and msom.sales_order_code = #{salesOrderCode}} +""" + +return db.selectInt(sql); \ No newline at end of file