<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: zhangxing5129  
    $Date: 2013-9-2 上午11:01:28  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:o="leaf.database.local.oracle" xmlns:bm="http://www.leaf-framework.org/schema/bm" xmlns:f="leaf.database.features" alias="t1" baseTable="GLD_JOURNAL_DETAILS" defaultOrderBy="account_code">
    <bm:fields>
        <bm:field name="journal_line_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="JOURNAL_LINE_ID" prompt="GLD_JOURNAL_DETAILS.JOURNAL_LINE_ID"/>
        <bm:field name="journal_header_id" databaseType="NUMBER" datatype="java.lang.Long" forQuery="true" forUpdate="false" physicalName="JOURNAL_HEADER_ID" prompt="GLD_JOURNAL_DETAILS.JOURNAL_HEADER_ID"/>
        <bm:field name="line_description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="LINE_DESCRIPTION" prompt="GLD_JOURNAL_DETAILS.LINE_DESCRIPTION"/>
        <bm:field name="responsibility_center_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="RESPONSIBILITY_CENTER_ID" prompt="GLD_JOURNAL_DETAILS.RESPONSIBILITY_CENTER_ID"/>
        <bm:field name="responsibility_center_name" databaseType="VARCHAR2" datatype="java.lang.String" expression="(select responsibility_center_name from fnd_responsibility_centers_vl     where responsibility_center_id=t1.responsibility_center_id)" prompt="GLD_JOURNAL_DETAILS.RESPONSIBILITY_CENTER_ID"/>
        <bm:field name="account_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="ACCOUNT_ID" prompt="GLD_JOURNAL_DETAILS.ACCOUNT_ID"/>
        <bm:field name="exchange_rate_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE" prompt="GLD_JOURNAL_DETAILS.EXCHANGE_RATE_TYPE"/>
        <bm:field name="exchange_rate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXCHANGE_RATE" prompt="GLD_JOURNAL_DETAILS.EXCHANGE_RATE"/>
        <bm:field name="amount_dr" databaseType="NUMBER" datatype="java.lang.Double" physicalName="AMOUNT_DR" prompt="GLD_JOURNAL_DETAILS.AMOUNT_DR"/>
        <bm:field name="amount_cr" databaseType="NUMBER" datatype="java.lang.Double" physicalName="AMOUNT_CR" prompt="GLD_JOURNAL_DETAILS.AMOUNT_CR"/>
        <bm:field name="amount_fuc_dr" databaseType="NUMBER" datatype="java.lang.Double" physicalName="AMOUNT_FUC_DR" prompt="GLD_JOURNAL_DETAILS.AMOUNT_FUC_DR"/>
        <bm:field name="amount_fuc_cr" databaseType="NUMBER" datatype="java.lang.Double" physicalName="AMOUNT_FUC_CR" prompt="GLD_JOURNAL_DETAILS.AMOUNT_FUC_CR"/>
        <bm:field name="reference1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REFERENCE1" prompt="GLD_JOURNAL_DETAILS.REFERENCE1"/>
        <bm:field name="reference2" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REFERENCE2" prompt="GLD_JOURNAL_DETAILS.REFERENCE2"/>
        <bm:field name="reference3" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REFERENCE3" prompt="GLD_JOURNAL_DETAILS.REFERENCE3"/>
        <bm:field name="reference4" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="REFERENCE4" prompt="GLD_JOURNAL_DETAILS.REFERENCE4"/>
        <bm:field name="line_quantity" databaseType="NUMBER" datatype="java.lang.Long" physicalName="LINE_QUANTITY" prompt="GLD_JOURNAL_DETAILS.LINE_QUANTITY"/>
        <bm:field name="account_code" databaseType="VARCHAR2" datatype="java.lang.String" expression="(select account_code from GLD_COMPANY_ACCOUNTS_VL    where account_id=t1.account_id)" prompt="GLD_JOURNAL_DETAILS.ACCOUNT_ID"/>
        <bm:field name="account_description" databaseType="VARCHAR2" datatype="java.lang.String" expression="(select description from GLD_COMPANY_ACCOUNTS_VL    where account_id=t1.account_id)" physicalName="DESCRIPTION" prompt="GLD_ACCOUNTS.ACCOUNT_DESCRIPTION"/>
    </bm:fields>
    <bm:features>
        <f:standard-who/>
        <o:sequence-pk/>
    </bm:features>
    <bm:primary-key>
        <bm:pk-field name="journal_line_id"/>
    </bm:primary-key>
    <bm:query-fields>
        <bm:query-field field="journal_header_id" queryOperator="="/>
    </bm:query-fields>
</bm:model>
