LP#1325720 Repair fund rollover year selector query
authorBill Erickson <berick@esilibrary.com>
Mon, 2 Jun 2014 20:14:38 +0000 (16:14 -0400)
committerBen Shum <bshum@biblio.org>
Thu, 18 Sep 2014 20:32:10 +0000 (16:32 -0400)
Dojo dojo stores track values as strings, so values used in data store
queries must be coerced into strings before performing the query.

This fixes the year query in the fund rollover UI so that the page is
able to render the results of a rollover without dying from an JS error
before completing.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
Open-ILS/web/js/ui/default/acq/financial/list_funds.js

index fbf1a74..09a47d5 100644 (file)
@@ -253,7 +253,7 @@ function performRollover(args) {
                     
                     // add the new year to the year selector if it's not already there
                     fundFilterYearSelect.store.fetch({
-                        query : {year : nextYear}, 
+                        query : {year : ''+nextYear}, 
                         onComplete:
                             function(list) {
                                 if(list && list.length > 0) return;