fnd_company_levels.lview 4.48 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 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: ouyangzhaochang2663 $
    $Date: 2010/11/15 07:47:04 $
    $Revision: 1.3 $
    $Purpose: 公司级别定义
-->
<a:screen xmlns:a="http://www.leaf-framework.org/application" trace="true">
    <a:init-procedure><![CDATA[     
    ]]></a:init-procedure>
    <a:view>
        <a:link id="sys_service_welcome_link" url="${/request/@context_path}/welcome.lview"/>
        <script type="text/javascript"><![CDATA[
            function queryCompanyLevel(){
                $('fnd_company_levels_result_ds').query();
            }
            function resetCompanyLevel(){
            	$('fnd_company_levels_query_ds').reset();
            }
            	function fnd_2040_grid_add(){
                $('fnd_company_levels_grid').showEditorByRecord($('fnd_company_levels_result_ds').create());
            }
            function fnd_2040_grid_clear(){
                $('fnd_company_levels_grid').clear();
            }
            function fnd_2040_grid_submit() {
                var result_ds = $('fnd_company_levels_result_ds');
                if (result_ds.validate()) {
                    result_ds.submit();
                }
            }
            function fnd_2040_next(){
                 history.go(1);
            }
            function fnd_2040_back(){
                history.go(-1);
            }
            function fnd_2040_quit(){
                location.href = $('sys_service_welcome_link').getUrl();
                parent.shMenu('show');
            }
            function companyLevelCodeEdit(record,name){
                if(record.isNew){
                    return 'company_level_code_grid_tf';
                }else{
                    return '';
                }
            }
        ]]></script>
        <a:dataSets>
            <a:dataSet id="fnd_company_levels_query_ds" model="fnd.fnd_company_levels"/>
            <a:dataSet id="fnd_company_levels_result_ds" autoQuery="true" fetchAll="false" model="fnd.fnd_company_levels" queryDataSet="fnd_company_levels_query_ds" selectable="true">
                <a:fields>
                    <a:field name="company_level_code" required="true"/>
                    <a:field name="description" required="true"/>
                    <a:field name="enabled_flag" checkedValue="Y" defaultValue="Y" uncheckedValue="N"/>
                </a:fields>
            </a:dataSet>
        </a:dataSets>
        <a:screenBody>
            <a:screenTopToolbar>
                <a:screenTitle/>
                <a:gridButton click="fnd_2040_back" text="HLS.BACK"/>
                <a:gridButton click="fnd_2040_next" text="HLS.FORWARD"/>
                <a:gridButton click="fnd_2040_quit" text="HLS.EXIT"/>
                <a:gridButton click="fnd_2040_grid_add" text="HLS.NEW"/>
                <a:gridButton click="fnd_2040_grid_clear" text="HLS.CLEAR"/>
                <a:gridButton click="fnd_2040_grid_submit" text="HLS.SAVE"/>
                <a:gridButton click="queryCompanyLevel" text="HLS.QUERY"/>
            </a:screenTopToolbar>
            <a:form column="2" labelWidth="100" title="HAP_QUERY_TITLE">
                <a:textField name="company_level_code" bindTarget="fnd_company_levels_query_ds" typeCase="upper">
                    <a:events>
                        <a:event name="enterdown" handler="queryCompanyLevel"/>
                    </a:events>
                </a:textField>
                <a:textField name="description" bindTarget="fnd_company_levels_query_ds">
                    <a:events>
                        <a:event name="enterdown" handler="queryCompanyLevel"/>
                    </a:events>
                </a:textField>
            </a:form>
            <a:grid id="fnd_company_levels_grid" bindTarget="fnd_company_levels_result_ds" marginHeight="180" marginWidth="30">
                <a:columns>
                    <a:column name="company_level_code" align="center" editorFunction="companyLevelCodeEdit" sortable="true" width="200"/>
                    <a:column name="description" align="left" editor="description_grid_tf" width="400"/>
                    <a:column name="enabled_flag" align="center" editor="description_grid_ckb" sortable="true"/>
                </a:columns>
                <a:editors>
                    <a:textField id="company_level_code_grid_tf" typeCase="upper"/>
                    <a:textField id="description_grid_tf"/>
                    <a:checkBox id="description_grid_ckb"/>
                </a:editors>
            </a:grid>
        </a:screenBody>
    </a:view>
</a:screen>