fnd_dimension_value_assign.lview 3.54 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
<?xml version="1.0" encoding="UTF-8"?>
<a:screen xmlns:a="http://www.leaf-framework.org/application">
    <a:init-procedure>
        <a:model-query model="fnd.fnd_dimension_values" rootpath="fnd_dimension_values_assign"/>
    </a:init-procedure>
    <a:view>
        <div/>
        <script type="text/javascript"><![CDATA[
        
        function setinitdata(ds,record,index){
           record.set('dimension_value_id',${/parameter/@dimension_value_id});
        }
        
        function editFunction(record,name){
        	if(record.isNew){
        		return 'company_code_lov';
        	}
        	return '';
        }
		]]></script>
        <a:dataSets>
            <a:dataSet id="fnd_dimension_values_assign_query_ds" loadData="true">
                <a:datas dataSource="/model/fnd_dimension_values_assign"/>
                <a:fields>
                    <a:field name="dimension_value_code" readOnly="true"/>
                    <a:field name="description" readOnly="true"/>
                </a:fields>
            </a:dataSet>
            <a:dataSet id="fnd_dimension_values_assign_result_ds" autoQuery="true" model="fnd.FND2220.fnd_company_dimension_values" queryDataSet="fnd_dimension_values_assign_query_ds" selectable="true">
                <a:fields>
                    <a:field name="dimension_value_id"/>
                    <a:field name="company_id"/>
                    <a:field name="company_code" lovHeight="450" lovService="fnd.fnd_valid_company_lov" lovWidth="500" required="true" title="FND_DIMENSION_VALUES.COMPANY_ASSIGN">
                        <a:mapping>
                            <a:map from="company_id" to="company_id"/>
                            <a:map from="company_code" to="company_code"/>
                            <a:map from="company_short_name" to="company_short_name"/>
                        </a:mapping>
                    </a:field>
                    <a:field name="company_short_name"/>
                    <a:field name="enabled_flag" checkedValue="Y" defaultValue="Y" uncheckedValue="N"/>
                </a:fields>
                <a:events>
                    <a:event name="add" handler="setinitdata"/>
                </a:events>
            </a:dataSet>
        </a:dataSets>
        <a:screenBody>
            <a:fieldSet column="2" title="FND_DIMENSION_VALUES.DISTRIBUTION_DETAILS">
                <a:textField name="dimension_value_code" bindTarget="fnd_dimension_values_assign_query_ds" prompt="FND_DIMENSION_VALUES.DIMENSION_VALUE_CODE"/>
                <a:textField name="description" bindTarget="fnd_dimension_values_assign_query_ds" prompt="FND_DIMENSION_VALUES.DESCRIPTION"/>
            </a:fieldSet>
            <a:grid bindTarget="fnd_dimension_values_assign_result_ds" height="330" navBar="true" width="500">
                <a:toolBar>
                    <a:button type="add"/>
                    <a:button type="clear"/>
                    <a:button type="save"/>
                </a:toolBar>
                <a:columns>
                    <a:column name="company_code" align="center" editorFunction="editFunction"/>
                    <a:column name="company_short_name" align="left" editor="company_short_name_tf"/>
                    <a:column name="enabled_flag" editor="enabled_flag_assign_cb"/>
                </a:columns>
                <a:editors>
                    <a:lov id="company_code_lov"/>
                    <a:textField id="company_short_name_tf"/>
                    <a:checkBox id="enabled_flag_assign_cb"/>
                </a:editors>
            </a:grid>
        </a:screenBody>
    </a:view>
</a:screen>