<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: gaoyang  
    $Date: 2013-4-23 下午03:22:21  
    $Revision: 1.0  
    $Purpose: 
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
    <bm:operations>
        <bm:operation name="update">
            <bm:update-sql><![CDATA[
            	begin
            		  hls_fin_calculator_save_pkg.update_calc_hd_formula(
            		              p_calc_session_id=>${@calc_session_id},
					              p_company_id=>${/session/@company_id},
					              p_price_list=>${@price_list},
					              p_calc_method=>${@calc_method},
					              p_calc_successful=>${@calc_successful},
					              p_calc_prompt=>${@calc_prompt},
					              p_calc_prompt_msg=>${@calc_prompt_msg},
					              p_business_type=>${@business_type},
					              p_inception_of_lease=>${@inception_of_lease},
					              p_lease_start_date=>${@lease_start_date},
					              p_lease_end_date=>${@lease_end_date},
					              p_lease_times=>${@lease_times},
					              p_pay_type=>${@pay_type},
					              p_annual_pay_times=>${@annual_pay_times},
					              p_lease_term=>${@lease_term},
					              p_biz_day_convention=>${@biz_day_convention},
					              p_rounding_method=>${@rounding_method},
					              p_currency=>${@currency},
					              p_currency_precision=>${@currency_precision},
					              p_int_rate_precision=>${@int_rate_precision},
					              p_tax_type_id=>${@tax_type_id},
					              p_vat_flag=>${@vat_flag},
					              p_vat_rate=>${@vat_rate},
					              p_billing_method=>${@billing_method},
					              p_base_rate_type=>${@base_rate_type},
					              p_base_rate=>${@base_rate},
					              p_int_rate_fixing_way=>${@int_rate_fixing_way},
					              p_int_rate_fixing_range=>${@int_rate_fixing_range},
					              p_int_rate_display=>${@int_rate_display},
					              p_int_rate=>${@int_rate},
					              p_int_rate_implicit=>${@int_rate_implicit},
					              p_int_rate_type=>${@int_rate_type},
					              p_flt_rate_adj_method=>${@flt_rate_adj_method},
					              p_flt_simulate_step=>${@flt_simulate_step},
					              p_flt_simulate_range=>${@flt_simulate_range},
					              p_flt_unit_adj_amt=>${@flt_unit_adj_amt},
					              p_flt_execute_times_rule=>${@flt_execute_times_rule},
					              p_flt_rate_profile=>${@flt_rate_profile},
					              p_flt_annual_adj_times=>${@flt_annual_adj_times},
					              p_flt_delay_execute_period=>${@flt_delay_execute_period},
					              p_flt_next_adj_date=>${@flt_next_adj_date},
					              p_irr=>${@irr},
					              p_irr_after_tax=>${@irr_after_tax},
					              p_int_rate_implicit_after_tax=>${@int_rate_implicit_after_tax},
					              p_irr_reserved1=>${@irr_reserved1},
					              p_irr_reserved2=>${@irr_reserved2},
					              p_irr_reserved3=>${@irr_reserved3},
					              p_lease_item_amount=>${@lease_item_amount},
					              p_lease_item_cost=>${@lease_item_cost},
					              p_net_lease_item_amount=>${@net_lease_item_amount},
					              p_vat_input=>${@vat_input},
					              p_down_payment_ratio=>${@down_payment_ratio},
					              p_down_payment=>${@down_payment},
					              p_net_down_payment=>${@net_down_payment},
					              p_vat_down_payment=>${@vat_down_payment},
					              p_finance_amount=>${@finance_amount},
					              p_net_finance_amount=>${@net_finance_amount},
					              p_vat_finance_amount=>${@vat_finance_amount},
					              p_actual_finance_amount=>${@actual_finance_amount},
					              p_contract_amount=>${@contract_amount},
					              p_total_rental=>${@total_rental},
					              p_net_total_rental=>${@net_total_rental},
					              p_vat_total_rental=>${@vat_total_rental},
					              p_total_interest=>${@total_interest},
					              p_net_total_interest=>${@net_total_interest},
					              p_vat_total_interest=>${@vat_total_interest},
					              p_total_fee=>${@total_fee},
					              p_net_total_fee=>${@net_total_fee},
					              p_vat_total_fee=>${@vat_total_fee},
					              p_finance_income=>${@finance_income},
					              p_net_finance_income=>${@net_finance_income},
					              p_vat_finance_income=>${@vat_finance_income},
					              p_lease_charge_ratio=>${@lease_charge_ratio},
					              p_lease_charge=>${@lease_charge},
					              p_net_lease_charge=>${@net_lease_charge},
					              p_vat_lease_charge=>${@vat_lease_charge},
					              p_lease_mgt_fee_ratio=>${@lease_mgt_fee_ratio},
					              p_lease_mgt_fee=>${@lease_mgt_fee},
					              p_net_lease_mgt_fee=>${@net_lease_mgt_fee},
					              p_vat_lease_mgt_fee=>${@vat_lease_mgt_fee},
					              p_lease_mgt_fee_rule=>${@lease_mgt_fee_rule},
					              p_residual_ratio=>${@residual_ratio},
					              p_residual_value=>${@residual_value},
					              p_net_residual_value=>${@net_residual_value},
					              p_vat_residual_value=>${@vat_residual_value},
					              p_deposit_ratio=>${@deposit_ratio},
					              p_deposit=>${@deposit},
					              p_deposit_deduction=>${@deposit_deduction},
					              p_balloon_ratio=>${@balloon_ratio},
					              p_balloon=>${@balloon},
					              p_net_balloon=>${@net_balloon},
					              p_vat_balloon=>${@vat_balloon},
					              p_interim_rent_period=>${@interim_rent_period},
					              p_interim_times=>${@interim_times},
					              p_interim_rental=>${@interim_rental},
					              p_net_interim_rental=>${@net_interim_rental},
					              p_vat_interim_rental=>${@vat_interim_rental},
					              p_calc_with_residual_value=>${@calc_with_residual_value},
					              p_pmt=>${@pmt},
					              p_pmt_first=>${@pmt_first},
					              p_annual_mean_rate=>${@annual_mean_rate},
					              p_npv_using_cof=>${@npv_using_cof},
					              p_rounding_object=>${@rounding_object},
					              p_exchange_rate_type=>${@exchange_rate_type},
					              p_exchange_rate_quotation=>${@exchange_rate_quotation},
					              p_exchange_rate=>${@exchange_rate},
					              p_insurance_rate=>${@insurance_rate},
					              p_insurance_fee=>${@insurance_fee},
					              p_net_insurance_fee=>${@net_insurance_fee},
					              p_vat_insurance_fee=>${@vat_insurance_fee},
					              p_insurance_fee_payable=>${@insurance_fee_payable},
					              p_notarial_fee=>${@notarial_fee},
					              p_net_notarial_fee=>${@net_notarial_fee},
					              p_vat_notarial_fee=>${@vat_notarial_fee},
					              p_notarial_fee_payable=>${@notarial_fee_payable},
					              p_commission_receivable=>${@commission_receivable},
					              p_net_commission_receivable=>${@net_commission_receivable},
					              p_vat_commission_receivable=>${@vat_commission_receivable},
					              p_commission_payable=>${@commission_payable},
					              p_third_party_deposit=>${@third_party_deposit},
					              p_promise_to_pay=>${@promise_to_pay},
					              p_other_fee=>${@other_fee},
					              p_net_other_fee=>${@net_other_fee},
					              p_vat_other_fee=>${@vat_other_fee},
					              p_other_fee2=>${@other_fee2},
					              p_net_other_fee2=>${@net_other_fee2},
					              p_vat_other_fee2=>${@vat_other_fee2},
					              p_other_fee3=>${@other_fee3},
					              p_net_other_fee3=>${@net_other_fee3},
					              p_vat_other_fee3=>${@vat_other_fee3},
					              p_other_payment=>${@other_payment},
					              p_other_payment2=>${@other_payment2},
					              p_other_payment3=>${@other_payment3},
					              p_credit_write_off_order=>${@credit_write_off_order},
					              p_fin_income_recognize_method=>${@fin_income_recognize_method},
					              p_penalty_profile=>${@penalty_profile},
					              p_early_termination_profile=>${@early_termination_profile},
					              p_reschedule_profile=>${@reschedule_profile},
					              p_contract_split_profile=>${@contract_split_profile},
					              p_repur_profile=>${@repur_profile},
					              p_pay_times=>${@pay_times},
					              p_first_pay_date=>${@first_pay_date},
					              p_last_pay_date=>${@last_pay_date},
					              p_machinery_amount=>${@machinery_amount},
					              p_parts_amount=>${@parts_amount},
					              p_lease_item_price_agent=>${@lease_item_price_agent},
					              p_main_business_income=>${@main_business_income},
					              p_main_business_cost=>${@main_business_cost},
					              p_financing_cost=>${@financing_cost},
					              p_total_salestax=>${@total_salestax},
					              p_btb_payment_date=>${@btb_payment_date},
					              p_btb_int_rate=>${@btb_int_rate},
					              p_btb_int_rate_implicit=>${@btb_int_rate_implicit},
					              p_btb_finance_amount=>${@btb_finance_amount},
					              p_btb_net_finance_amount=>${@btb_net_finance_amount},
					              p_btb_total_repayment=>${@btb_total_repayment},
					              p_btb_total_interest=>${@btb_total_interest},
					              p_btb_total_fee_pv=>${@btb_total_fee_pv},
					              p_btb_total_fee=>${@btb_total_fee},
					              p_btb_finance_ratio=>${@btb_finance_ratio},
					              p_btb_interest_margin=>${@btb_interest_margin},
					              p_btb_vat_interest=>${@btb_vat_interest},
					              p_btb_vat_fee=>${@btb_vat_fee},
					              p_btb_interest_after_tax=>${@btb_interest_after_tax},
					              p_btb_fee_after_tax=>${@btb_fee_after_tax},
					              p_vat_rate_of_interest=>${@vat_rate_of_interest},
                                  p_vat_rate_of_fee=>${@vat_rate_of_fee},
                                  p_vat_rate_reserved1=>${@vat_rate_reserved1},
					              p_hd_user_col_d01=>${@hd_user_col_d01},
					              p_hd_user_col_d02=>${@hd_user_col_d02},
					              p_hd_user_col_d03=>${@hd_user_col_d03},
					              p_hd_user_col_d04=>${@hd_user_col_d04},
					              p_hd_user_col_d05=>${@hd_user_col_d05},
					              p_hd_user_col_v01=>${@hd_user_col_v01},
					              p_hd_user_col_v02=>${@hd_user_col_v02},
					              p_hd_user_col_v03=>${@hd_user_col_v03},
					              p_hd_user_col_v04=>${@hd_user_col_v04},
					              p_hd_user_col_v05=>${@hd_user_col_v05},
					              p_hd_user_col_v06=>${@hd_user_col_v06},
					              p_hd_user_col_v07=>${@hd_user_col_v07},
					              p_hd_user_col_v08=>${@hd_user_col_v08},
					              p_hd_user_col_v09=>${@hd_user_col_v09},
					              p_hd_user_col_v10=>${@hd_user_col_v10},
					              p_hd_user_col_n01=>${@hd_user_col_n01},
					              p_hd_user_col_n02=>${@hd_user_col_n02},
					              p_hd_user_col_n03=>${@hd_user_col_n03},
					              p_hd_user_col_n04=>${@hd_user_col_n04},
					              p_hd_user_col_n05=>${@hd_user_col_n05},
					              p_hd_user_col_n06=>${@hd_user_col_n06},
					              p_hd_user_col_n07=>${@hd_user_col_n07},
					              p_hd_user_col_n08=>${@hd_user_col_n08},
					              p_hd_user_col_n09=>${@hd_user_col_n09},
					              p_hd_user_col_n10=>${@hd_user_col_n10},
					              p_hd_user_col_n11=>${@hd_user_col_n11},
					              p_hd_user_col_n12=>${@hd_user_col_n12},
					              p_hd_user_col_n13=>${@hd_user_col_n13},
					              p_hd_user_col_n14=>${@hd_user_col_n14},
					              p_hd_user_col_n15=>${@hd_user_col_n15},
					              p_user_id=>${/session/@user_id});
    			end;
            ]]></bm:update-sql>
        </bm:operation>
    </bm:operations>
</bm:model>
