รวม code จากทุกคน ที่แก้ไข op ล่าสุด

This commit is contained in:
Nakorn Rientrakrunchai
2020-04-05 22:57:02 +07:00
parent 6135a2ec09
commit 9ffe9c30d3
46 changed files with 2636 additions and 529 deletions

View File

@@ -121,7 +121,14 @@ function eva_adjust_postponement_quota_GoDelete(a) {
function Oneva_adjust_postponement_quota_limit_frame_quotaChange()
{
var limit_frame_quota = parseFloat($("#eva_adjust_postponement_quota_limit_frame_quota").val());
limit_frame_quota = Math.round(limit_frame_quota * 100) / 100;
if(limit_frame_quota < 0) limit_frame_quota = 0;
$("#eva_adjust_postponement_quota_limit_frame_quota").val(limit_frame_quota);
var limit = parseFloat($("#eva_adjust_postponement_quota_limit").val());
limit = Math.round(limit * 100)/100;
$("#eva_adjust_postponement_quota_limit").val(limit);
limit_quota = limit_frame_quota * limit / 100;
$("#eva_adjust_postponement_quota_limit_quota").val(limit_quota);
CalculateRemainQuota();
@@ -136,8 +143,20 @@ function CalculateRemainQuota(){
var i = $(this).find("#rowCount").text();
var new_sarary = parseFloat($("#eva_adjust_postponement_detail_quota_02_new_sarary_" + i).text());
var receive_quota = parseFloat($("#eva_adjust_postponement_detail_quota_02_receive_quota_" + i).val());
receive_quota = Math.round(receive_quota*100)/100;
if(receive_quota < 0) receive_quota = 0;
$("#eva_adjust_postponement_detail_quota_02_receive_quota_" + i).val(receive_quota);
var new_sarary_with_quota = new_sarary + receive_quota;
$("#eva_adjust_postponement_detail_quota_02_new_sarary_with_quota_" + i).text(new_sarary_with_quota);
if(new_sarary_with_quota < 13285){
$("#eva_adjust_postponement_detail_quota_02_new_cost_living_" + i).text(1000);
}else{
$("#eva_adjust_postponement_detail_quota_02_new_cost_living_" + i).text(0);
}
sum_receive_quota += receive_quota;
});