<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: zhangxing5129  
    $Date: 2013-9-12 下午03:57:56  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" xmlns:f="leaf.database.features" alias="t1" baseTable="HLS_FIN_CALC_CONFIG_TEMPLT" defaultOrderBy="display_order,column_code" needAccessControl="false">
    <bm:fields>
        <bm:field name="layout_area_seq" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LAYOUT_AREA_SEQ" prompt="HLS050.HLS_FIN_CALC_CONFIG.LAYOUT_AREA_SEQ"/>
        <bm:field name="column_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="COLUMN_NAME" prompt="HLS050.HLS_FIN_CALC_CONFIG.COLUMN_NAME"/>
        <bm:field name="column_comment" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="COLUMN_COMMENT" prompt="HLS050.HLS_FIN_CALC_CONFIG.COLUMN_COMMENT"/>
        <bm:field name="column_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COLUMN_ID" prompt="HLS050.HLS_FIN_CALC_CONFIG.COLUMN_ID"/>
        <bm:field name="column_code" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="COLUMN_CODE" prompt="HLS050.HLS_FIN_CALC_CONFIG.COLUMN_CODE"/>
        <bm:field name="cf_item" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CF_ITEM" prompt="HLS.CF_ITEM"/>
        <bm:field name="data_type" databaseType="VARCHAR2" datatype="java.lang.String" forUpdate="false" lookupCode="HLS050_DATA_TYPE" lookupField="data_type_display" physicalName="DATA_TYPE"/>
        <bm:field name="data_type_display" forInsert="false" forUpdate="false" prompt="HLS050.HLS_FIN_CALC_CONFIG.DATA_TYPE"/>
        <bm:field name="system_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="SYSTEM_FLAG" prompt="HLS050.HLS_FIN_CALC_CONFIG.SYSTEM_FLAG"/>
        <bm:field name="key_field_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="KEY_FIELD_FLAG" prompt="HLS050.HLS_FIN_CALC_CONFIG.KEY_FIELD_FLAG"/>
        <bm:field name="enabled_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ENABLED_FLAG" prompt="HLS050.HLS_FIN_CALC_CONFIG.ENABLED_FLAG"/>
        <bm:field name="display_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DISPLAY_FLAG" prompt="HLS050.HLS_FIN_CALC_CONFIG.DISPLAY_FLAG"/>
        <bm:field name="display_order" databaseType="NUMBER" datatype="java.lang.Long" physicalName="DISPLAY_ORDER" prompt="HLS050.HLS_FIN_CALC_CONFIG.DISPLAY_ORDER"/>
        <bm:field name="prompt" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROMPT" prompt="HLS050.HLS_FIN_CALC_CONFIG.PROMPT"/>
        <bm:field name="input_mode" databaseType="VARCHAR2" datatype="java.lang.String" lookupCode="HLS050_INPUT_MODE" lookupField="input_mode_display" physicalName="INPUT_MODE"/>
        <bm:field name="input_mode_display" forInsert="false" forUpdate="false" prompt="HLS050.HLS_FIN_CALC_CONFIG.INPUT_MODE"/>
        <bm:field name="validation_type" databaseType="VARCHAR2" datatype="java.lang.String" lookupCode="HLS050_VALIDATION_TYPE" lookupField="validation_type_display" physicalName="VALIDATION_TYPE"/>
        <bm:field name="validation_type_display" forInsert="false" forUpdate="false" prompt="HLS050.HLS_FIN_CALC_CONFIG.VALIDATION_TYPE"/>
        <bm:field name="validation_sql" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="VALIDATION_SQL" prompt="HLS050.HLS_FIN_CALC_CONFIG.VALIDATION_SQL"/>
        <bm:field name="precision" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PRECISION" prompt="HLS050.HLS_FIN_CALC_CONFIG.PRECISION"/>
        <bm:field name="zero_fill" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ZERO_FILL" prompt="HLS050.HLS_FIN_CALC_CONFIG.ZERO_FILL"/>
        <bm:field name="allow_format" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ALLOW_FORMAT" prompt="HLS050.HLS_FIN_CALC_CONFIG.ALLOW_FORMAT"/>
        <bm:field name="allow_decimal" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ALLOW_DECIMAL" prompt="HLS050.HLS_FIN_CALC_CONFIG.ALLOW_DECIMAL"/>
        <bm:field name="alignment" databaseType="VARCHAR2" datatype="java.lang.String" lookupCode="HLS050_ALIGNMENT" lookupField="alignment_display" physicalName="ALIGNMENT" prompt="HLS050.HLS_FIN_CALC_CONFIG.ALIGNMENT"/>
        <bm:field name="alignment_display" forInsert="false" forUpdate="false" prompt="HLS050.HLS_FIN_CALC_CONFIG.ALIGNMENT"/>
        <bm:field name="width" databaseType="NUMBER" datatype="java.lang.Long" physicalName="WIDTH" prompt="HLS050.HLS_FIN_CALC_CONFIG.WIDTH"/>
        <bm:field name="percent" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PERCENT" prompt="HLS050.HLS_FIN_CALC_CONFIG.PERCENT"/>
        <bm:field name="default_value" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DEFAULT_VALUE" prompt="HLS050.HLS_FIN_CALC_CONFIG.DEFAULT_VALUE"/>
        <bm:field name="upper_limit" databaseType="NUMBER" datatype="java.lang.Long" physicalName="UPPER_LIMIT" prompt="HLS050.HLS_FIN_CALC_CONFIG.UPPER_LIMIT"/>
        <bm:field name="lower_limit" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LOWER_LIMIT" prompt="HLS050.HLS_FIN_CALC_CONFIG.LOWER_LIMIT"/>
        <bm:field name="usage_quotation" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="USAGE_QUOTATION" prompt="HLS050.HLS_FIN_CALC_CONFIG.USAGE_QUOTATION"/>
        <bm:field name="usage_lease_chance" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="USAGE_LEASE_CHANCE" prompt="HLS050.HLS_FIN_CALC_CONFIG.USAGE_LEASE_CHANCE"/>
        <bm:field name="usage_project" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="USAGE_PROJECT" prompt="HLS050.HLS_FIN_CALC_CONFIG.USAGE_PROJECT"/>
        <bm:field name="usage_contract" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="USAGE_CONTRACT" prompt="HLS050.HLS_FIN_CALC_CONFIG.USAGE_CONTRACT"/>
        <bm:field name="usage_change_req" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="USAGE_CHANGE_REQ" prompt="HLS050.HLS_FIN_CALC_CONFIG.USAGE_CHANGE_REQ"/>
        <bm:field name="usage_calculator" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="USAGE_CALCULATOR" prompt="HLS050.HLS_FIN_CALC_CONFIG.USAGE_CALCULATOR"/>
        <bm:field name="lov_return_vcode" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LOV_RETURN_VCODE" prompt="HLS050.HLS_FIN_CALC_CONFIG.LOV_RETURN_VCODE"/>
    </bm:fields>
    <bm:features>
        <f:standard-who/>
    </bm:features>
    <bm:primary-key>
        <bm:pk-field name="column_code"/>
    </bm:primary-key>
    <bm:query-fields>
        <!--  <bm:query-field field="config_id" queryOperator="="/> -->
        <bm:query-field field="column_code" queryOperator="like"/>
        <bm:query-field field="column_name" queryOperator="like"/>
        <bm:query-field field="prompt" queryOperator="like"/>
        <bm:query-field field="data_type" queryOperator="="/>
        <bm:query-field field="input_mode" queryOperator="="/>
        <bm:query-field field="validation_type" queryOperator="="/>
        <bm:query-field field="alignment" queryOperator="="/>
        <bm:query-field name="enabled_flag" queryExpression="(${@enabled_flag} = &apos;ALL&apos; or t1.enabled_flag = ${@enabled_flag})"/>
        <bm:query-field name="display_flag" queryExpression="(${@display_flag} = &apos;ALL&apos; or t1.display_flag = ${@display_flag})"/>
        <bm:query-field name="allow_decimal" queryExpression="(${@allow_decimal} = &apos;ALL&apos; or t1.allow_decimal = ${@allow_decimal})"/>
    </bm:query-fields>
    <bm:data-filters>
        <bm:data-filter name="layout_area_seq" enforceOperations="query" expression="layout_area_seq=${@layout_area_seq}"/>
    </bm:data-filters>
</bm:model>
