From 4b0b351f939a33ca1afd25f5171a06195a0c400c Mon Sep 17 00:00:00 2001 From: Galen Charlton Date: Mon, 13 Dec 2021 20:36:16 -0500 Subject: [PATCH] LP#1942220: add flesh_po_items_further option to PO retrieval This fleshes in any fund debits and debit invoice items associated with PO direct charges Signed-off-by: Galen Charlton --- Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Financials.pm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Financials.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Financials.pm index bc273386c6..f5680f2ccb 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Financials.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Financials.pm @@ -1026,6 +1026,11 @@ sub retrieve_purchase_order_impl { } push (@{$flesh->{flesh_fields}->{acqpo}}, 'po_items') if $options->{flesh_po_items}; + if ($options->{flesh_po_items_further}) { + push (@{$flesh->{flesh_fields}->{acqpoi}}, 'fund_debit'); + push (@{$flesh->{flesh_fields}->{acqfdeb}}, 'invoice_items'); + $flesh->{'flesh'} = 3; + } my $args = (@{$flesh->{"flesh_fields"}->{"acqpo"}}) ? [$po_id, $flesh] : $po_id; -- 2.11.0