From d49b3b9bdda890e83eb9a57faf1bd8530e0b1839 Mon Sep 17 00:00:00 2001 From: zhaoxiaolin Date: Wed, 9 Oct 2024 17:56:50 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B4=A8=E9=87=8F=E9=97=AE=E9=A2=98=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/ProOrderWorkorderServiceImpl.java | 3 + .../controller/QcStaticTableController.java | 9 +- .../service/IQcStaticTableService.java | 2 + .../impl/QcStaticTableServiceImpl.java | 47 +++++-- .../quality/QcCheckTaskInventoryMapper.xml | 9 +- .../com/op/sap/controller/SapController.java | 2 +- .../java/com/op/wms/domain/BaseProduct.java | 32 +++-- .../service/impl/BaseProductServiceImpl.java | 6 +- .../mapper/wms/BaseProductMapper.xml | 118 +++++++++++------- 9 files changed, 151 insertions(+), 77 deletions(-) diff --git a/op-modules/op-plan/src/main/java/com/op/plan/service/impl/ProOrderWorkorderServiceImpl.java b/op-modules/op-plan/src/main/java/com/op/plan/service/impl/ProOrderWorkorderServiceImpl.java index 5863a6a7..6c2f8b88 100644 --- a/op-modules/op-plan/src/main/java/com/op/plan/service/impl/ProOrderWorkorderServiceImpl.java +++ b/op-modules/op-plan/src/main/java/com/op/plan/service/impl/ProOrderWorkorderServiceImpl.java @@ -1384,6 +1384,9 @@ public class ProOrderWorkorderServiceImpl implements IProOrderWorkorderService { dtos = proOrderWorkorderMapper.getPreIdCardListB(proOrderWorkorder); dtos.get(0).setUmrez(dtos.get(0).getBatchQuantity().multiply(dtos.get(0).getUmrez()));//子单数量 } + for(ProOrderWorkorder pow:dtos){ + pow.setProductCode(pow.getProductCode().substring(7)); + } return dtos; } diff --git a/op-modules/op-quality/src/main/java/com/op/quality/controller/QcStaticTableController.java b/op-modules/op-quality/src/main/java/com/op/quality/controller/QcStaticTableController.java index 763c53da..8d1c0287 100644 --- a/op-modules/op-quality/src/main/java/com/op/quality/controller/QcStaticTableController.java +++ b/op-modules/op-quality/src/main/java/com/op/quality/controller/QcStaticTableController.java @@ -589,5 +589,12 @@ public class QcStaticTableController extends BaseController { util.exportExcel(response, list, "巡检检验结果明细"); } - + /** + * 定量值分析--表头--产品名称 + **/ + @GetMapping("/getDLTableMXList") + @Log(title = "定量值分析明细", businessType = BusinessType.QUERY) + public QcStaticTable getDLTableMXList(QcStaticTable qcStaticTable) { + return qcStaticTableService.getDLTableMXList(qcStaticTable); + } } diff --git a/op-modules/op-quality/src/main/java/com/op/quality/service/IQcStaticTableService.java b/op-modules/op-quality/src/main/java/com/op/quality/service/IQcStaticTableService.java index 1523b4c4..ac9a366f 100644 --- a/op-modules/op-quality/src/main/java/com/op/quality/service/IQcStaticTableService.java +++ b/op-modules/op-quality/src/main/java/com/op/quality/service/IQcStaticTableService.java @@ -67,4 +67,6 @@ public interface IQcStaticTableService { List exportIncomeDetail(QcStaticTable qcStaticTable); List exportXJDetail(QcStaticTable qcStaticTable); + + QcStaticTable getDLTableMXList(QcStaticTable qcStaticTable); } diff --git a/op-modules/op-quality/src/main/java/com/op/quality/service/impl/QcStaticTableServiceImpl.java b/op-modules/op-quality/src/main/java/com/op/quality/service/impl/QcStaticTableServiceImpl.java index 1989db28..f089faad 100644 --- a/op-modules/op-quality/src/main/java/com/op/quality/service/impl/QcStaticTableServiceImpl.java +++ b/op-modules/op-quality/src/main/java/com/op/quality/service/impl/QcStaticTableServiceImpl.java @@ -188,6 +188,27 @@ public class QcStaticTableServiceImpl implements IQcStaticTableService { return qcStaticTableMapper.getXJDetail(qcStaticTable); } + @Override + @DS("#header.poolName") + public QcStaticTable getDLTableMXList(QcStaticTable qcStaticTable) { + QcStaticTable dto = new QcStaticTable(); + //第一列日期 + List days = this.getDays(qcStaticTable.getYmArrayStart(), + qcStaticTable.getYmArrayEnd(), "ymd"); + qcStaticTable.setDataType("ymd"); + +// List titleList = qcStaticTableMapper.getDLTableTitle(qcStaticTable); +// //表头:第一行 +// List colName1 = titleList.stream().map(QcStaticTable::getMaterialName).distinct().collect(Collectors.toList()); +// dto.setTitleCol1(colName1); + + //列表数据 + List dxData = new ArrayList<>(); + + dto.setDxData(dxData); + + return dto; + } /** * 不良率 = (A类*1+B类*0.65+C类*0.35)/抽样总数 * @@ -728,18 +749,18 @@ public class QcStaticTableServiceImpl implements IQcStaticTableService { } dto.setDxData(dxData); - //给折线图取上下限制 - if(qcStaticTable.getProjectNoArray()!=null){ - qcStaticTable.setProjectNo(qcStaticTable.getProjectNoArray()[0]); - QcStaticTable upandown = qcStaticTableMapper.getUpAndDown(qcStaticTable); - if(upandown!=null){ - dto.setUpperDiff(upandown.getUpperDiff()); - dto.setDownDiff(upandown.getDownDiff()); - }else{ - dto.setUpperDiff(BigDecimal.ZERO); - dto.setDownDiff(BigDecimal.ZERO); - } - } +// //给折线图取上下限制 +// if(qcStaticTable.getProjectNoArray()!=null){ +// qcStaticTable.setProjectNo(qcStaticTable.getProjectNoArray()[0]); +// QcStaticTable upandown = qcStaticTableMapper.getUpAndDown(qcStaticTable); +// if(upandown!=null){ +// dto.setUpperDiff(upandown.getUpperDiff()); +// dto.setDownDiff(upandown.getDownDiff()); +// }else{ +// dto.setUpperDiff(BigDecimal.ZERO); +// dto.setDownDiff(BigDecimal.ZERO); +// } +// } return dto; } @@ -1165,6 +1186,8 @@ public class QcStaticTableServiceImpl implements IQcStaticTableService { return days; } + + public static void main(String args[]){ String ymd = "1、0.4016"; System.out.println(ymd.substring(2)); diff --git a/op-modules/op-quality/src/main/resources/mapper/quality/QcCheckTaskInventoryMapper.xml b/op-modules/op-quality/src/main/resources/mapper/quality/QcCheckTaskInventoryMapper.xml index 61be5714..b653f29b 100644 --- a/op-modules/op-quality/src/main/resources/mapper/quality/QcCheckTaskInventoryMapper.xml +++ b/op-modules/op-quality/src/main/resources/mapper/quality/QcCheckTaskInventoryMapper.xml @@ -292,7 +292,7 @@ wms_fp_storage_news_sn.wh_code ) t --> - select t0.orderNo, + select t.order_no orderNo, t.material_code materialCode, t.material_name materialName, @@ -322,8 +322,9 @@ where bp.warehouse_cycle is not null and t.check_type in('checkTypeLL','checkTypeCP') and t.del_flag = '0' and t.material_code like concat('%',#{materialCode}, '%') and t.material_name like concat('%',#{materialName}, '%') - )t0 - where t0.days >= t0.warehouse_cycle + - and product_code like concat('%', #{productCode},'%') - and product_desc_zh like concat('%',#{productDescZh}, '%') - and product_model = #{productModel} - and product_desc_en = #{productDescEn} - and rule_code = #{ruleCode} - and old_product_code = #{oldProductCode} - and parts_product_code = #{partsProductCode} - and sku_barcode = #{skuBarcode} - and length = #{length} - and width = #{width} - and height = #{height} - and gross_weight = #{grossWeight} - and net_weight = #{netWeight} - and tare_weight = #{tareWeight} - and volume = #{volume} - and unit_price = #{unitPrice} - and product_group = #{productGroup} - and product_group_name like concat('%',#{productGroupName}, '%') - and user_defined1 = #{userDefined1} - and user_defined2 = #{userDefined2} - and user_defined3 = #{userDefined3} - and user_defined4 = #{userDefined4} - and user_defined5 = #{userDefined5} - and user_defined6 = #{userDefined6} - and factory_code = #{factoryCode} - and active_flag = #{activeFlag} - and sync_flag = #{syncFlag} - and primary_uom = #{primaryUom} - and bstme = #{bstme} - and basic_order = #{basicOrder} - and conv_order = #{convOrder} - and ausme = #{ausme} - and basic_issue = #{basicIssue} - and conv_issue = #{convIssue} - and append_flag = #{appendFlag} - and append_percent = #{appendPercent} - and mtart = #{mtart} - and report_rate = #{reportRate} - and mvgr5 like concat('%', #{mvgr5},'%') - and del_flag = '0' + and bp.product_code like concat('%', #{productCode},'%') + and bp.product_desc_zh like concat('%',#{productDescZh}, '%') + and bp.product_model = #{productModel} + and bp.product_desc_en = #{productDescEn} + and bp.rule_code = #{ruleCode} + and bp.old_product_code = #{oldProductCode} + and bp.parts_product_code = #{partsProductCode} + and bp.sku_barcode = #{skuBarcode} + and bp.length = #{length} + and bp.width = #{width} + and bp.height = #{height} + and bp.gross_weight = #{grossWeight} + and bp.net_weight = #{netWeight} + and bp.tare_weight = #{tareWeight} + and bp.volume = #{volume} + and bp.unit_price = #{unitPrice} + and bp.product_group = #{productGroup} + and bp.product_group_name like concat('%',#{productGroupName}, '%') + and bp.user_defined1 = #{userDefined1} + and bp.user_defined2 = #{userDefined2} + and bp.user_defined3 = #{userDefined3} + and bp.user_defined4 = #{userDefined4} + and bp.user_defined5 = #{userDefined5} + and bp.user_defined6 = #{userDefined6} + and bp.factory_code = #{factoryCode} + and bp.active_flag = #{activeFlag} + and bp.sync_flag = #{syncFlag} + and bp.primary_uom = #{primaryUom} + and bp.bstme = #{bstme} + and bp.basic_order = #{basicOrder} + and bp.conv_order = #{convOrder} + and bp.ausme = #{ausme} + and bp.basic_issue = #{basicIssue} + and bp.conv_issue = #{convIssue} + and bp.append_flag = #{appendFlag} + and bp.append_percent = #{appendPercent} + and bp.mtart = #{mtart} + and bp.report_rate = #{reportRate} + and bp.mvgr5 like concat('%', #{mvgr5},'%') + and bp.del_flag = '0' - order by product_code asc + order by bp.product_code asc