<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: gaoyang  
    $Date: 2013-4-15 下午01:13:07  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" xmlns:f="leaf.database.features" alias="t1" baseTable="HLS_BP_MASTER_V" defaultOrderBy="bp_code" needAccessControl="false">
    <bm:fields>
        <bm:field name="bp_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BP_ID" prompt="HLS_BP_MASTER_V.BP_ID"/>
        <bm:field name="bp_code" databaseType="VARCHAR2" datatype="java.lang.String" displayWidth="242" forDisplay="true" forQuery="true" physicalName="BP_CODE" prompt="HLS.BP_CODE" queryWidth="150"/>
        <bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" displayWidth="242" forDisplay="true" forQuery="true" physicalName="BP_NAME" prompt="HLS.BP_NAME" queryWidth="150"/>
        <bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" prompt="HLS_BP_MASTER_V.COMPANY_ID"/>
        <bm:field name="company_code" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="COMPANY_CODE" prompt="HLS_BP_MASTER_V.COMPANY_CODE"/>
        <bm:field name="company_short_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="COMPANY_SHORT_NAME" prompt="HLS_BP_MASTER_V.COMPANY_SHORT_NAME"/>
        <bm:field name="company_full_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="COMPANY_FULL_NAME" prompt="HLS_BP_MASTER_V.COMPANY_FULL_NAME"/>
        <bm:field name="bp_category" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_CATEGORY"/>
        <bm:field name="bp_category_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_CATEGORY_NAME"/>
        <bm:field name="bp_class" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_CLASS"/>
        <bm:field name="bp_class_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_CLASS_NAME"/>
        <!-- <bm:field name="created_by" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CREATED_BY" prompt="HLS_BP_MASTER_V.CREATED_BY"/> -->
    </bm:fields>
    <bm:features>
        <f:standard-who/>
    </bm:features>
    <bm:query-fields>
        <bm:query-field field="bp_code" queryOperator="like"/>
        <bm:query-field field="bp_name" queryOperator="like"/>
        <bm:query-field field="bp_category" queryOperator="="/>
        <bm:query-field field="company_id" queryOperator="="/>
        <!-- <bm:query-field field="created_by" queryExpression="(t1.created_by=${/parameter/@user_id})" queryOperator="="/> -->
    </bm:query-fields>
    <!--商业伙伴需要分配公司权限，这里需要放出DF，否则查询商业伙伴重复，如他出使用此BM，请复制重做   modify：qm-->
    <bm:data-filters>
        <bm:data-filter name="query" expression="(t1.company_id=${/session/@company_id})"/>
    </bm:data-filters>
</bm:model>
