From 7f5c8595fe77ddc651b0ac3630cbb886e380a93b Mon Sep 17 00:00:00 2001 From: erickson Date: Thu, 24 Jul 2008 14:18:01 +0000 Subject: [PATCH] fixed typo in object name. pointing li_detail at the newly creatd fund_debit object git-svn-id: svn://svn.open-ils.org/ILS/branches/acq-experiment@10108 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm index 6b5b2b0113..8f955a55be 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm @@ -644,7 +644,7 @@ sub create_purchase_order_debits { flesh => 1, flesh_fields => {acqlid => ['fund']}}])->[0]) { - my $debit = Fieldmapper::acq::fund_debut->new; + my $debit = Fieldmapper::acq::fund_debit->new; $debit->fund($lid->fund->id); $debit->origin_amount($price); if($ptype == 2) { # price from vendor @@ -655,9 +655,14 @@ sub create_purchase_order_debits { $debit->origin_currency_type($lid->fund->currency_type); $debit->amount($price); } + $debit->encumbrance($args->{encumbrance}); $debit->debit_type('purchase'); $e->create_acq_fund_debit($debit) or return $e->die_event; + + # point the lineitem detail at the fund debit object + $lid->fund_debit($debit->id); + $e->update_acq_lineitem_detail($lid) or return $e->die_event; $total += $debit->amount; } } -- 2.11.0