<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: Clocc  
    $Date: 2015-7-30 下午4:16:48  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:f="leaf.database.features" xmlns:bm="http://www.leaf-framework.org/schema/bm" alias="t1" baseTable="CUS_RPT_CUS312_O" defaultOrderBy="SUBSTR(T1.SEARCH_TERM_1,-7)">
    <bm:fields>
        <bm:field name="control_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTROL_ID" prompt="CUS_RPT_CUS312_O.CONTROL_ID"/>
        <bm:field name="contract_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTRACT_ID" prompt="CUS_RPT_CUS312_O.CONTRACT_ID"/>
        <bm:field name="contract_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS" prompt="CUS_RPT_CUS312_O.CONTRACT_STATUS"/>
        <bm:field name="contract_status_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS_N" prompt="CUS_RPT_CUS312_O.CONTRACT_STATUS_N"/>
        <bm:field name="contract_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NUMBER" prompt="CUS_RPT_CUS312_O.CONTRACT_NUMBER"/>
        <bm:field name="search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="SEARCH_TERM_1" prompt="CUS_RPT_CUS312_O.SEARCH_TERM_1"/>
        <bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" prompt="CUS_RPT_CUS312_O.COMPANY_ID"/>
        <bm:field name="company_id_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="COMPANY_ID_N" prompt="CUS_RPT_CUS312_O.COMPANY_ID_N"/>
        <bm:field name="bp_id_tenant" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BP_ID_TENANT" prompt="CUS_RPT_CUS312_O.BP_ID_TENANT"/>
        <bm:field name="bp_id_tenant_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_ID_TENANT_N" prompt="CUS_RPT_CUS312_O.BP_ID_TENANT_N"/>
        <bm:field name="period_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PERIOD_NAME" prompt="CUS_RPT_CUS312_O.PERIOD_NAME"/>
        <bm:field name="inception_of_lease" databaseType="DATE" datatype="java.util.Date" physicalName="INCEPTION_OF_LEASE" prompt="CUS_RPT_CUS312_O.INCEPTION_OF_LEASE"/>
        <bm:field name="signing_date" databaseType="DATE" datatype="java.util.Date" physicalName="SIGNING_DATE" prompt="CUS_RPT_CUS312_O.SIGNING_DATE"/>
        <bm:field name="received_date" databaseType="DATE" datatype="java.util.Date" physicalName="RECEIVED_DATE" prompt="CUS_RPT_CUS312_O.RECEIVED_DATE"/>
        <bm:field name="lease_channel" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEASE_CHANNEL" prompt="CUS_RPT_CUS312_O.LEASE_CHANNEL"/>
        <bm:field name="lease_channel_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEASE_CHANNEL_N" prompt="CUS_RPT_CUS312_O.LEASE_CHANNEL_N"/>
        <bm:field name="division" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DIVISION" prompt="CUS_RPT_CUS312_O.DIVISION"/>
        <bm:field name="division_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DIVISION_N" prompt="CUS_RPT_CUS312_O.DIVISION_N"/>
        <bm:field name="specification" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="SPECIFICATION" prompt="CUS_RPT_CUS312_O.SPECIFICATION"/>
        <bm:field name="serial_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="SERIAL_NUMBER" prompt="CUS_RPT_CUS312_O.SERIAL_NUMBER"/>
        <bm:field name="bp_id_vender" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BP_ID_VENDER" prompt="CUS_RPT_CUS312_O.BP_ID_VENDER"/>
        <bm:field name="bp_id_vender_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_ID_VENDER_N" prompt="CUS_RPT_CUS312_O.BP_ID_VENDER_N"/>
        <bm:field name="bp_id_tenant_province_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BP_ID_TENANT_PROVINCE_ID" prompt="CUS_RPT_CUS312_O.BP_ID_TENANT_PROVINCE_ID"/>
        <bm:field name="bp_id_tenant_province_id_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_ID_TENANT_PROVINCE_ID_N" prompt="CUS_RPT_CUS312_O.BP_ID_TENANT_PROVINCE_ID_N"/>
        <bm:field name="lease_item_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="LEASE_ITEM_AMOUNT" prompt="CUS_RPT_CUS312_O.LEASE_ITEM_AMOUNT"/>
        <bm:field name="insurance_fee" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INSURANCE_FEE" prompt="CUS_RPT_CUS312_O.INSURANCE_FEE"/>
        <bm:field name="csa" databaseType="NUMBER" datatype="java.lang.Double" physicalName="CSA" prompt="CUS_RPT_CUS312_O.CSA"/>
        <bm:field name="payment_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PAYMENT_AMOUNT" prompt="CUS_RPT_CUS312_O.PAYMENT_AMOUNT"/>
        <bm:field name="lease_mgt_fee" databaseType="NUMBER" datatype="java.lang.Double" physicalName="LEASE_MGT_FEE" prompt="CUS_RPT_CUS312_O.LEASE_MGT_FEE"/>
        <bm:field name="residual_value" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RESIDUAL_VALUE" prompt="CUS_RPT_CUS312_O.RESIDUAL_VALUE"/>
        <bm:field name="deposit" databaseType="NUMBER" datatype="java.lang.Double" physicalName="DEPOSIT" prompt="CUS_RPT_CUS312_O.DEPOSIT"/>
        <bm:field name="down_payment" databaseType="NUMBER" datatype="java.lang.Double" physicalName="DOWN_PAYMENT" prompt="CUS_RPT_CUS312_O.DOWN_PAYMENT"/>
        <bm:field name="change_req_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CHANGE_REQ_TYPE" prompt="CUS_RPT_CUS312_O.CHANGE_REQ_TYPE"/>
        <bm:field name="change_req_date" databaseType="DATE" datatype="java.util.Date" physicalName="CHANGE_REQ_DATE" prompt="CUS_RPT_CUS312_O.CHANGE_REQ_DATE"/>
        <bm:field name="ccr_fee" databaseType="NUMBER" datatype="java.lang.Double" physicalName="CCR_FEE" prompt="CUS_RPT_CUS312_O.CCR_FEE"/>
        <bm:field name="actual_finance_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="ACTUAL_FINANCE_AMOUNT" prompt="CUS_RPT_CUS312_O.ACTUAL_FINANCE_AMOUNT"/>
        <bm:field name="total_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="TOTAL_INTEREST" prompt="CUS_RPT_CUS312_O.TOTAL_INTEREST"/>
        <bm:field name="total_rental" databaseType="NUMBER" datatype="java.lang.Double" physicalName="TOTAL_RENTAL" prompt="CUS_RPT_CUS312_O.TOTAL_RENTAL"/>
        <bm:field name="finance_income" databaseType="NUMBER" datatype="java.lang.Double" physicalName="FINANCE_INCOME" prompt="CUS_RPT_CUS312_O.FINANCE_INCOME"/>
        <bm:field name="due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="DUE_AMOUNT" prompt="CUS_RPT_CUS312_O.DUE_AMOUNT"/>
        <bm:field name="received_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_AMOUNT" prompt="CUS_RPT_CUS312_O.RECEIVED_AMOUNT"/>
        <bm:field name="int_rate" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INT_RATE" prompt="CUS_RPT_CUS312_O.INT_RATE"/>
        <bm:field name="collected_times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COLLECTED_TIMES" prompt="CUS_RPT_CUS312_O.COLLECTED_TIMES"/>
        <bm:field name="uncollected_times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="UNCOLLECTED_TIMES" prompt="CUS_RPT_CUS312_O.UNCOLLECTED_TIMES"/>
        <bm:field name="overdue_times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_TIMES" prompt="CUS_RPT_CUS312_O.OVERDUE_TIMES"/>
        <bm:field name="lease_times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LEASE_TIMES" prompt="CUS_RPT_CUS312_O.LEASE_TIMES"/>
        <bm:field name="penalty" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PENALTY" prompt="CUS_RPT_CUS312_O.PENALTY"/>
        <bm:field name="uncollected_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="UNCOLLECTED_AMOUNT" prompt="CUS_RPT_CUS312_O.UNCOLLECTED_AMOUNT"/>
        <bm:field name="net_invest_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_INVEST_AMOUNT" prompt="CUS_RPT_CUS312_O.NET_INVEST_AMOUNT"/>
        <bm:field name="uncollected_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="UNCOLLECTED_INTEREST" prompt="CUS_RPT_CUS312_O.UNCOLLECTED_INTEREST"/>
        <bm:field name="interest_current" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INTEREST_CURRENT" prompt="CUS_RPT_CUS312_O.INTEREST_CURRENT"/>
        <bm:field name="collected_rental" databaseType="NUMBER" datatype="java.lang.Double" physicalName="COLLECTED_RENTAL" prompt="CUS_RPT_CUS312_O.COLLECTED_RENTAL"/>
        <bm:field name="interest_straight" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INTEREST_STRAIGHT" prompt="CUS_RPT_CUS312_O.INTEREST_STRAIGHT"/>
        <bm:field name="uncollected_interest_straight" databaseType="NUMBER" datatype="java.lang.Double" physicalName="UNCOLLECTED_INTEREST_STRAIGHT" prompt="CUS_RPT_CUS312_O.UNCOLLECTED_INTEREST_STRAIGHT"/>
        <bm:field name="down_payment_1" databaseType="NUMBER" datatype="java.lang.Double" physicalName="DOWN_PAYMENT_1" prompt="CUS_RPT_CUS312_O.DOWN_PAYMENT_1"/>
        <bm:field name="reschedule_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="RESCHEDULE_FLAG" prompt="CUS_RPT_CUS312_O.RESCHEDULE_FLAG"/>
        <bm:field name="et_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ET_FLAG" prompt="CUS_RPT_CUS312_O.ET_FLAG"/>
        <bm:field name="cashflow_change_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CASHFLOW_CHANGE_FLAG" prompt="CUS_RPT_CUS312_O.CASHFLOW_CHANGE_FLAG"/>
        <bm:field name="transaction_date" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TRANSACTION_DATE" prompt="CUS_RPT_CUS312_O.TRANSACTION_DATE"/>
        <bm:field name="uncollected_ar" databaseType="NUMBER" datatype="java.lang.Double" physicalName="UNCOLLECTED_AR" prompt="CUS_RPT_CUS312_O.UNCOLLECTED_AR"/>
        <bm:field name="all_file_confirm_status_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ALL_FILE_CONFIRM_STATUS_N" prompt="CUS_RPT_CUS312_O.ALL_FILE_CONFIRM_STATUS_N"/>
        <bm:field name="payment_others" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PAYMENT_OTHERS" prompt="CUS_RPT_CUS312_O.PAYMENT_OTHERS"/>
        <bm:field name="gross" databaseType="NUMBER" datatype="java.lang.Double" physicalName="GROSS" prompt="CUS_RPT_CUS312_O.GROSS"/>
        <bm:field name="net_fin" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_FIN" prompt="CUS_RPT_CUS312_O.NET_FIN"/>
        <bm:field name="unearned_income_fin" databaseType="NUMBER" datatype="java.lang.Double" physicalName="UNEARNED_INCOME_FIN" prompt="CUS_RPT_CUS312_O.UNEARNED_INCOME_FIN"/>
        <bm:field name="interest_reverse" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INTEREST_REVERSE" prompt="CUS_RPT_CUS312_O.INTEREST_REVERSE"/>
        <bm:field name="vat_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="VAT_FLAG" prompt="CUS_RPT_CUS312_O.VAT_FLAG"/>
        <bm:field name="principal_implicit_next_12" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PRINCIPAL_IMPLICIT_NEXT_12" prompt="CUS_RPT_CUS312_O.PRINCIPAL_IMPLICIT_NEXT_12"/>
        <bm:field name="principal_implicit_next_12_p" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PRINCIPAL_IMPLICIT_NEXT_12_P" prompt="CUS_RPT_CUS312_O.PRINCIPAL_IMPLICIT_NEXT_12_P"/>
        <bm:field name="operation_fee" databaseType="NUMBER" datatype="java.lang.Double" physicalName="OPERATION_FEE" prompt="CUS_RPT_CUS312_O.OPERATION_FEE"/>
        <bm:field name="legal_status_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEGAL_STATUS_N" prompt="CUS_RPT_CUS312_O.LEGAL_STATUS_N"/>
        <bm:field name="lawsuit_status_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LAWSUIT_STATUS_N" prompt="CUS_RPT_CUS312_O.LAWSUIT_STATUS_N"/>
        <bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" prompt="CUS_RPT_CUS312_O.DOCUMENT_TYPE"/>
        <bm:field name="operation_fee_three" databaseType="NUMBER" datatype="java.lang.Double" physicalName="OPERATION_FEE_THREE" prompt="CUS_RPT_CUS312_O.OPERATION_FEE_THREE"/>
        <bm:field name="branch_company_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BRANCH_COMPANY_N" prompt="CUS_RPT_CUS312_O.BRANCH_COMPANY_N"/>
        <bm:field name="province_id_n" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROVINCE_ID_N" prompt="CUS_RPT_CUS312_O.PROVINCE_ID_N"/>
    </bm:fields>
    <bm:features>
        <f:standard-who/>
    </bm:features>
    <bm:query-fields>
        <bm:query-field field="bp_id_tenant_n" queryOperator="like"/>
        <bm:query-field field="search_term_1" queryOperator="like"/>
        <bm:query-field field="contract_number" queryOperator="like"/>
        <bm:query-field field="period_name" queryOperator="like"/>
        <bm:query-field name="lease_channel_n" queryExpression="t1.lease_channel_n = ${@lease_channel_n}"/>
    </bm:query-fields>
    <bm:data-filters>
        <bm:data-filter name="init" enforceOperations="query" expression="t1.control_id=${@control_id}"/>
    </bm:data-filters>
</bm:model>
