diff --git a/src/main/java/cn/palmte/work/bean/IncomeCostBean.java b/src/main/java/cn/palmte/work/bean/IncomeCostBean.java index 62cac7c..52968ff 100644 --- a/src/main/java/cn/palmte/work/bean/IncomeCostBean.java +++ b/src/main/java/cn/palmte/work/bean/IncomeCostBean.java @@ -149,7 +149,7 @@ public class IncomeCostBean { || null == costPurchaseBuildTaxInclude || null == costPurchaseServiceTaxInclude || null == costPurchaseOtherTaxInclude - || null == costProjectManageTaxInclude + /*|| null == costProjectManageTaxInclude*/ || null == costOtherOtherTaxInclude){ return null; } @@ -157,7 +157,7 @@ public class IncomeCostBean { .add(costPurchaseBuildTaxInclude) .add(costPurchaseServiceTaxInclude) .add(costPurchaseOtherTaxInclude) - .add(costProjectManageTaxInclude) + .add(null == costProjectManageTaxInclude ? new BigDecimal(0) : costProjectManageTaxInclude) .add(costOtherOtherTaxInclude); } diff --git a/src/main/resources/static/assets/js/project_budget.js b/src/main/resources/static/assets/js/project_budget.js index 67cea2b..007d5e2 100644 --- a/src/main/resources/static/assets/js/project_budget.js +++ b/src/main/resources/static/assets/js/project_budget.js @@ -111,6 +111,7 @@ function saveDetail(url, data, callback) { /** * 更新页面收入的数据【累加】 + * 明细修改保存后修改收入含税和不含税金额 */ function updateIncomeData(incomeDetails) { var deviceTaxInclude = 0; @@ -252,6 +253,7 @@ function appendTrCost() { } /** * 更新页面收入的数据【累加】 + * 明细保存后回来更新总含税金额和不含税金额 */ function updateCostData(details) { var deviceTaxInclude = 0; @@ -300,6 +302,9 @@ function updateCostData(details) { } function bindOtherOtherChangeable() { + /** + * 其他其他含税金额改变的时候,修改总含税金额 + */ $("input[name='costOtherOtherTaxInclude']").change(function () { var costPurchaseDeviceTaxInclude = parseFloat($("input[name='costPurchaseDeviceTaxInclude']").val()); var costPurchaseBuildTaxInclude = parseFloat($("input[name='costPurchaseBuildTaxInclude']").val()); @@ -310,7 +315,9 @@ function bindOtherOtherChangeable() { $("input[name='costTotalTaxInclude']").val(costPurchaseDeviceTaxInclude+costPurchaseBuildTaxInclude+costPurchaseServiceTaxInclude+costPurchaseOtherTaxInclude+costOtherOther); }); - + /** + * 其他其他不含税金额改变的时候,修改总不含税金额 + */ $("input[name='costOtherOtherTaxExclude']").change(function () { var costPurchaseDeviceTaxExclude = parseFloat($("input[name='costPurchaseDeviceTaxExclude']").val()); var costPurchaseBuildTaxExclude = parseFloat($("input[name='costPurchaseBuildTaxExclude']").val());