con_contract_approve_wfl.lview 3.92 KB
Newer Older
Spencer Chang's avatar
Spencer Chang committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: duzhihong  
    $Date: 2014-8-4 下午3:32:33  
    $Revision: 1.0  
    $Purpose: 
-->
<a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true" trace="true">
    <a:view>
        <a:link id="con_contract_update_link_id" url="${/request/@context_path}/modules/cont/CON500/con_contract_update.lview"/>
        <a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/>
        <script type="text/javascript"><![CDATA[
            function con505_render_contractMaintainDs_grid(value, record, name) {
                // if (name == 'contract_number') {
                    return '<a href="javascript:con505_contractMaintainDs_grid_update(' + record.id + ');">' + '合同明细' + '</a>';
                // }
            }
            
            function con505_param_set_value(param) {
                param['function_code'] = 'CON301';
                param['function_usage'] = 'QUERY';
                param['maintain_type'] = 'READONLY';
                param['url_title'] = '${l:CON301.CONTRACT_DETAIL}';
                hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'con_contract_update_link_id');
            }
            
            function con505_contractMaintainDs_grid_update(id) {
                var current_record = $('con_contract_for_wfl_ds').findById(id);
                var param = current_record.data;
                param['document_id'] = current_record.get('contract_id');
                con505_param_set_value(param);
            }
        ]]></script>
        <a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
        <a:dataSets>
            <a:dataSet id="con_contract_for_wfl_ds" autoQuery="true" model="cont.CON500.con_contract_v" queryUrl="${/request/@context_path}/autocrud/cont.CON500.con_contract_v/query?contract_id=${/parameter/@contract_id}">
                <a:fields>
                    <a:field name="contract_number" readOnly="true"/>
                    <a:field name="contract_name" readOnly="true"/>
                    <a:field name="bp_name" readOnly="true"/>
                    <a:field name="contract_id"/>
                </a:fields>
            </a:dataSet>
        </a:dataSets>
        <a:screenBody>
            <a:form marginWidth="30" title="合同审批">
                <a:box column="4" labelWidth="120" width="1000">
                    <a:textField name="contract_number" bindTarget="con_contract_for_wfl_ds" prompt="HLS.CONTRACT_NUMBER"/>
                    <a:textField name="contract_name" bindTarget="con_contract_for_wfl_ds" prompt="合同名称"/>
                    <a:textField name="bp_name" bindTarget="con_contract_for_wfl_ds" prompt="承租人" width="200"/>
                    <a:label name="contract_detail" bindTarget="con_contract_for_wfl_ds" renderer="con505_render_contractMaintainDs_grid" style="margin-left:30px;"/>
                </a:box>
            </a:form>
        </a:screenBody>
        <a:switch test="/parameter/@upload_flag">
            <a:case value="Y">
                <!-- <a href="javascript:approve_wfl_atm_upload();" style="margin-left:19px;text-decoration:underline">
                    <font size="3"><![CDATA[附件上传]]></font>
                </a> -->
                <a:screen-include screen="atm_upload.lview?document_id=${/parameter/@contract_id}&amp;document_table=HY_CON_PROCESS&amp;showflag=N"/>
            </a:case>
            <a:case value="N">
                <!-- <a href="javascript:approve_wfl_atm_query();" style="margin-left:19px;text-decoration:underline">
                    <font size="3"><![CDATA[附件上传]]></font>
                </a> -->
                <a:screen-include screen="atm_query.lview?document_id=${/parameter/@contract_id}&amp;document_table=HY_CON_PROCESS&amp;showflag=N"/>
            </a:case>
        </a:switch>
    </a:view>
</a:screen>