<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: lgc5900  
    $Date: 2015年11月26日 下午1:32:12  
    $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
                    SUM(pm.quantity) quantity,
                    TO_CHAR(SUM(pm.original_asset_value)/10000 , 'FM999,999,999,990.00') original_asset_value,
                    --净值
                    TO_CHAR(SUM(pm.lease_transfer_price)/10000 , 'FM999,999,999,990.00') lease_transfer_price,
                    --评估价值（万元）
                    TO_CHAR(SUM(pm.net_asset_value)/10000 , 'FM999,999,999,990.00') net_asset_value
                FROM
                    prj_project_lease_item pm
                WHERE
                    pm.project_id = ${@project_id}
            ]]></bm:query-sql>
            <bm:parameters>
                <bm:parameter name="project_id"/>
            </bm:parameters>
        </bm:operation>
    </bm:operations>
    <bm:fields>
        <bm:field name="quantity"/>
        <bm:field name="original_asset_value"/>
        <bm:field name="net_asset_value"/>
        <bm:field name="lease_transfer_price"/>
    </bm:fields>
</bm:model>
