Commit 3802f370 authored by 25484's avatar 25484

[fix]合同结束页面修改

parent 367e4d09
......@@ -58,7 +58,7 @@
<bm:query-field field="bp_id_agent_desc" queryExpression="bp_id_agent_desc like upper(&apos;%&apos;||${@bp_id_agent_desc}||&apos;%&apos;)"/>
</bm:query-fields>
<bm:data-filters>
<bm:data-filter enforceOperations="query" expression="t1.contract_status in (&apos;INCEPT&apos;,&apos;ETING&apos;,&apos;ADING&apos;) "/>
<bm:data-filter enforceOperations="query" expression="t1.contract_status in (&apos;TERMINATE&apos;) "/>
<!-- <bm:data-filter enforceOperations="query" expression="t1.lease_end_date &lt;= sysdate"/> -->
<bm:data-filter enforceOperations="query" expression="t1.data_class = &apos;NORMAL&apos;"/>
<!--<bm:data-filter enforceOperations="query" expression=" NOT EXISTS (SELECT 1 FROM con_contract_cashflow WHERE contract_id = t1.contract_id AND cf_item IN (1,8,52) AND (write_off_flag IN (&apos;PARTIAL&apos;, &apos;NOT&apos;) OR received_amount != due_amount))"/>-->
......
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: gaoyang
$Date: 2013-6-24 下午03:23:39
$Revision: 1.0
$Purpose:
$Author: gaoyang
$Date: 2013-6-24 下午03:23:39
$Revision: 1.0
$Purpose:
-->
<a:screen xmlns:c="leaf.application.action" xmlns:p="uncertain.proc" xmlns:a="http://www.leaf-framework.org/application" xmlns:s="leaf.plugin.script" cacheEnabled="true" cacheKey="${/parameter/@layout_code}_screen" customizationEnabled="true" trace="true">
<a:screen xmlns:a="http://www.leaf-framework.org/application" xmlns:c="leaf.application.action" xmlns:p="uncertain.proc" xmlns:s="leaf.plugin.script" customizationEnabled="true" dynamiccreateenabled="true" trace="true">
<a:init-procedure>
<!-- <s:server-script import="aut_authority_validate.js"/> -->
<!-- <s:server-script import="aut_authority_validate.js"/>-->
<a:model-query fetchAll="true" model="hls.HLS030.hls_doc_layout_main" rootPath="layout_main_path"/>
<a:model-query fetchAll="true" model="cont.CON500.hls_doc_layout_button" rootPath="layout_main_button_path"/>
<a:model-query defaultWhereClause="t1.parent_table is null and t1.tab_type!=&apos;TAB&apos; and t1.enabled_flag=&apos;Y&apos; and rownum=1" fetchAll="true" model="cont.CON500.con_hls_doc_layout_tab_query" rootPath="base_table_path"/>
<!-- <s:server-script><![CDATA[
var m=$ctx.get('/model/layout_main_button_path');
println(m.toXML());
println('**************');
]]></s:server-script> -->
<a:model-query fetchAll="true" model="cont.CON500.hls_doc_layout_button" rootPath="layout_main_button_path"/>
<a:model-query defaultWhereClause="t1.parent_table is null and t1.tab_type!=&apos;TAB&apos; and t1.enabled_flag=&apos;Y&apos; and rownum=1" fetchAll="true" model="cont.CON500.con_hls_doc_layout_tab_query" rootPath="base_table_path"/>
<!-- <s:server-script><![CDATA[-->
<!-- var m=$ctx.get('/model/layout_main_button_path');-->
<!-- println(m.toXML());-->
<!-- println('**************');-->
<!-- ]]></s:server-script>-->
</a:init-procedure>
<a:view>
<script type="text/javascript"><![CDATA[
var dynamic_document_id = '$c{/parameter/@document_id}';
if ('$c{/parameter/@document_id}') {
var detail_mask;
if ('${/parameter/@winid}') {
if (parent.$L.CmpManager.get('${/parameter/@winid}')) {
detail_mask = parent.$('${/parameter/@winid}').wrap;
parent.Leaf.Masker.mask(detail_mask, '${l:HLS.LOADING}');
} else {
detail_mask = $('${/parameter/@winid}').wrap;
Leaf.Masker.mask(detail_mask, '${l:HLS.LOADING}');
}
} else {
detail_mask = Ext.getBody();
Leaf.Masker.mask(detail_mask, '${l:HLS.LOADING}');
}
}
window['${/parameter/@layout_code}_dynamic_link_renderer'] = function(value, record, name, config_record, bp_seq) {
var link_function = '';
window['${/parameter/@layout_code}_hls_link_render_record'][record.id + '---' + name] = record;
if (name == 'bp_link' && record.get('bp_id') && record.get('record_id')) {
link_function = '${/parameter/@layout_code}_open_bp_detail_window';
return '<a href="javascript:window[\'' + link_function + '\'](\'' + record.id + '\',\'' + name + '\');">' + config_record.get('prompt') + '</a>';
} else if (name == 'car_detail' && record.get('contract_lease_item_id')) {
link_function = '${/parameter/@layout_code}_open_lease_item_detail_window';
return '<a href="javascript:window[\'' + link_function + '\'](\'' + record.id + '\',\'' + name + '\');">' + config_record.get('prompt') + '</a>';
}
};
window['${/parameter/@layout_code}_open_lease_item_detail_window'] = function(id, name) {
var record = window['${/parameter/@layout_code}_hls_link_render_record'][id + '---' + name];
var param = record.data;
var contract_lease_item_id = record.get('contract_lease_item_id');
new Leaf.Window({
id: 'contract_lease_item_maintain_window',
url: $('contract_lease_item_maintain_link').getUrl(),
params: {
contract_lease_item_id: contract_lease_item_id,
winid: 'contract_lease_item_maintain_window'
},
draggable: true,
fullScreen: true
});
};
window['${/parameter/@layout_code}_open_bp_detail_window'] = function(id, name) {
var record = window['${/parameter/@layout_code}_hls_link_render_record'][id + '---' + name];
var param = record.data;
param['function_code'] = 'CON501H';
param['function_usage'] = 'MODIFY';
param['url_title'] = '${l:HLS212.BP_MASTER_MAINTAIN}';
hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'con713_hls_bp_master_modify_link', record.ds.id, '${/parameter/@layout_code}');
};
function con500_contract_save(nextStep) {
var root_ds = $('${/model/base_table_path/record/@tab_code}_${/model/base_table_path/record/@base_table}_ds');
if (root_ds.validate()) {
var winid = '${/parameter/@winid}';
if (winid) {
Leaf.Masker.mask($(winid).wrap, '${l:HLS.EXECUTING}');
} else {
Leaf.Masker.mask(Ext.getBody(), '${l:HLS.EXECUTING}');
}
lock_current_window();
var root_record = root_ds.getAt(0);
root_ds.setSubmitParameter('layout_code', '${/parameter/@layout_code}');
on_con_save_dynamic(root_ds, root_record, nextStep, winid);
}
}
function con500_contract_submit() {
var dynamic_document_id = '$c{/parameter/@document_id}';
if ('$c{/parameter/@document_id}') {
var detail_mask;
if ('${/parameter/@winid}') {
if (parent.$L.CmpManager.get('${/parameter/@winid}')) {
detail_mask = parent.$('${/parameter/@winid}').wrap;
// parent.Leaf.Masker.mask(detail_mask, '${l:HLS.LOADING}');
} else {
detail_mask = $('${/parameter/@winid}').wrap;
// Leaf.Masker.mask(detail_mask, '${l:HLS.LOADING}');
}
} else {
detail_mask = Ext.getBody();
// Leaf.Masker.mask(detail_mask, '${l:HLS.LOADING}');
}
}
Leaf.SideBar.enable = false;
con500_contract_save(con500_contract_submit_final);
}
function con500_contract_exit() {
if ('${/parameter/@winid}') {
$('${/parameter/@winid}').close();
} else {
window.location.go(-1);
}
}
function con500_contract_save_exit() {
con500_contract_save(con500_contract_exit);
}
function con500_contract_quote() {
var root_ds = $('${/model/base_table_path/record/@tab_code}_${/model/base_table_path/record/@base_table}_ds');
con500_contract_quote_execute(root_ds);
}
function con500_contract_upload() {
if (!dynamic_document_id) {
Leaf.showMessage('${l:HLS.PROMPT}', '${l:HLS.EXECUTE_AFTER_SAVE}');
return;
} else {
var dynamic_base_table = '${/model/base_table_path/record/@base_table}'.toUpperCase();
var url = '${/request/@context_path}/uploadFile.lview?table_name=' + dynamic_base_table + '&header_id=' + dynamic_document_id;
new Leaf.Window({
url: url,
title: '${l:HLS.SUPPORTING_DOCUMENT}',
id: '${/parameter/@attach_tab_code}_con500_cdd_uploadFile_screen_id',
width: 850,
height: 400
});
}
}
]]></script>
window['${/parameter/@layout_code}_dynamic_link_renderer'] = function(value, record, name, config_record, bp_seq) {
var link_function = '';
window['${/parameter/@layout_code}_hls_link_render_record'][record.id + '---' + name] = record;
if (name == 'bp_link' && record.get('bp_id') && record.get('record_id')) {
link_function = '${/parameter/@layout_code}_open_bp_detail_window';
return '<a href="javascript:window[\'' + link_function + '\'](\'' + record.id + '\',\'' + name + '\');">' + config_record.get('prompt') + '</a>';
} else if (name == 'car_detail' && record.get('contract_lease_item_id')) {
link_function = '${/parameter/@layout_code}_open_lease_item_detail_window';
return '<a href="javascript:window[\'' + link_function + '\'](\'' + record.id + '\',\'' + name + '\');">' + config_record.get('prompt') + '</a>';
}
};
window['${/parameter/@layout_code}_open_lease_item_detail_window'] = function(id, name) {
var record = window['${/parameter/@layout_code}_hls_link_render_record'][id + '---' + name];
var param = record.data;
var contract_lease_item_id = record.get('contract_lease_item_id');
new Leaf.Window({
id: 'contract_lease_item_maintain_window',
url: $('contract_lease_item_maintain_link').getUrl(),
params: {
contract_lease_item_id: contract_lease_item_id,
winid: 'contract_lease_item_maintain_window'
},
draggable: true,
fullScreen: true
});
};
window['${/parameter/@layout_code}_open_bp_detail_window'] = function(id, name) {
var record = window['${/parameter/@layout_code}_hls_link_render_record'][id + '---' + name];
var param = record.data;
param['function_code'] = 'CON501H';
param['function_usage'] = 'MODIFY';
param['url_title'] = '${l:HLS212.BP_MASTER_MAINTAIN}';
hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'con713_hls_bp_master_modify_link', record.ds.id, '${/parameter/@layout_code}');
};
function con500_contract_save(nextStep) {
var root_ds = $('${/model/base_table_path/record/@tab_code}_${/model/base_table_path/record/@base_table}_ds');
if (root_ds.validate()) {
var winid = '${/parameter/@winid}';
if (winid) {
Leaf.Masker.mask($(winid).wrap, '${l:HLS.EXECUTING}');
} else {
Leaf.Masker.mask(Ext.getBody(), '${l:HLS.EXECUTING}');
}
lock_current_window();
var root_record = root_ds.getAt(0);
root_ds.setSubmitParameter('layout_code', '${/parameter/@layout_code}');
on_con_save_dynamic(root_ds, root_record, nextStep, winid);
}
}
function con500_contract_submit() {
Leaf.SideBar.enable = false;
con500_contract_save(con500_contract_submit_final);
}
function con500_contract_exit() {
if ('${/parameter/@winid}') {
$('${/parameter/@winid}').close();
} else {
window.location.go(-1);
}
}
function con500_contract_save_exit() {
con500_contract_save(con500_contract_exit);
}
function con500_contract_quote() {
var root_ds = $('${/model/base_table_path/record/@tab_code}_${/model/base_table_path/record/@base_table}_ds');
con500_contract_quote_execute(root_ds);
}
function con500_contract_upload() {
if (!dynamic_document_id) {
Leaf.showMessage('${l:HLS.PROMPT}', '${l:HLS.EXECUTE_AFTER_SAVE}');
return;
} else {
var dynamic_base_table = '${/model/base_table_path/record/@base_table}'.toUpperCase();
var url = '${/request/@context_path}/uploadFile.lview?table_name=' + dynamic_base_table + '&header_id=' + dynamic_document_id;
new Leaf.Window({
url: url,
title: '${l:HLS.SUPPORTING_DOCUMENT}',
id: '${/parameter/@attach_tab_code}_con500_cdd_uploadFile_screen_id',
width: 850,
height: 400
});
}
}
]]></script>
<a:freeMarker><![CDATA[
<#if model.getObject("/model/layout_main_button_path").getChilds()??>
<#if model.getObject("/parameter/@tab_tab_code")??>
<#else>
<a:screenTopToolbar>
<#list model.getObject('/model/layout_main_button_path').getChilds() as item>
<#if item.getString('button_code') =='SAVE'>
<a:gridButton click="con500_contract_save" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='EXIT'>
<a:gridButton click="con500_contract_exit" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='SAVE_EXIT'>
<a:gridButton click="con500_contract_save_exit" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='QUOTE'>
<a:gridButton click="con500_contract_quote" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='SUBMIT_APPROVAL'>
<a:gridButton click="con500_contract_submit" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='PRINT'>
<a:gridButton click="function(){con500_contract_print&amp;&amp;con500_contract_print()}" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='UPLOAD'>
<a:gridButton click="con500_contract_upload" text="${item.getString('prompt')!""}"/>
<#else>
<a:gridButton id="${item.getString('button_code')!""}" click="function(btn){con500_define_button&amp;&amp;con500_define_button(btn,$('${model.getObject("/model/base_table_path/record/@tab_code")!""}_${model.getObject("/model/base_table_path/record/@base_table")}_ds'))}" text="${item.getString('prompt')!""}"/>
</#if>
</#list>
</a:screenTopToolbar>
</#if>
</#if>
]]></a:freeMarker>
<#if model.getObject("/model/layout_main_button_path").getChilds()??>
<#if model.getObject("/parameter/@tab_tab_code")??>
<#else>
<a:screenTopToolbar>
<#list model.getObject('/model/layout_main_button_path').getChilds() as item>
<#if item.getString('button_code') =='SAVE'>
<a:gridButton click="con500_contract_save" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='EXIT'>
<a:gridButton click="con500_contract_exit" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='SAVE_EXIT'>
<a:gridButton click="con500_contract_save_exit" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='QUOTE'>
<a:gridButton click="con500_contract_quote" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='SUBMIT_APPROVAL'>
<a:gridButton click="con500_contract_submit" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='PRINT'>
<a:gridButton click="function(){con500_contract_print&amp;&amp;con500_contract_print()}" text="${item.getString('prompt')!""}"/>
<#elseif item.getString('button_code') =='UPLOAD'>
<a:gridButton click="con500_contract_upload" text="${item.getString('prompt')!""}"/>
<#else>
<a:gridButton id="${item.getString('button_code')!""}" click="function(btn){con500_define_button&amp;&amp;con500_define_button(btn,$('${model.getObject("/model/base_table_path/record/@tab_code")!""}_${model.getObject("/model/base_table_path/record/@base_table")}_ds'))}" text="${item.getString('prompt')!""}"/>
</#if>
</#list>
</a:screenTopToolbar>
</#if>
</#if>
]]></a:freeMarker>
<a:screenBody padding="5" style="width:98%">
<a:placeHolder id="dynamicMain_id"/>
</a:screenBody>
......
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