[open-ils-commits] [GIT] Evergreen ILS branch rel_2_10 updated. 403becfc04b6a130db5d4ed12bfc234303753668

Evergreen Git git at git.evergreen-ils.org
Tue Mar 14 16:34:00 EDT 2017


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, rel_2_10 has been updated
       via  403becfc04b6a130db5d4ed12bfc234303753668 (commit)
      from  0c9754c15a5fafbad6818f84a58b6565e51cde72 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 403becfc04b6a130db5d4ed12bfc234303753668
Author: Remington Steed <rjs7 at calvin.edu>
Date:   Thu Sep 29 14:55:41 2016 -0400

    LP#1586567 Always return Fund Years sorted descending
    
    Currently, fund year selectors in Acq interfaces (at least Acq Admin ->
    Funds, and Acq -> Load MARC Order Records) show the fund years in
    database order. This commit adds a descending sort to the perl function
    that retrieves fund years for those interfaces. It also removes the
    unsuccessful attempt at sorting that was present in the dojo code.
    
    Signed-off-by: Remington Steed <rjs7 at calvin.edu>
    Signed-off-by: Dawn Dale <ddale at georgialibraries.org>
    Signed-off-by: Kathy Lussier <klussier at masslnc.org>

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 28b4f51..e66e648 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Financials.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Financials.pm
@@ -327,8 +327,11 @@ sub retrieve_org_funds {
                 acqf => [{column => 'year', transform => 'distinct'}]
             }, 
             from => 'acqf', 
-            where => $filter}
-        );
+            where => $filter,
+            order_by => {
+                acqf => {"year" => {"direction" => "desc"}}
+            }
+        });
 
         return [map { $_->{year} } @$data];
     }
diff --git a/Open-ILS/web/js/ui/default/acq/financial/list_funds.js b/Open-ILS/web/js/ui/default/acq/financial/list_funds.js
index 69ec8b4..0d2f7de 100644
--- a/Open-ILS/web/js/ui/default/acq/financial/list_funds.js
+++ b/Open-ILS/web/js/ui/default/acq/financial/list_funds.js
@@ -169,7 +169,6 @@ function loadYearSelector() {
                 yearList = yearList.map(function(year){return {year:year+''};}); // dojo wants strings
 
                 var yearStore = {identifier:'year', name:'year', items:yearList};
-                yearStore.items = yearStore.items.sort().reverse();
                 fundFilterYearSelect.store = new dojo.data.ItemFileWriteStore({data:yearStore});
 
                 // default to this year
diff --git a/Open-ILS/web/js/ui/default/acq/picklist/upload.js b/Open-ILS/web/js/ui/default/acq/picklist/upload.js
index df11b0f..ac2b6b9 100644
--- a/Open-ILS/web/js/ui/default/acq/picklist/upload.js
+++ b/Open-ILS/web/js/ui/default/acq/picklist/upload.js
@@ -220,7 +220,6 @@ function loadYearSelector() {
                 yearList = yearList.map(function(year){return {year:year+''};}); // dojo wants strings
 
                 var yearStore = {identifier:'year', name:'year', items:yearList};
-                yearStore.items = yearStore.items.sort().reverse();
                 acqUploadYearSelector.store = new dojo.data.ItemFileReadStore({data:yearStore});
 
                 // until an ordering agency is selected, default to the 

-----------------------------------------------------------------------

Summary of changes:
 .../lib/OpenILS/Application/Acq/Financials.pm      |    7 +++++--
 .../web/js/ui/default/acq/financial/list_funds.js  |    1 -
 Open-ILS/web/js/ui/default/acq/picklist/upload.js  |    1 -
 3 files changed, 5 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list