<?xml version="1.0" encoding="UTF-8"?>
<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="CFL_WF_APPROVER_RELATION" defaultOrderBy="t1.approver_seq" >
    <bm:fields>
        <bm:field name="approver_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="APPROVER_ID" prompt="CFL_WF_APPROVER_RELATION.APPROVER_ID"/>
        <bm:field name="approver_group_id" databaseType="NUMBER" datatype="java.lang.Long" insertExpression="${../../@approver_group_id}" physicalName="APPROVER_GROUP_ID" prompt="CFL_WF_APPROVER_RELATION.APPROVER_GROUP_ID"/>
        <bm:field name="approver_employee_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="APPROVER_EMPLOYEE_ID" prompt="CFL_WF_APPROVER_RELATION.APPROVER_EMPLOYEE_ID"/>
        <bm:field name="approver_seq" databaseType="NUMBER" datatype="java.lang.Long" physicalName="APPROVER_SEQ" prompt="CFL_WF_APPROVER_RELATION.APPROVER_SEQ"/>
        <bm:field name="approver_count" databaseType="NUMBER" datatype="java.lang.Long" physicalName="APPROVER_COUNT" prompt="CFL_WF_APPROVER_RELATION.APPROVER_COUNT"/>
        <bm:field name="review_employee_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="REVIEW_EMPLOYEE_ID" prompt="CFL_WF_APPROVER_RELATION.REVIEW_EMPLOYEE_ID"/>
        <bm:field name="manager_employee_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="MANAGER_EMPLOYEE_ID" prompt="CFL_WF_APPROVER_RELATION.MANAGER_EMPLOYEE_ID"/>
        <bm:field name="enabled_flag" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="ENABLED_FLAG" prompt="CFL_WF_APPROVER_RELATION.ENABLED_FLAG"/>
        <bm:field name="approver_employee" expression="(SELECT v.name FROM zj_wfl_employee_vl v WHERE v.employee_id = t1.approver_employee_id )" forInsert="false" forUpdate="false"/>
        <bm:field name="review_employee" expression="(SELECT v.name FROM zj_wfl_employee_vl v WHERE v.employee_id = t1.review_employee_id )" forInsert="false" forUpdate="false"/>
        <bm:field name="manager_employee" expression="(SELECT v.name FROM zj_wfl_employee_vl v WHERE v.employee_id = t1.manager_employee_id)" forInsert="false" forUpdate="false"/>
    </bm:fields>
    <bm:features>
        <f:standard-who/>
        <o:sequence-pk/>
    </bm:features>
    <bm:primary-key>
        <bm:pk-field name="approver_id"/>
    </bm:primary-key>
    <bm:query-fields>
        <bm:query-field field="approver_group_id" queryOperator="="/>
    </bm:query-fields>
</bm:model>
