Browse Source

打印单导出自动计算重量

lingpeng.li 3 weeks ago
parent
commit
75ad66af22

+ 4 - 0
zgztBus/jeecg-module-sbm/src/main/java/org/jeecg/modules/billet/storageBill/controller/StorageBillPrintController.java

@@ -447,6 +447,10 @@ public class StorageBillPrintController extends JeecgController<StorageBillPrint
                 } else {
                     weight = billetRulerConfig.getWeight();
                     exportRow.setWeightPerPiece(BigDecimal.valueOf(weight));
+                    Integer amount = x.getAmountTotal();
+                    BigDecimal totalWeight = (amount == null) ? BigDecimal.ZERO :
+                            BigDecimal.valueOf(weight).multiply(BigDecimal.valueOf(amount));
+                    exportRow.setTotalWeight(totalWeight);
                 }