<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: wujun  
    $Date: 2017-4-7 上午10:41:00  
    $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 fbrs.base_rate_set,
			       fbrs.description,
			       fbrs.base_rate_type,
			       fbrs.currency,
			       fbrs.enabled_flag,
			       fbrs.valid_from,
			       fbrs.valid_to,
			       fbrs.approve_status
			  from fnd_base_rate_set fbrs
			 where fbrs.approve_status = 'APPROVED'
			 ) t1 #WHERE_CLAUSE# ORDER BY t1.base_rate_type,t1.valid_from
			]]></bm:query-sql>
        </bm:operation>
    </bm:operations>
    <bm:query-fields>
        <bm:query-field name="base_rate_type" queryExpression="t1.base_rate_type=${@base_rate_type}"/>
        <bm:query-field name="currency" queryExpression="t1.currency=${@currency}"/>
        <bm:query-field name="enabled_flag" queryExpression="t1.enabled_flag=${@enabled_flag}"/>
    </bm:query-fields>
</bm:model>
