Commit f93d1f17 authored by agping's avatar agping

收佣金 优化

parent 12e9ff38
......@@ -651,8 +651,9 @@ define(['doT', 'text!temp/reportList_template_tpl.html', 'css!style/home.css', '
$('.anchangfei').show();
};
});
//中介费类型 正常 多收
$(".fee-type-zhongjie").change(function() {
//中介费类型 正常 多收 change
$(".fee-type-zhongjie,.commission-before-zhongjie,.commission-money").change(function() {
console.log(555)
if($('.fee-type-zhongjie').val()*1 == 0){//正常
var shouldMoney = (0.7*bargain.price_commission).toFixed(2)
var moreMoney = ($('.commission-money').val()*1 - shouldMoney + $('.commission-before-zhongjie').val()*1).toFixed(2)
......@@ -662,11 +663,13 @@ define(['doT', 'text!temp/reportList_template_tpl.html', 'css!style/home.css', '
}else{//多收
var shouldMoney = 0;
var moreMoney = $('.commission-money').val()*1;
$('.fee-money-zhongjie').html(shouldMoney);//应收金额
$('.fee-more-zhongjie').html(moreMoney);//多收金额
};
});
//之前已收佣 change
//收款入账 change
//收款图片 和 收款详情切换
$('.tit_con').unbind('click').bind('click',function(e){
......@@ -1033,11 +1036,8 @@ define(['doT', 'text!temp/reportList_template_tpl.html', 'css!style/home.css', '
$('#container_body_img_area_liu').html('');
$('.commission-bargain-id').html(bargain.bargainid_commission);//初始化 成交报告id
$('.commission-price-zhongjie').html(bargain.price_commission);//初始化成交价
//默认中介费 类型正常
var shouldMoney = (0.7*bargain.price_commission).toFixed(2)
var moreMoney = ($('.commission-money').val()*1 - shouldMoney + $('.commission-before-zhongjie').val()*1).toFixed(2)
$('.fee-money-zhongjie').html(shouldMoney);//应收金额
$('.fee-more-zhongjie').html(moreMoney);//多收金额
$('.fee-money-zhongjie').html(0);//应收金额
$('.fee-more-zhongjie').html(0);//多收金额
bargain.getNum();
bargain.getRole();
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment