fnd_city.lview 4.86 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 98 99 100 101 102 103 104 105 106 107 108 109 110
<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: zhenwe.yin $
    $Date: 2013/4/2 15:06:05 $
    $Revision: 1.0 $
    $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 queryCity() {
                $('fnd_city_result_ds').query();
            }
            
            function resetCity() {
                $('fnd_city_query_ds').reset();
            }
            
            function fnd_013_next() {
                history.go(1);
            }
            
            function fnd_013_back() {
                history.go(-1);
            }
            
            function fnd_013_quit() {
                location.href = $('sys_service_welcome_link').getUrl();
                parent.shMenu('show');
            }
            
            function fnd_013_grid_add() {
                var grid = $('fnd_city_grid');
                $('fnd_city_grid').showEditorByRecord($('fnd_city_result_ds').create());
            }
            
            function fnd_013_grid_clear() {
                $('fnd_city_grid').clear();
            }
            
            function fnd_013_grid_submit() {
                $('fnd_city_result_ds').submit();
            }
            
            function fnd_013_submitsuccess() {
                $('fnd_city_result_ds').query();
            }
        ]]></script>
        <a:dataSets>
            <a:dataSet id="fnd_city_query_ds" model="fnd.FND013.fnd_city"/>
            <a:dataSet id="fnd_city_result_ds" autoQuery="true" fetchAll="false" model="fnd.FND013.fnd_city" pageSize="15" queryDataSet="fnd_city_query_ds" selectable="true">
                <a:fields>
                    <a:field name="province_code_desc" autoComplete="true" lovGridHeight="300" lovHeight="450" lovService="basic.fnd_province_for_lov" lovWidth="650" required="true" title="HLS.PROVINCE_CODE_QUERY">
                        <a:mapping>
                            <a:map from="province_id" to="province_id"/>
                            <a:map from="description" to="province_code_desc"/>
                        </a:mapping>
                    </a:field>
                    <a:field name="province_id"/>
                    <a:field name="city_code" required="true"/>
                    <a:field name="description" required="true"/>
                    <a:field name="print_name"/>
                    <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_013_back" text="HLS.BACK"/>
                <a:gridButton click="fnd_013_next" text="HLS.FORWARD"/>
                <a:gridButton click="fnd_013_quit" text="HLS.EXIT"/>
                <a:gridButton click="fnd_013_grid_add" text="HLS.NEW"/>
                <a:gridButton click="fnd_013_grid_clear" text="HLS.CLEAR"/>
                <a:gridButton click="fnd_013_grid_submit" text="HLS.SAVE"/>
                <a:gridButton click="queryCity" text="HLS.QUERY"/>
            </a:screenTopToolbar>
            <a:form column="2" title="HLS.QUERY_TITLE">
                <a:textField name="city_code" bindTarget="fnd_city_query_ds" typeCase="upper">
                    <a:events>
                        <a:event name="enterdown" handler="queryCity"/>
                    </a:events>
                </a:textField>
                <a:textField name="description" bindTarget="fnd_city_query_ds">
                    <a:events>
                        <a:event name="enterdown" handler="queryCity"/>
                    </a:events>
                </a:textField>
            </a:form>
            <a:grid id="fnd_city_grid" bindTarget="fnd_city_result_ds" marginHeight="180" marginWidth="30" navBar="true">
                <a:columns>
                    <a:column name="province_code_desc" editor="cityDs_lov" prompt="HLS.PROVINCE_NAME" width="250"/>
                    <a:column name="city_code" editor="cityCodeDs_tf" width="140"/>
                    <a:column name="description" editor="cityDs_tf" width="350"/>
                    <a:column name="print_name" editor="cityDs_tf" width="350"/>
                    <a:column name="enabled_flag" editor="cityCodeDs_chk" width="50"/>
                </a:columns>
                <a:editors>
                    <a:textField id="cityCodeDs_tf" maxLength="6"/>
                    <a:textField id="cityDs_tf"/>
                    <a:checkBox id="cityCodeDs_chk"/>
                    <a:lov id="cityDs_lov"/>
                </a:editors>
            </a:grid>
        </a:screenBody>
    </a:view>
</a:screen>