diff --git a/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java b/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java index e01000d7..1387e8fb 100644 --- a/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java +++ b/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java @@ -1119,17 +1119,15 @@ public class WmsMaterialCoilServiceImpl implements IWmsMaterialCoilService { bo.setSpecThickness(thickness); // 计算理论厚度(需要实测长度) - if (bo.getTheoreticalThickness() == null && bo.getActualLength() != null) { + if (bo.getActualLength() != null) { BigDecimal length = new BigDecimal(bo.getActualLength()); BigDecimal theoreticalThickness = volume.divide(length, 10, RoundingMode.HALF_UP).divide(width, 10, RoundingMode.HALF_UP).multiply(new BigDecimal("1000")); bo.setTheoreticalThickness(theoreticalThickness); } // 计算理论长度 - if (bo.getTheoreticalLength() == null) { - BigDecimal theoreticalLength = volume.divide(thickness, 10, RoundingMode.HALF_UP).divide(width, 10, RoundingMode.HALF_UP).multiply(new BigDecimal("1000")); - bo.setTheoreticalLength(theoreticalLength); - } + BigDecimal theoreticalLength = volume.divide(thickness, 10, RoundingMode.HALF_UP).divide(width, 10, RoundingMode.HALF_UP).multiply(new BigDecimal("1000")); + bo.setTheoreticalLength(theoreticalLength); } catch (Exception e) { log.warn("计算理论厚度/长度失败", e); }