diff --git a/Application/Admin/View/CompanyStatementPool/editPuPool.html b/Application/Admin/View/CompanyStatementPool/editPuPool.html index 778e15be9..d0e7b276e 100644 --- a/Application/Admin/View/CompanyStatementPool/editPuPool.html +++ b/Application/Admin/View/CompanyStatementPool/editPuPool.html @@ -466,6 +466,11 @@ withhold = 0; $(_this).parent().parent().find(".withhold").val(withhold); } + + if (!oldwithhold ) { + oldwithhold = 0; + $(_this).parent().parent().find(".oldwithhold").val(oldwithhold); + } // else if(parseFloat(withhold) > parseFloat(pay_money)) { // withhold = pay_money; // $(_this).parent().parent().find(".withhold").val(withhold); @@ -509,7 +514,7 @@ } } - var D_value = parseFloat(old_amount)-parseFloat(this_amount) + (withhold-oldwithhold); + var D_value = parseFloat(old_amount)-parseFloat(this_amount) + parseFloat(withhold-oldwithhold); week_amount_find.find(".week_amount").text((parseFloat(week_amount) - D_value).toFixed(2)); diff --git a/Application/Admin/View/CompanyStatementPool/editSpecialPuPool.html b/Application/Admin/View/CompanyStatementPool/editSpecialPuPool.html index bcc213f90..02709bf51 100644 --- a/Application/Admin/View/CompanyStatementPool/editSpecialPuPool.html +++ b/Application/Admin/View/CompanyStatementPool/editSpecialPuPool.html @@ -471,6 +471,11 @@ withhold = 0; $(_this).parent().parent().find(".withhold").val(withhold); } + + if (!oldwithhold ) { + oldwithhold = 0; + $(_this).parent().parent().find(".oldwithhold").val(oldwithhold); + } // else if(parseFloat(withhold) > parseFloat(pay_money)) { // withhold = pay_money; // $(_this).parent().parent().find(".withhold").val(withhold); @@ -514,7 +519,7 @@ var this_amount = week_amount_find.find(".sum_money_span").text(); - var D_value = parseFloat(old_amount)-parseFloat(this_amount) + (withhold-oldwithhold) ; + var D_value = parseFloat(old_amount)-parseFloat(this_amount) + parseFloat(withhold-oldwithhold) ; week_amount_find.find(".week_amount").text((parseFloat(week_amount)-D_value).toFixed(2)); // week_amount_find.find(".week_amount_input").val((parseFloat(week_amount)-D_value- parseFloat(withhold)));