<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: lixi  
    $Date: 2011-7-12 下午06:55:08  
    $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 * from (
            select t.req_item_id, t.req_item_code, t.description
			  from exp_req_items_vl t
			 where t.enabled_flag = 'Y'
			and t.set_of_books_id = ${/parameter/@set_of_books_id}
			) v
			#WHERE_CLAUSE#
			order by req_item_code
			]]></bm:query-sql>
            <bm:parameters>
                <bm:parameter inputPath="/parameter/@set_of_books_id"/>
            </bm:parameters>
        </bm:operation>
    </bm:operations>
    <bm:query-fields>
        <bm:query-field name="req_item_code" queryExpression="req_item_code like ${@req_item_code}"/>
        <bm:query-field name="description" queryExpression="description like &apos;%&apos;||${@description}||&apos;%&apos;"/>
    </bm:query-fields>
    <bm:fields>
        <bm:field name="req_item_id"/>
        <bm:field name="req_item_code" displayWidth="233" forDisplay="true" forQuery="true" prompt="申请项目"/>
        <bm:field name="description" displayWidth="235" forDisplay="true" forQuery="true" prompt="描述"/>
    </bm:fields>
</bm:model>
