/**
 * 回款阶段
 */
function finishSubmit(){
	var mr = $('#mod-finish-moneyReturn').val();
	if(isNotDouble(mr)){
		showMsg('回款金额只能为浮点数');
		return;
	}
	var mltj = $('#mod-finish-moneyLtj').val();
	if(isNotDouble(mltj)){
		showMsg('推荐律师费只能为浮点数');
		return;
	}
	if(parseFloat(mltj) > parseFloat(mr)){
		showMsg('推荐律师费不能大于回款金额');
		return;
	}
	var url = contextPath + '/ssrz/ssrzOrder/changeStatus';
	var parameters = {'orderId':$('#mod-finish-orderId').val(), 'type':40, 'moneyReturn':mr, 'moneyLtj':mltj};
	postData(url, parameters, finishSubmitCallback, errorCallbackDefault);
}

function finishSubmitCallback(data){
	if(data.success){
		$('#modal-finish').modal('toggle');
		showMsg('保存成功');
		myGrid.trigger('reloadGrid');
	}else{
		showMsg(data.message);
	}
}

function showFinishMod(orderId){
	$('#mod-finish-orderId').val(orderId);
	var ids = ['mod-finish-moneyReturn','mod-finish-moneyLtj'];
	for(var i in ids){
		$('#' + ids[i]).val('');
	}
	$('#modal-finish').modal('toggle');
}