From 7f9f3b41ed1d97680300f6500e0d1887ee6ebabd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A8=8B=E5=B0=8F=E4=BC=9F?= Date: Tue, 8 Apr 2025 14:23:25 +0800 Subject: [PATCH] =?UTF-8?q?=E7=B3=BB=E7=BB=9F=E6=A0=A1=E9=AA=8C=E8=AE=A1?= =?UTF-8?q?=E9=87=8F=E6=B8=85=E5=8D=95=E5=8F=98=E5=8A=A8=E7=9A=84=E5=8D=95?= =?UTF-8?q?=E4=BB=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pr/plugin/form/ContractEeasurementBillPlugin.java | 5 +++++ .../form/InContractMeasurementBillEditPlugin.java | 10 ++++++++++ 2 files changed, 15 insertions(+) diff --git a/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/ContractEeasurementBillPlugin.java b/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/ContractEeasurementBillPlugin.java index 79f0977..3760beb 100644 --- a/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/ContractEeasurementBillPlugin.java +++ b/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/ContractEeasurementBillPlugin.java @@ -137,6 +137,11 @@ public class ContractEeasurementBillPlugin extends ContractMeasureBillEditPlugin int parentRowIndex = changeData.getParentRowIndex(); if (StringUtils.equals(propName, "zcgj_hsjell")) { doLockFieldWithPriceAdjustMode((PriceAdjustModeEnum)null); + } else if (StringUtils.equals(propName,"currentprice")) { + BigDecimal oldValue = (BigDecimal)changeData.getOldValue(); + if(oldValue.compareTo(new BigDecimal(0)) == 0){return;} + BigDecimal newValue = (BigDecimal)changeData.getNewValue(); + PriceChangedWarn(oldValue,newValue,rowIndex,parentRowIndex); } else if (StringUtils.equals(propName, "thisqty") || StringUtils.equals(propName, "thisoftaxmount")) { BigDecimal oldValue = (BigDecimal)changeData.getOldValue(); if(oldValue.compareTo(new BigDecimal(0)) == 0){return;} diff --git a/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/InContractMeasurementBillEditPlugin.java b/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/InContractMeasurementBillEditPlugin.java index 0f8380c..dab9969 100644 --- a/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/InContractMeasurementBillEditPlugin.java +++ b/code/zcdev/zcgj-zcdev-zcdev-pr/src/main/java/zcgj/zcdev/zcdev/pr/plugin/form/InContractMeasurementBillEditPlugin.java @@ -183,6 +183,11 @@ public class InContractMeasurementBillEditPlugin extends InContractMeasureBillEd int parentRowIndex = changeData.getParentRowIndex(); if (StringUtils.equals(propName, "zcgj_hsjell")) { doLockFieldWithPriceAdjustMode((PriceAdjustModeEnum)null); + } else if (StringUtils.equals(propName,"currentprice")) { + BigDecimal oldValue = (BigDecimal)changeData.getOldValue(); + if(oldValue.compareTo(new BigDecimal(0)) == 0){return;} + BigDecimal newValue = (BigDecimal)changeData.getNewValue(); + PriceChangedWarn(oldValue,newValue,rowIndex,parentRowIndex); } else if ( StringUtils.equals(propName, "thisoftaxmount")) {//StringUtils.equals(propName, "thisqty") || BigDecimal oldValue = (BigDecimal)changeData.getOldValue(); @@ -208,6 +213,11 @@ public class InContractMeasurementBillEditPlugin extends InContractMeasureBillEd listentry.set("currentamt",currentprice.multiply(totalqty));//当前金额 = 当前单价 * 数量 listentry.set("currenttaxamt",curtaxprice.multiply(totalqty).subtract(currentprice.multiply(totalqty)));//当前税额 listentry.set("currentoftax",curtaxprice.multiply(totalqty));//当前价税合计 +// this.getModel().setValue("currentprice", currentprice,rowIndex,parentRowIndex); +// this.getModel().setValue("currentprice",currentprice, rowIndex, parentRowIndex); +// this.getModel().setValue("currentamt",currentprice.multiply(totalqty),rowIndex, parentRowIndex); +// this.getModel().setValue("currenttaxamt",curtaxprice.multiply(totalqty).subtract(currentprice.multiply(totalqty)),rowIndex, parentRowIndex); +// this.getModel().setValue("currentoftax",curtaxprice.multiply(totalqty),rowIndex, parentRowIndex); this.getView().updateView(); } // String resname = (String)this.getModel().getValue("resname", rowIndex, parentRowIndex);