<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: DJ  
    $Date: 2013-11-20 下午2:24:26  
    $Revision: 1.0  
    $Purpose: 
-->
<ns1:model xmlns:ns1="http://www.leaf-framework.org/schema/bm" alias="t1" extend="fnd.FND506.prj_project_approver_group" extendMode="reference">
    <ns1:fields>
        <ns1:field name="approver_user_id"/>
        <ns1:field name="employee_code" forDisplay="true" forQuery="true"/>
        <ns1:field name="employee_name" forDisplay="true" forQuery="true"/>
        <ns1:field name="unit_name" forDisplay="true" forQuery="true"/>
        <ns1:field name="position_name" forDisplay="true" forQuery="true"/>
        <ns1:field name="company_short_name" forDisplay="true" forQuery="true"/>
    </ns1:fields>
    <ns1:query-fields>
        <ns1:query-field name="employee_code" queryExpression="e.employee_code like ${@employee_code}"/>
        <ns1:query-field name="employee_name" queryExpression="e.employee_name like ${@employee_name}"/>
        <ns1:query-field name="unit_name" queryExpression="e.unit_name like ${@unit_name}"/>
        <ns1:query-field name="position_name" queryExpression="e.position_name like ${@position_name}"/>
        <ns1:query-field name="company_short_name" queryExpression="e.company_short_name like ${@company_short_name}"/>
    </ns1:query-fields>
    <ns1:data-filters>
        <ns1:data-filter enforceOperations="query" expression="t1.enabled_flag = &apos;Y&apos; "/>
        <ns1:data-filter enforceOperations="query" expression="exists (select 1 from con_contract_approval tt1,con_contract ct,prj_project tt2,bgfl_project_app_grp_assign tt3 where tt1.approval_id = ${@approval_id} and tt1.contract_id = ct.contract_id and ct.project_id=tt2.project_id   and tt2.project_type = tt3.project_type and tt3.approver_user_id = t1.approver_user_id)"/>
    </ns1:data-filters>
</ns1:model>
