<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: zhangyu  
    $Date: 2016-5-19 上午11:06:26  
    $Revision: 1.0  
    $Purpose: 
-->
<a:screen xmlns:a="http://www.leaf-framework.org/application" trace="true">
    <a:init-procedure/>
    <a:view>
        <script type="text/javascript"><![CDATA[
            function hn1010_atm_complement_config_query() {
                $('hn1010_atm_complemnt_config_ds').query();
            }
            
            function hn1020_editor_fun(record,name){
                if (record.isNew){
                    if(name=='function_code'){
                        return 'editor_tf';
                    }
                    else if(name=='document_category_desc'){
                        return 'editor_cb';
                    }
                }
                return '';
            }
            
            function hn1010_atm_complement_config_reset(){
                $('hn1020_atm_complement_config_query_ds').reset();
            }
        ]]></script>
        <a:dataSets>
            <a:dataSet id="coding_rule_doc_category_ds" loadData="true" model="hls.HLS002.hls_document_category"/>
            <a:dataSet id="approval_method_ds" lookupCode="HLS003_APPROVAL_METHOD"/>
            <a:dataSet id="enabled_flag_ds" lookupCode="YES_NO"/>
            <a:dataSet id="hn1020_atm_complement_config_query_ds">
                <a:fields>
                    <a:field name="enabled_flag_desc" displayField="code_value_name" options="enabled_flag_ds" returnField="enabled_flag" valueField="code_value"/>
                    <a:field name="document_category_desc" displayField="description" options="coding_rule_doc_category_ds" returnField="document_category" valueField="document_category"/>
                    <a:field name="function_code" lovGridHeight="350" lovHeight="550" lovService="hn.HN1010.hn1010_atm_complement_config_lov" lovWidth="500">
                        <a:mapping>
                            <a:map from="function_code" to="function_code"/>
                            <a:map from="function_description" to="function_description"/>
                            <a:map from="config_id" to="config_id"/>
                        </a:mapping>
                    </a:field>
                </a:fields>
            </a:dataSet>
            <a:dataSet id="hn1010_atm_complemnt_config_ds" autoQuery="true" model="hn.HN1020.hn1020_atm_complement_config" queryDataSet="hn1020_atm_complement_config_query_ds" selectable="true" selectionModel="single">
                <a:fields>
                    <a:field name="enabled_flag" checkedValue="Y" defaultValue="Y" uncheckedValue="N"/>
                    <a:field name="document_category_desc" displayField="description" options="coding_rule_doc_category_ds" returnField="document_category" valueField="document_category"/>
                    <a:field name="approval_method_desc" displayField="code_value_name" options="approval_method_ds" returnField="approval_method" valueField="code_value"/>
                    <a:field name="workflow_desc" lovGridHeight="300" lovHeight="480" lovLabelWidth="100" lovService="basic.hls_wfl_workflow_v_lov" lovWidth="750" title="HLS.WORKFLOW_DESC">
                        <a:mapping>
                            <a:map from="workflow_desc" to="workflow_desc"/>
                            <a:map from="workflow_id" to="workflow_id"/>
                        </a:mapping>
                    </a:field>
                    <a:field name="screen_url" lovGridHeight="330" lovHeight="460" lovService="hn.HN1020.hn1020_atm_complement_screen_lov" lovWidth="600" required="true" title="页面选择">
                        <a:mapping>
                            <a:map from="screen_id" to="screen_id"/>
                            <a:map from="screen_url" to="screen_url"/>
                            <a:map from="url_desc" to="url_desc"/>
                        </a:mapping>
                    </a:field>
                </a:fields>
            </a:dataSet>
        </a:dataSets>
        <a:screenBody>
            <a:screenTopToolbar>
                <a:screenTitle/>
                <a:gridButton bind="hn1010_atm_complemnt_config_grid" type="add"/>
                <a:gridButton bind="hn1010_atm_complemnt_config_grid" type="save"/>
                <a:gridButton click="hn1010_atm_complement_config_query" text="查询"/>
                <a:gridButton click="hn1010_atm_complement_config_reset" text="重置"/>
            </a:screenTopToolbar>
            <a:form column="4" marginWidth="30" title="查询条件">
                <a:lov name="function_code" bindTarget="hn1020_atm_complement_config_query_ds" prompt="操作代码"/>
                <a:textField name="function_description" bindTarget="hn1020_atm_complement_config_query_ds" prompt="操作描述"/>
                <a:comboBox name="document_category_desc" bindTarget="hn1020_atm_complement_config_query_ds" prompt="单据类别"/>
                <a:comboBox name="enabled_flag_desc" bindTarget="hn1020_atm_complement_config_query_ds" prompt="启用标志"/>
            </a:form>
            <a:grid id="hn1010_atm_complemnt_config_grid" bindTarget="hn1010_atm_complemnt_config_ds" marginHeight="180" marginWidth="30" navBar="true">
                <a:columns>
                    <a:column name="function_code" editorFunction="hn1020_editor_fun" prompt="功能操作" width="140"/>
                    <a:column name="function_description" editor="editor_tf" prompt="操作描述" width="200"/>
                    <a:column name="document_category_desc" editorFunction="hn1020_editor_fun" prompt="单据类别" width="90"/>
                    <a:column name="approval_method_desc" editor="editor_cb" prompt="审批方式" width="100"/>
                    <a:column name="workflow_desc" editor="editor_lov" prompt="工作流" width="150"/>
                    <a:column name="table_name" editor="editor_tf" prompt="表名" width="200"/>
                    <a:column name="screen_url" editor="editor_lov" prompt="维护页面路径" width="120"/>
                    <a:column name="url_desc" prompt="页面名称" width="150"/>
                    <a:column name="enabled_flag" editor="editor_chb" prompt="启用标志" width="80"/>
                </a:columns>
                <a:editors>
                    <a:textField id="editor_tf"/>
                    <a:comboBox id="editor_cb"/>
                    <a:lov id="editor_lov"/>
                    <a:checkBox id="editor_chb"/>
                </a:editors>
            </a:grid>
        </a:screenBody>
    </a:view>
</a:screen>