<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: gaoyang  
    $Date: 2013-5-28 下午01:44:42  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
    <bm:operations>
        <bm:operation name="insert">
            <bm:update-sql><![CDATA[
                begin
                    csh_transaction_wfl_pkg.csh_transaction_wfl_insert(
                            p_transaction_wfl_id   => ${@transaction_wfl_id},
                            p_transaction_id       => ${@transaction_id},
                            p_reversed_date        => to_date(${@reversed_date}, 'yyyy-mm-dd'),
                            p_reversed_period_name => ${@reversed_period_name},
                            p_transaction_date     => to_date(${@transaction_date}, 'yyyy-mm-dd'),
                            p_description          => ${@description},
                            p_note                 => ${@note},
                            p_csh_transaction_atm_id => ${@csh_transaction_atm_id},
                            p_user_id              => ${/session/@user_id}
                    );
                end;
                ]]></bm:update-sql>
            <bm:parameters>
                <bm:parameter name="transaction_wfl_id" dataType="java.lang.Long" input="false" output="true" outputPath="/parameter/@transaction_wfl_id"/>
            </bm:parameters>
        </bm:operation>
        <bm:operation name="update">
            <bm:update-sql><![CDATA[
            	begin
                    csh_transaction_wfl_pkg.csh_write_off_wfl_insert(
                            p_transaction_wfl_id   => ${../../@transaction_wfl_id},
                            p_write_off_id         => ${@write_off_id},
                            p_user_id              => ${/session/@user_id}
                    );
            	end;
            ]]></bm:update-sql>
        </bm:operation>
        <bm:operation name="execute">
            <bm:update-sql><![CDATA[
                begin
                    csh_transaction_wfl_pkg.csh_reverse_wfl_start(
                            p_transaction_wfl_id   => ${@transaction_wfl_id},
                            p_user_id              => ${/session/@user_id}
                    );
                end;
            ]]></bm:update-sql>
        </bm:operation>
    </bm:operations>
</bm:model>
