gh_nc_contract_query.lview 3.96 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 71 72 73 74 75 76 77 78 79 80
<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: Peter Soong  
    $Date: 2014-06-10 16:24:49  
    $Revision: 1.0  
    $Purpose: 
-->
<a:screen xmlns:s="leaf.plugin.script" xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true" trace="true">
    <a:view>
        <a:link id="gh_contract_nc_log_link" url="${/request/@context_path}/modules/nc/NC100/hls_nc_bp_log_query.lview"/>
        <script type="text/javascript"><![CDATA[
            function bpQueryScreen_query() {
                $('con_bpQueryDs').query();
            }
            
            
            function log_renderer(value, record, name) {
            
                var result_id = record.get('result_id');
                return '<a href="javascript:openLogPage(\'' + result_id + '\')";>查看</a>';
            
            }
            //重置按钮
            
            function bpQueryScreen_reset() {
                $('para_con_bpQueryDs').reset();
            }
            function openLogPage(result_id) {
                new Leaf.Window({
                    id: 'hls_nc_bp_log_window',
                    url: $('gh_contract_nc_log_link').getUrl() + '?result_id=' + result_id,
                    title: '日志信息',
                    height: 450,
                    width: 700
                });
            }
        ]]></script>
        <a:dataSets>
            <a:dataSet id="para_con_bpQueryDs">
                <a:fields>
                    <a:field name="contract_number"/>
                    <a:field name="contract_name"/>
                    <a:field name="bp_id_tenant_n"/>
                    <a:field name="division_n"/>
                    <a:field name="lease_organization_n"/>
                    <a:field name="lease_channel_n"/>
                </a:fields>
            </a:dataSet>
            <a:dataSet id="con_bpQueryDs" autoQuery="true" model="nc.NC100.hls_nc_contract_query" queryDataSet="para_con_bpQueryDs" selectable="true"><![CDATA[
            ]]></a:dataSet>
        </a:dataSets>
        <a:screenBody>
            <a:screenTopToolbar>
                <a:gridButton click="bpQueryScreen_query" text="HLS.QUERY"/>
                <a:toolbarButton click="bpQueryScreen_reset" text="HLS.RESET"/>
            </a:screenTopToolbar>
            <a:form column="4" labelWidth="120" marginWidth="50" title="HLS.QUERY_TITLE">
                <a:textField name="contract_number" bindTarget="para_con_bpQueryDs" prompt="合同编号"/>
                <a:textField name="contract_name" bindTarget="para_con_bpQueryDs" prompt="合同名称"/>
                <a:textField name="bp_id_tenant_n" bindTarget="para_con_bpQueryDs" prompt="承租人名称"/>
                <a:textField name="lease_organization_n" bindTarget="para_con_bpQueryDs" prompt="业务部"/>
                <a:textField name="division_n" bindTarget="para_con_bpQueryDs" prompt="产品线"/>
                <a:textField name="lease_channel_n" bindTarget="para_con_bpQueryDs" prompt="商业模式"/>
            </a:form>
            <a:grid id="con_bpQueryDs_grid" bindTarget="con_bpQueryDs" marginHeight="300" marginWidth="50" navBar="true">
                <a:columns>
                    <a:column name="contract_number" prompt="合同编号" width="180"/>
                    <a:column name="contract_name" prompt="合同名称" width="250"/>
                    <a:column name="bp_id_tenant_n" prompt="承租人名称" width="120"/>
                    <a:column name="lease_organization_n" prompt="业务部"/>
                    <a:column name="division_n" prompt="产品线"/>
                    <a:column name="lease_channel_n" prompt="商业模式"/>
                    <a:column name="time" prompt="传输时间" width="130"/>
                    <a:column name="result_state_n" prompt="状态" width="60"/>
                    <a:column name="resultdescription" prompt="日志" renderer="log_renderer" width="60"/>
                </a:columns>
            </a:grid>
        </a:screenBody>
    </a:view>
</a:screen>