From d0596a9f8b7d8b961a9c003651a74c786ced6c95 Mon Sep 17 00:00:00 2001 From: zhangzhiqiang Date: Thu, 5 Jan 2023 17:57:50 +0800 Subject: [PATCH] =?UTF-8?q?mdf:=E6=96=B0=E6=96=99=E6=A8=A1=E5=BC=8F/?= =?UTF-8?q?=E6=94=B9=E9=85=8D=E6=A8=A1=E5=BC=8F=E6=88=90=E5=9E=8B=E5=89=82?= =?UTF-8?q?=E8=AE=A1=E7=AE=97=EF=BC=9Btodo:=E5=90=88=E6=89=B9=E6=A8=A1?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../nl/wms/pf/service/impl/AutoformulaServiceImpl.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/mes/hd/nladmin-system/src/main/java/org/nl/wms/pf/service/impl/AutoformulaServiceImpl.java b/mes/hd/nladmin-system/src/main/java/org/nl/wms/pf/service/impl/AutoformulaServiceImpl.java index 251b0364..51f78efd 100644 --- a/mes/hd/nladmin-system/src/main/java/org/nl/wms/pf/service/impl/AutoformulaServiceImpl.java +++ b/mes/hd/nladmin-system/src/main/java/org/nl/wms/pf/service/impl/AutoformulaServiceImpl.java @@ -2741,7 +2741,8 @@ public class AutoformulaServiceImpl implements AutoformulaService { JSONObject rf_dis = rf_list.getJSONObject(i); String set_material_id = rf_dis.getString("material_id"); //R1p*纯粉系数 - double net_rate_qty = rf_dis.getDouble("net_rate_qty"); + double net_rate_qty = rf_dis.getDouble("formula_qty")*net_rate_map.get(set_material_id)/100.0; +// double net_rate_qty = rf_dis.getDouble("net_rate_qty"); JSONObject ProductMaterialSet = MD_PD_ProductMaterialSet.query("set_type='01' and material_id='"+material_id+"' and set_material_id='"+set_material_id+"'").uniqueResult(0); if(ProductMaterialSet == null){ throw new BadRequestException("产品"+material_code+"未配置新料模式可配粉软废信息!"); @@ -4323,7 +4324,8 @@ public class AutoformulaServiceImpl implements AutoformulaService { rf_map.forEach((key, rf_dis)->{ String set_material_id = rf_dis.getString("material_id"); //R1p*纯粉系数 - double net_rate_qty = rf_dis.getDouble("net_rate_qty"); + double net_rate_qty = rf_dis.getDouble("formula_qty")*net_rate_map.get(set_material_id)/100.0; +// double net_rate_qty = rf_dis.getDouble("net_rate_qty"); JSONObject ProductMaterialSet = MD_PD_ProductMaterialSet.query("set_type='02' and material_id='"+material_id+"' and set_material_id='"+set_material_id+"'").uniqueResult(0); if(ProductMaterialSet == null){ throw new BadRequestException("产品"+material_code+"未配置改配模式可配粉软废信息!"); @@ -4368,7 +4370,7 @@ public class AutoformulaServiceImpl implements AutoformulaService { //当前软废已配 double now_formula_qty = bomdlts2_now.getDouble("now_formula_qty"); //已配小于需配 - if(now_formula_qty