<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: weiwuzhen  
    $Date: 2016-4-27 上午11:00:30  
    $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 p.chance_id,
        p.bp_id,
		P.lease_organization, --业务部
        p.project_name, --项目名称        
        p.industry_insurance_yn, --是否符合行业准入标准
        -- p.expect_register_date, --提交项目评审时间
        to_char(p.expect_register_date,'yyyy')||'年'||to_char(p.expect_register_date,'mm')||'月'||to_char(p.expect_register_date,'dd')||'日' expect_register_date,
        --p.expect_sign_date, --签约时间
         to_char(p.expect_sign_date,'yyyy')||'年'||to_char(p.expect_sign_date,'mm')||'月'||to_char(p.expect_sign_date,'dd')||'日' expect_sign_date,
       -- p.inception_of_lease, --对外付款时间
        to_char(to_date(p.inception_of_lease,'yyyy-mm-dd'),'yyyy')||'年'||to_char(to_date(p.inception_of_lease,'yyyy-mm-dd'),'mm')||'月'||to_char(to_date(p.inception_of_lease,'yyyy-mm-dd'),'dd')||'日' inception_of_lease,  
        --p.lease_start_date， --项目起租日
        to_char(to_date(p.lease_start_date,'yyyy-mm-dd'),'yyyy')||'年'||to_char(to_date(p.lease_start_date,'yyyy-mm-dd'),'mm')||'月'||to_char(to_date(p.lease_start_date,'yyyy-mm-dd'),'dd')||'日' lease_start_date, 
        P.text
   from prj_chance_lv p
	where p.chance_id=${/parameter/@chance_id}


]]></bm:query-sql>
        </bm:operation>
    </bm:operations>
    <!-- <bm:fields>
        <bm:field name="project_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NAME"/>
        <bm:field name="binary_classification_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BINARY_CLASSIFICATION_N"/>
        <bm:field name="lease_itme_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEASE_ITME_NAME"/>
        <bm:field name="lease_project_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEASE_PROJECT_NAME"/>
        <bm:field name="lease_amount" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEASE_AMOUNT"/>
        <bm:field name="industry_insurance_yn" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INDUSTRY_INSURANCE_YN"/>
        <bm:field name="expect_register_date" databaseType="DATE" datatype="java.util.Date" physicalName="EXPECT_REGISTER_DATE"/>
        <bm:field name="expect_sign_date" databaseType="DATE" datatype="java.util.Date" physicalName="EXPECT_SIGN_DATE"/>
        <bm:field name="inception_of_lease" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INCEPTION_OF_LEASE"/>
        <bm:field name="lease_start_date" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEASE_START_DATE"/>
        <bm:field name="chance_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CHANCE_ID" required="true"/>
    </bm:fields> -->
    <!-- <bm:query-fields>
        <bm:query-field name="chance_id" queryExpression="chance_id=${@chance_id}"/>
    </bm:query-fields> -->
</bm:model>
