Cache propagated funds in fund rollover action
authorBill Erickson <berick@esilibrary.com>
Mon, 11 Jun 2012 19:23:17 +0000 (15:23 -0400)
committerBill Erickson <berick@esilibrary.com>
Fri, 13 Jul 2012 13:58:41 +0000 (09:58 -0400)
Repair display of propagated funds grid which was likely broken with
b9bb6d47.  Propagated funds must be collected and added to the local
cache for grid getter functions to find them.

https://bugs.launchpad.net/evergreen/+bug/1011789

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 5b212c6..17873d0 100644 (file)
@@ -207,6 +207,10 @@ function performRollover(args) {
                     }
                 )
 
+                // add the new, rolled funds to the cache.  Note that in dry-run 
+                // mode, these are ephemeral and no longer exist on the server.
+                cachedFunds = cachedFunds.concat(rolloverResponses);
+
                 dojo.byId('acq-fund-list-rollover-summary-header').innerHTML = 
                     dojo.string.substitute(
                         localeStrings.FUND_LIST_ROLLOVER_SUMMARY,