Commit 8b7800a3 authored by 邓乾隆's avatar 邓乾隆

合同起租页面追加同步判断

parent 66b9b342
<?xml version="1.0" encoding="UTF-8"?>
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
select contract_status
from con_contract t
where t.contract_id = ${@contract_id}
and rownum = 1
]]></bm:query-sql>
</bm:operation>
</bm:operations>
<bm:fields>
<bm:field name="contract_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="contract_status"/>
</bm:fields>
</bm:model>
......@@ -58,6 +58,7 @@
url="${/request/@context_path}/modules/hls/HLS500N/hls_fin_calculator_update_n.lview"/>
<a:link id="get_atch_download_link"
url="${/request/@context_path}/modules/batch_download/lease_atm_batch_dl.lsc"/>
<a:link id="check_contract_status" model="cont.CON3200.con_checklist_contract" modelaction="query"/>
<link href="${/request/@context_path}/modules/viewerjs/viewer.css" rel="stylesheet"/>
<script src="${/request/@context_path}/modules/viewerjs/viewer.js"/>
<script src="${/request/@context_path}/modules/viewerjs/viewer_tool.js"/>
......@@ -779,6 +780,29 @@
var division = lease_item_record.get('division');
var machine_number_num = 0;
var secondary_lease = record.get('secondary_lease') ;
var contract_id = record.get('contract_id');
var contract_status = record.get('contract_status');
console.log(contract_record);
//校验合同状态
if(!Leaf.isEmpty(contract_status)){
Leaf.request({
url: $('check_contract_status').getUrl(),
para: {
contract_id: contract_id
},
scope: this,
success: function (res) {
if(contract_status != res.result.record.contract_status){
$L.showErrorMessage('提示', '合同状态已发生改变,需要重新刷新页面!');
return false;
}
},
failure: function () {
return false;
},
});
}
if(!Leaf.isEmpty(secondary_lease) && secondary_lease!='YES') {
if (division == '92' && !Leaf.isEmpty(machine_number)) {
Leaf.request({
......
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