系统校验计量清单变动的单价

This commit is contained in:
程小伟 2025-04-08 14:23:25 +08:00
parent 898165509b
commit 7f9f3b41ed
2 changed files with 15 additions and 0 deletions

View File

@ -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;}

View File

@ -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);