<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: hp  
    $Date: 2013-12-2 下午05:04:52  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" xmlns:f="leaf.database.features" alias="t1" baseTable="HLS_BP_LEGAL_INFO_REQ">
    <bm:fields>
        <bm:field name="legal_info_req_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LEGAL_INFO_REQ_ID" prompt="HLS_BP_LEGAL_INFO_REQ.LEGAL_INFO_REQ_ID"/>
        <bm:field name="bp_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BP_ID" prompt="HLS_BP_LEGAL_INFO_REQ.BP_ID"/>
        <bm:field name="bp_class" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_CLASS" prompt="HLS_BP_LEGAL_INFO_REQ.BP_CLASS"/>
        <bm:field name="employee_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EMPLOYEE_ID" prompt="HLS_BP_LEGAL_INFO_REQ.EMPLOYEE_ID"/>
        <bm:field name="owner_user_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OWNER_USER_ID" prompt="HLS_BP_LEGAL_INFO_REQ.OWNER_USER_ID"/>
        <bm:field name="document_category" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_CATEGORY" prompt="HLS_BP_LEGAL_INFO_REQ.DOCUMENT_CATEGORY"/>
        <bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" prompt="HLS_BP_LEGAL_INFO_REQ.DOCUMENT_TYPE"/>
        <bm:field name="wfl_instance_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="WFL_INSTANCE_ID" prompt="HLS_BP_LEGAL_INFO_REQ.WFL_INSTANCE_ID"/>
        <bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" prompt="HLS_BP_LEGAL_INFO_REQ.COMPANY_ID"/>
        <bm:field name="req_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REQ_STATUS" prompt="HLS_BP_LEGAL_INFO_REQ.REQ_STATUS"/>
        <bm:field name="req_date" databaseType="DATE" datatype="java.util.Date" physicalName="REQ_DATE" prompt="HLS_BP_LEGAL_INFO_REQ.REQ_DATE"/>
        <bm:field name="submit_date" databaseType="DATE" datatype="java.util.Date" physicalName="SUBMIT_DATE" prompt="HLS_BP_LEGAL_INFO_REQ.SUBMIT_DATE"/>
        <bm:field name="pste_query_date" databaseType="DATE" datatype="java.util.Date" physicalName="PSTE_QUERY_DATE" prompt="HLS_BP_LEGAL_INFO_REQ.PSTE_QUERY_DATE"/>
        <bm:field name="fl_reg_query_date" databaseType="DATE" datatype="java.util.Date" physicalName="FL_REG_QUERY_DATE" prompt="HLS_BP_LEGAL_INFO_REQ.FL_REG_QUERY_DATE"/>
        <bm:field name="ac_pledge_query_date" databaseType="DATE" datatype="java.util.Date" physicalName="AC_PLEDGE_QUERY_DATE" prompt="HLS_BP_LEGAL_INFO_REQ.AC_PLEDGE_QUERY_DATE"/>
        <bm:field name="confirm_date" databaseType="DATE" datatype="java.util.Date" physicalName="CONFIRM_DATE" prompt="HLS_BP_LEGAL_INFO_REQ.CONFIRM_DATE"/>
        <bm:field name="pste_note" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PSTE_NOTE" prompt="HLS_BP_LEGAL_INFO_REQ.PSTE_NOTE"/>
        <bm:field name="fl_reg_note" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="FL_REG_NOTE" prompt="HLS_BP_LEGAL_INFO_REQ.FL_REG_NOTE"/>
        <bm:field name="ac_pledge_note" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="AC_PLEDGE_NOTE" prompt="HLS_BP_LEGAL_INFO_REQ.AC_PLEDGE_NOTE"/>
        <bm:field name="ref_v01" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REF_V01" prompt="HLS_BP_LEGAL_INFO_REQ.REF_V01"/>
        <bm:field name="ref_v02" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REF_V02" prompt="HLS_BP_LEGAL_INFO_REQ.REF_V02"/>
        <bm:field name="ref_v03" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REF_V03" prompt="HLS_BP_LEGAL_INFO_REQ.REF_V03"/>
        <bm:field name="ref_v04" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REF_V04" prompt="HLS_BP_LEGAL_INFO_REQ.REF_V04"/>
        <bm:field name="ref_v05" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REF_V05" prompt="HLS_BP_LEGAL_INFO_REQ.REF_V05"/>
        <bm:field name="ref_n01" databaseType="NUMBER" datatype="java.lang.Long" physicalName="REF_N01" prompt="HLS_BP_LEGAL_INFO_REQ.REF_N01"/>
        <bm:field name="ref_n02" databaseType="NUMBER" datatype="java.lang.Long" physicalName="REF_N02" prompt="HLS_BP_LEGAL_INFO_REQ.REF_N02"/>
        <bm:field name="ref_n03" databaseType="NUMBER" datatype="java.lang.Long" physicalName="REF_N03" prompt="HLS_BP_LEGAL_INFO_REQ.REF_N03"/>
        <bm:field name="ref_n04" databaseType="NUMBER" datatype="java.lang.Long" physicalName="REF_N04" prompt="HLS_BP_LEGAL_INFO_REQ.REF_N04"/>
        <bm:field name="ref_n05" databaseType="NUMBER" datatype="java.lang.Long" physicalName="REF_N05" prompt="HLS_BP_LEGAL_INFO_REQ.REF_N05"/>
        <bm:field name="ref_d01" databaseType="DATE" datatype="java.util.Date" physicalName="REF_D01" prompt="HLS_BP_LEGAL_INFO_REQ.REF_D01"/>
        <bm:field name="ref_d02" databaseType="DATE" datatype="java.util.Date" physicalName="REF_D02" prompt="HLS_BP_LEGAL_INFO_REQ.REF_D02"/>
        <bm:field name="ref_d03" databaseType="DATE" datatype="java.util.Date" physicalName="REF_D03" prompt="HLS_BP_LEGAL_INFO_REQ.REF_D03"/>
        <bm:field name="ref_d04" databaseType="DATE" datatype="java.util.Date" physicalName="REF_D04" prompt="HLS_BP_LEGAL_INFO_REQ.REF_D04"/>
        <bm:field name="ref_d05" databaseType="DATE" datatype="java.util.Date" physicalName="REF_D05" prompt="HLS_BP_LEGAL_INFO_REQ.REF_D05"/>
        <bm:field name="bp_code" expression="(select m.bp_code from hls_bp_master_all_data_v m where m.bp_id=t1.bp_id)" forInsert="false" forUpdate="false"/>
        <bm:field name="bp_name" expression="(select m.bp_name from hls_bp_master_all_data_v m where m.bp_id=t1.bp_id)" forInsert="false" forUpdate="false"/>
        <bm:field name="bp_class_desc" expression="(select m.bp_class_desc from hls_bp_master_all_data_v m where m.bp_id=t1.bp_id)" forInsert="false" forUpdate="false"/>
        <bm:field name="loan_card_num" expression="(select m.loan_card_num from hls_bp_master_all_data_v m where m.bp_id=t1.bp_id)" forInsert="false" forUpdate="false"/>
        <bm:field name="id_card_no" expression="(select decode(m.id_type,&apos;ID_CARD&apos;,m.id_card_no,&apos;&apos;) from hls_bp_master_all_data_v m where m.bp_id=t1.bp_id)" forInsert="false" forUpdate="false"/>
        <bm:field name="loan_card_num_pwd" expression="(select m.ref_v01 from hls_bp_master_all_data_v m where m.bp_id=t1.bp_id)" forInsert="false" forUpdate="false"/>
        <bm:field name="organization_code" expression="(select m.organization_code from hls_bp_master_all_data_v m where m.bp_id=t1.bp_id)" forInsert="false" forUpdate="false"/>
    </bm:fields>
    <bm:features>
        <f:standard-who/>
    </bm:features>
    <bm:primary-key>
        <bm:pk-field name="legal_info_req_id"/>
    </bm:primary-key>
    <bm:data-filters>
        <bm:data-filter enforceOperations="query" expression="t1.legal_info_req_id=${@legal_info_req_id}"/>
    </bm:data-filters>
</bm:model>
