<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: gaoyang  
    $Date: 2013-6-21 下午01:49:23  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
    <bm:operations>
        <bm:operation name="query">
            <bm:query-sql><![CDATA[
            select t1.price_list,
			       t1.description,
			       t1.company_id,
			       t1.authority_group,
			       t1.enabled_flag,
			       t1.creation_date,
			       t1.created_by,
			       t1.last_update_date,
			       t1.last_updated_by,
			       t1.show_column_code,
			       t1.calc_method,
			       nvl(t1.column_count,5) column_count,
			       nvl(t1.field_width,120) field_width,
			       nvl(t1.label_width,100) label_width,
			       nvl(t1.margin_top,3) margin_top,
			       nvl(t1.box_width,1300) box_width,
			       nvl(t1.show_box,'N') show_box
			  from hls_price_list t1
			  #WHERE_CLAUSE#]]></bm:query-sql>
        </bm:operation>
    </bm:operations>
    <bm:fields>
        <bm:field name="price_list" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PRICE_LIST"/>
        <bm:field name="description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DESCRIPTION"/>
        <bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" required="true"/>
        <bm:field name="authority_group" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="AUTHORITY_GROUP"/>
        <bm:field name="enabled_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ENABLED_FLAG"/>
        <bm:field name="creation_date" databaseType="DATE" datatype="java.util.Date" physicalName="CREATION_DATE"/>
        <bm:field name="created_by" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CREATED_BY"/>
        <bm:field name="last_update_date" databaseType="DATE" datatype="java.util.Date" physicalName="LAST_UPDATE_DATE"/>
        <bm:field name="last_updated_by" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LAST_UPDATED_BY"/>
        <bm:field name="show_column_code" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="SHOW_COLUMN_CODE"/>
        <bm:field name="calc_method" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CALC_METHOD"/>
        <bm:field name="column_count" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COLUMN_COUNT"/>
        <bm:field name="field_width" databaseType="NUMBER" datatype="java.lang.Long" physicalName="FIELD_WIDTH"/>
        <bm:field name="label_width" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LABEL_WIDTH"/>
        <bm:field name="margin_top" databaseType="NUMBER" datatype="java.lang.Long" physicalName="MARGIN_TOP"/>
        <bm:field name="box_width" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BOX_WIDTH"/>
        <bm:field name="show_box" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="SHOW_BOX"/>
    </bm:fields>
    <bm:query-fields>
        <bm:query-field field="price_list" queryOperator="="/>
    </bm:query-fields>
    <bm:data-filters>
        <bm:data-filter name="company_id" enforceOperations="query" expression="company_id=${/session/@company_id}"/>
        <bm:data-filter name="enabled_flag" enforceOperations="query" expression="t1.enabled_flag=&apos;Y&apos;"/>
    </bm:data-filters>
</bm:model>
