From: erickson Date: Fri, 12 Mar 2010 05:03:00 +0000 (+0000) Subject: added limit/offset options to response stream of fiscall rollover processor X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=309eb62c14c9c1865c4a3857a33c9833e0bb2aa7;p=evergreen%2Fbjwebb.git added limit/offset options to response stream of fiscall rollover processor git-svn-id: svn://svn.open-ils.org/ILS/trunk@15817 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm index 064845424..f0fefb3a8 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Financials.pm @@ -1227,11 +1227,12 @@ __PACKAGE__->register_method ( sub process_fiscal_rollover { - my( $self, $conn, $auth, $year, $org_id, $descendants ) = @_; + my( $self, $conn, $auth, $year, $org_id, $descendants, $options ) = @_; my $e = new_editor(xact=>1, authtoken=>$auth); return $e->die_event unless $e->checkauth; return $e->die_event unless $e->allowed('ADMIN_FUND', $org_id); + $options ||= {}; my $combined = ($self->api_name =~ /combined/); @@ -1271,12 +1272,16 @@ sub process_fiscal_rollover { } # Fetch all funds for the specified org units for the subsequent year - my $fund_ids = $e->search_acq_fund( + my $fund_ids = $e->search_acq_fund([ { year => int($year) + 1, org => $org_ids, propagate => 't' - }, + }, { + limit => $$optoins{limit} || 20, + offset => $$optoins{offset} || 0, + } + ], {idlist => 1} );