<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: hp  
    $Date: 2015-1-4 下午7:04:08  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" xmlns:f="leaf.database.features" alias="t1" baseTable="CON_CONTRACT_LAW">
    <bm:fields>
        <bm:field name="law_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LAW_ID" prompt="CON_CONTRACT_LAW.LAW_ID"/>
        <bm:field name="contract_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTRACT_ID" prompt="CON_CONTRACT_LAW.CONTRACT_ID"/>
        <bm:field name="legal_des" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEGAL_DES" prompt="CON_CONTRACT_LAW.LEGAL_DES"/>
        <bm:field name="law_dispose_period" databaseType="DATE" datatype="java.util.Date" physicalName="LAW_DISPOSE_PERIOD" prompt="CON_CONTRACT_LAW.LAW_DISPOSE_PERIOD"/>
        <bm:field name="machine_letter_period" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="MACHINE_LETTER_PERIOD" prompt="CON_CONTRACT_LAW.MACHINE_LETTER_PERIOD"/>
        <bm:field name="law_office" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LAW_OFFICE" prompt="CON_CONTRACT_LAW.LAW_OFFICE"/>
        <bm:field name="lawyer" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LAWYER" prompt="CON_CONTRACT_LAW.LAWYER"/>
        <bm:field name="dispose_period" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DISPOSE_PERIOD" prompt="CON_CONTRACT_LAW.DISPOSE_PERIOD"/>
        <bm:field name="machine_site" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="MACHINE_SITE" prompt="CON_CONTRACT_LAW.MACHINE_SITE"/>
        <bm:field name="rental_gather" databaseType="NUMBER" datatype="java.lang.Long" physicalName="RENTAL_GATHER" prompt="CON_CONTRACT_LAW.RENTAL_GATHER"/>
        <bm:field name="overdue_gather" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_GATHER" prompt="CON_CONTRACT_LAW.OVERDUE_GATHER"/>
        <bm:field name="law_fee_gather" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LAW_FEE_GATHER" prompt="CON_CONTRACT_LAW.LAW_FEE_GATHER"/>
        <bm:field name="gather_sum" databaseType="NUMBER" datatype="java.lang.Long" physicalName="GATHER_SUM" prompt="CON_CONTRACT_LAW.GATHER_SUM"/>
        <bm:field name="rental_mitigate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="RENTAL_MITIGATE" prompt="CON_CONTRACT_LAW.RENTAL_MITIGATE"/>
        <bm:field name="overdue_mitigate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_MITIGATE" prompt="CON_CONTRACT_LAW.OVERDUE_MITIGATE"/>
        <bm:field name="law_fee_mitigate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LAW_FEE_MITIGATE" prompt="CON_CONTRACT_LAW.LAW_FEE_MITIGATE"/>
        <bm:field name="mitigate_sum" databaseType="NUMBER" datatype="java.lang.Long" physicalName="MITIGATE_SUM" prompt="CON_CONTRACT_LAW.MITIGATE_SUM"/>
        <bm:field name="legal_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEGAL_NUMBER" prompt="CON_CONTRACT_LAW.LEGAL_NUMBER"/>
        <bm:field name="file_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="FILE_NUMBER" prompt="CON_CONTRACT_LAW.FILE_NUMBER"/>
        <bm:field name="guarantee_situation" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="GUARANTEE_SITUATION" prompt="CON_CONTRACT_LAW.GUARANTEE_SITUATION"/>
        <bm:field name="guarantee_des" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="GUARANTEE_DES" prompt="CON_CONTRACT_LAW.GUARANTEE_DES"/>
        <bm:field name="sell_price" databaseType="NUMBER" datatype="java.lang.Long" physicalName="SELL_PRICE" prompt="CON_CONTRACT_LAW.SELL_PRICE"/>
        <bm:field name="bp_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BP_ID" prompt="CON_CONTRACT_LAW.BP_ID"/>
        <bm:field name="followed_method" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="FOLLOWED_METHOD" prompt="CON_CONTRACT_LAW.FOLLOWED_METHOD"/>
        <bm:field name="FOLLOWED_METHOD_N" expression="(SELECT t.code_value_name FROM sys_code_values_v t WHERE t.code = &apos;LEGAL_PROCESS_TYPE&apos;  AND t.code_enabled_flag = &apos;Y&apos; AND t.code_value = t1.FOLLOWED_METHOD AND t.code_value_enabled_flag = &apos;Y&apos;)"/>
        <bm:field name="legal_way" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LEGAL_WAY" prompt="CON_CONTRACT_LAW.LEGAL_WAY"/>
        <bm:field name="status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="STATUS" prompt="CON_CONTRACT_LAW.STATUS"/>
        <bm:field name="wfl_instance_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="WFL_INSTANCE_ID" prompt="CON_CONTRACT_LAW.WFL_INSTANCE_ID"/>
        <bm:field name="document_category" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_CATEGORY" prompt="CON_CONTRACT_LAW.DOCUMENT_CATEGORY"/>
        <bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" prompt="CON_CONTRACT_LAW.DOCUMENT_TYPE"/>
        <bm:field name="country_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COUNTRY_ID" prompt="CON_CONTRACT_LAW.COUNTRY_ID"/>
        <bm:field name="province_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PROVINCE_ID" prompt="CON_CONTRACT_LAW.PROVINCE_ID"/>
        <bm:field name="city_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CITY_ID" prompt="CON_CONTRACT_LAW.CITY_ID"/>
        <bm:field name="district_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="DISTRICT_ID" prompt="CON_CONTRACT_LAW.DISTRICT_ID"/>
        <bm:field name="located_info" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LOCATED_INFO" prompt="CON_CONTRACT_LAW.LOCATED_INFO"/>
        <bm:field name="repair_info" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REPAIR_INFO" prompt="CON_CONTRACT_LAW.REPAIR_INFO"/>
        <bm:field name="mediation_description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="MEDIATION_DESCRIPTION" prompt="CON_CONTRACT_LAW.MEDIATION_DESCRIPTION"/>
        <bm:field name="repurchase_description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REPURCHASE_DESCRIPTION" prompt="CON_CONTRACT_LAW.REPURCHASE_DESCRIPTION"/>
        <bm:field name="dispose_date" databaseType="DATE" datatype="java.util.Date" physicalName="DISPOSE_DATE" prompt="CON_CONTRACT_LAW.DISPOSE_DATE"/>
        <bm:field name="overdue_amount" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_AMOUNT" prompt="CON_CONTRACT_LAW.OVERDUE_AMOUNT"/>
        <bm:field name="overdue_times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_TIMES" prompt="CON_CONTRACT_LAW.OVERDUE_TIMES"/>
        <bm:field name="payment_method_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PAYMENT_METHOD_ID" prompt="CON_CONTRACT_LAW.PAYMENT_METHOD_ID"/>
        <bm:field name="penalty" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PENALTY" prompt="CON_CONTRACT_LAW.PENALTY"/>
        <bm:field name="promised_repay_date" databaseType="DATE" datatype="java.util.Date" physicalName="PROMISED_REPAY_DATE" prompt="CON_CONTRACT_LAW.PROMISED_REPAY_DATE"/>
        <bm:field name="quantity" databaseType="NUMBER" datatype="java.lang.Long" physicalName="QUANTITY" prompt="CON_CONTRACT_LAW.QUANTITY"/>
        <bm:field name="unpaid_amount" databaseType="NUMBER" datatype="java.lang.Long" physicalName="UNPAID_AMOUNT" prompt="CON_CONTRACT_LAW.UNPAID_AMOUNT"/>
        <bm:field name="unpaid_times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="UNPAID_TIMES" prompt="CON_CONTRACT_LAW.UNPAID_TIMES"/>
        <bm:field name="payment_date" databaseType="DATE" datatype="java.util.Date" physicalName="PAYMENT_DATE" prompt="CON_CONTRACT_LAW.PAYMENT_DATE"/>
        <bm:field name="payment_amount" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PAYMENT_AMOUNT" prompt="CON_CONTRACT_LAW.PAYMENT_AMOUNT"/>
        <bm:field name="feedback" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="FEEDBACK" prompt="CON_CONTRACT_LAW.FEEDBACK"/>
        <bm:field name="feedback_amount" databaseType="NUMBER" datatype="java.lang.Long" physicalName="FEEDBACK_AMOUNT" prompt="CON_CONTRACT_LAW.FEEDBACK_AMOUNT"/>
        <bm:field name="send_date_01" databaseType="DATE" datatype="java.util.Date" physicalName="SEND_DATE_01" prompt="CON_CONTRACT_LAW.SEND_DATE_01"/>
        <bm:field name="send_date_02" databaseType="DATE" datatype="java.util.Date" physicalName="SEND_DATE_02" prompt="CON_CONTRACT_LAW.SEND_DATE_02"/>
        <bm:field name="repurchase_date" databaseType="DATE" datatype="java.util.Date" physicalName="REPURCHASE_DATE" prompt="CON_CONTRACT_LAW.REPURCHASE_DATE"/>
        <bm:field name="terminate_file_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TERMINATE_FILE_NUMBER" prompt="CON_CONTRACT_LAW.TERMINATE_FILE_NUMBER"/>
        <bm:field name="description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DESCRIPTION" prompt="CON_CONTRACT_LAW.DESCRIPTION"/>
        <bm:field name="feedback_amount_chn" expression="(fnd_convert_to_chinese_pkg.amount_convert_to_chinese(round(nvl(t1.feedback_amount, 0),1)))"/>
    </bm:fields>
    <bm:features>
        <f:standard-who/>
    </bm:features>
    <bm:primary-key>
        <bm:pk-field name="law_id"/>
    </bm:primary-key>
    <bm:query-fields>
        <bm:query-field field="contract_id" queryOperator="="/>
        <bm:query-field field="law_id" queryOperator="="/>
    </bm:query-fields>
</bm:model>
