<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: zhangxing5129  
    $Date: 2013-12-17 下午05:32:12  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
    <bm:operations>
        <bm:operation name="query">
            <bm:query-sql><![CDATA[
            select t1.value_code,t1.value_name
                 from (select e.employee_id as value_code, e.name as value_name
					  from exp_org_unit u, exp_employee_assigns a, exp_employees e
					 where u.unit_id in(7,8,9)
					   and u.chief_position_id = a.position_id
					   and u.company_id = a.company_id
					   and a.employee_id = e.employee_id
					   and a.enabled_flag = 'Y'
					   and e.enabled_flag = 'Y'
					   and u.company_id = ${/session/@company_id})t1
					   #WHERE_CLAUSE#
					   
   ]]></bm:query-sql>
        </bm:operation>
    </bm:operations>
    <bm:fields>
        <bm:field name="value_code"/>
        <bm:field name="value_name" forDisplay="true" forQuery="true" prompt="HLS.DESCRIPTION"/>
    </bm:fields>
    <bm:query-fields>
        <bm:query-field field="value_name" queryOperator="like"/>
    </bm:query-fields>
</bm:model>
