<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: DJ  
    $Date: 2013-6-19 下午12:44:44  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
    <bm:fields>
        <bm:field name="column_name" displayWidth="200" forDisplay="true" forQuery="true" prompt="HLS030.HLS_DOC_LAYOUT_CONFIG.COLUMN_NAME"/>
        <bm:field name="prompt" displayWidth="200" forDisplay="true" forQuery="true" prompt="HLS030.HLS_DOC_LAYOUT_CONFIG.PROMPT"/>
        <bm:field name="input_mode"/>
        <bm:field name="input_mode_desc" forDisplay="true" prompt="HLS030.HLS_DOC_LAYOUT_CONFIG.INPUT_MODE"/>
        <bm:field name="display_order" displayWidth="100" forDisplay="true" prompt="HLS050.HLS_FIN_CALC_CONFIG.DISPLAY_ORDER"/>
    </bm:fields>
    <bm:operations>
        <bm:operation name="query">
            <bm:query-sql><![CDATA[
    			SELECT t1.COLUMN_NAME,
				       t1.PROMPT,
				       t1.DISPLAY_ORDER,
				       t1.INPUT_MODE,
				       (select v.code_value_name
				          from sys_code_values_v v
				         where v.code = 'HLS050_INPUT_MODE'
				           and v.code_value = t1.input_mode) as INPUT_MODE_DESC
				  FROM HLS_DOC_LAYOUT_CONFIG t1
				  #WHERE_CLAUSE#
				  order by t1.DISPLAY_ORDER
    		]]></bm:query-sql>
        </bm:operation>
    </bm:operations>
    <bm:query-fields>
        <bm:query-field name="column_name" queryExpression="t1.column_name like ${@column_name}||&apos;%&apos;"/>
        <bm:query-field field="prompt" queryOperator="like"/>
    </bm:query-fields>
    <bm:data-filters>
        <bm:data-filter enforceOperations="query" expression="t1.enabled_flag = &apos;Y&apos; AND t1.display_flag = &apos;Y&apos; AND  t1.layout_code=${@layout_code} AND t1.tab_code=${@tab_code}"/>
    </bm:data-filters>
</bm:model>
