<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: qianming
    $Date: 2015-9-7 
    $Revision: 1.0  
    $Purpose: 单据类型分配租赁形式/项目类型
-->
<bm:model xmlns:o="leaf.database.local.oracle" xmlns:bm="http://www.leaf-framework.org/schema/bm" xmlns:f="leaf.database.features" alias="t1" baseTable="BGFL_DOCUMENT_TYPE_AGN_PTYPE">
    <bm:fields>
        <bm:field name="lease_form" forDisplay="true" forQuery="true" lookupCode="LEASE_FORM" lookupField="lease_form_n" physicalName="LEASE_FORM" prompt="租赁形式编码"/>
        <bm:field name="lease_form_n" forDisplay="true" forQuery="true" prompt="租赁形式描述"/>
        <bm:field name="document_type_n" expression="(select description from hls_document_type where document_type = t1.document_type)" forDisplay="true" forInsert="false" forUpdate="false" prompt="所属单据类型"/>
    </bm:fields>
    <bm:data-filters>
        <bm:data-filter enforceOperations="query" expression="t1.document_type = ${@document_type}"/>
    </bm:data-filters>
    <bm:query-fields>
        <bm:query-field field="lease_form" queryExpression="upper(t1.lease_form) like &apos;%&apos; || upper(${@lease_form}) || &apos;%&apos;"/>
        <bm:query-field field="lease_form_n" queryExpression="upper(t1.lease_form_n) like &apos;%&apos; || upper(${@lease_form_n}) || &apos;%&apos;"/>
    </bm:query-fields>
</bm:model>
