[open-ils-commits] r16815 - in trunk/Open-ILS: web/js/ui/default/acq/common web/js/ui/default/acq/financial web/templates/default/acq/financial xul/staff_client/chrome/locale/en-US (senator)
svn at svn.open-ils.org
svn at svn.open-ils.org
Fri Jun 25 12:00:39 EDT 2010
Author: senator
Date: 2010-06-25 12:00:36 -0400 (Fri, 25 Jun 2010)
New Revision: 16815
Modified:
trunk/Open-ILS/web/js/ui/default/acq/common/tag_manager.js
trunk/Open-ILS/web/js/ui/default/acq/financial/view_fund.js
trunk/Open-ILS/web/js/ui/default/acq/financial/view_funding_source.js
trunk/Open-ILS/web/templates/default/acq/financial/view_funding_source.tt2
trunk/Open-ILS/xul/staff_client/chrome/locale/en-US/offline.properties
Log:
Acq: fixing misc UI glitches
Creating allocations and credits in the Funding Source Details interface
didn't populate the appropriate grid immediately, but now it does.
New tags didn't seem to persist in the Fund Details interface if you switched
tabs and then came back to the Tags tab. Fixed.
Changed some tab names of misc Acq interfaces to match their current names in
the staff client menu.
Modified: trunk/Open-ILS/web/js/ui/default/acq/common/tag_manager.js
===================================================================
--- trunk/Open-ILS/web/js/ui/default/acq/common/tag_manager.js 2010-06-25 15:16:41 UTC (rev 16814)
+++ trunk/Open-ILS/web/js/ui/default/acq/common/tag_manager.js 2010-06-25 16:00:36 UTC (rev 16815)
@@ -57,6 +57,11 @@
dojo.destroy(
"oils-acq-fund-tag-mapping-" + mapping.id()
);
+ fund.tags(
+ fund.tags().filter(
+ function(o) { return o.id() != mapping.id(); }
+ )
+ );
},
"onerror": function() {
/* XXX does onerror not actually work? */
@@ -81,6 +86,7 @@
"oncomplete": function(r, list) {
mapping = list[0]; /* get the new mapping's ID this way */
mapping.tag(tag); /* re-"flesh" */
+ fund.tags().push(mapping); /* save local reference */
dojo.place(
self.renderTagMapping(mapping),
self.displayNode, "last"
Modified: trunk/Open-ILS/web/js/ui/default/acq/financial/view_fund.js
===================================================================
--- trunk/Open-ILS/web/js/ui/default/acq/financial/view_fund.js 2010-06-25 15:16:41 UTC (rev 16814)
+++ trunk/Open-ILS/web/js/ui/default/acq/financial/view_fund.js 2010-06-25 16:00:36 UTC (rev 16815)
@@ -66,6 +66,9 @@
function loadAllocationGrid() {
if(fundAllocationGrid.isLoaded) return;
+ /* XXX If we want to show allocating user with a username instead of just
+ * ID#, the following pcrud search will have to be replaced with an API
+ * call. */
fundAllocationGrid.loadAll({order_by : {acqfa : 'create_time DESC'}});
fundAllocationGrid.isLoaded = true;
}
Modified: trunk/Open-ILS/web/js/ui/default/acq/financial/view_funding_source.js
===================================================================
--- trunk/Open-ILS/web/js/ui/default/acq/financial/view_funding_source.js 2010-06-25 15:16:41 UTC (rev 16814)
+++ trunk/Open-ILS/web/js/ui/default/acq/financial/view_funding_source.js 2010-06-25 16:00:36 UTC (rev 16815)
@@ -16,11 +16,11 @@
var ses = new OpenSRF.ClientSession('open-ils.acq');
var fundingSource = null;
-function resetPage() {
+function resetPage(also_load_grid) {
fundingSource = null;
fsCreditGrid.isLoaded = false;
fsAllocationGrid.isLoaded = false;
- loadFS();
+ loadFS(also_load_grid);
}
function getFund(rowIndex, item) {
@@ -32,17 +32,21 @@
/** creates a new funding_source_credit from the dialog ----- */
function applyFSCredit(fields) {
fields.funding_source = fundingSourceID;
- openils.acq.FundingSource.createCredit(fields, resetPage);
+ openils.acq.FundingSource.createCredit(
+ fields, function() { resetPage(loadCreditGrid); }
+ );
}
function applyFSAllocation(fields) {
fields.funding_source = fundingSourceID;
if(isNaN(fields.amount)) fields.amount = null;
- openils.acq.Fund.createAllocation(fields, resetPage);
+ openils.acq.Fund.createAllocation(
+ fields, function() { resetPage(loadAllocationGrid); }
+ );
}
/** fetch the fleshed funding source ----- */
-function loadFS() {
+function loadFS(also_load_grid) {
var req = ses.request(
'open-ils.acq.funding_source.retrieve',
openils.User.authtoken, fundingSourceID,
@@ -58,6 +62,8 @@
return;
}
loadFSGrid();
+ if (typeof(also_load_grid) == "function")
+ also_load_grid(true /* reset_first */);
}
req.send();
}
@@ -87,7 +93,7 @@
}
}
-/** builds the credits grid ----- */
+/** builds the summary grid ----- */
function loadFSGrid() {
if(!fundingSource) return;
var store = new dojo.data.ItemFileReadStore({data:acqfs.toStoreData([fundingSource])});
@@ -97,8 +103,9 @@
/** builds the credits grid ----- */
-function loadCreditGrid() {
- if(fsCreditGrid.isLoaded) return;
+function loadCreditGrid(reset_first) {
+ if (fsCreditGrid.isLoaded) return;
+ if (reset_first) fsCreditGrid.resetStore();
fsCreditGrid.loadAll(
{"order_by": {"acqfscred": "effective_date DESC"}},
{"funding_source": fundingSource.id()}
@@ -106,8 +113,9 @@
fsCreditGrid.isLoaded = true;
}
-function loadAllocationGrid() {
- if(fsAllocationGrid.isLoaded) return;
+function loadAllocationGrid(reset_first) {
+ if (fsAllocationGrid.isLoaded) return;
+ if (reset_first) fsCreditGrid.resetStore();
fsAllocationGrid.loadAll(
{"order_by": {"acqfa": "create_time DESC"}},
{"funding_source": fundingSource.id()}
Modified: trunk/Open-ILS/web/templates/default/acq/financial/view_funding_source.tt2
===================================================================
--- trunk/Open-ILS/web/templates/default/acq/financial/view_funding_source.tt2 2010-06-25 15:16:41 UTC (rev 16814)
+++ trunk/Open-ILS/web/templates/default/acq/financial/view_funding_source.tt2 2010-06-25 16:00:36 UTC (rev 16815)
@@ -125,6 +125,7 @@
<table
jsId="fsCreditGrid"
+ autoheight="true"
dojoType="openils.widget.AutoGrid"
fieldOrder="['amount', 'effective_date', 'deadline_date', 'note']"
suppressFields="['id', 'funding_source']"
Modified: trunk/Open-ILS/xul/staff_client/chrome/locale/en-US/offline.properties
===================================================================
--- trunk/Open-ILS/xul/staff_client/chrome/locale/en-US/offline.properties 2010-06-25 15:16:41 UTC (rev 16814)
+++ trunk/Open-ILS/xul/staff_client/chrome/locale/en-US/offline.properties 2010-06-25 16:00:36 UTC (rev 16815)
@@ -225,14 +225,14 @@
menu.cmd_local_admin_cash_reports.tab=Cash Reports
menu.cmd_local_admin_transit_list.tab=Transits
menu.cmd_acq_create_invoice.tab=New Invoice
-menu.cmd_acq_bib_search.tab=Title Search
-menu.cmd_acq_from_bib.tab=Import Catalog Records
+menu.cmd_acq_bib_search.tab=MARC Federated Search
+menu.cmd_acq_from_bib.tab=Load Catalog Record IDs
menu.cmd_acq_unified_search.tab=Acquisitions Search
-menu.cmd_acq_upload.tab=Load Order Record
+menu.cmd_acq_upload.tab=Load MARC Order Records
menu.cmd_acq_new_brief_record.tab=New Brief Record
menu.cmd_acq_po.tab=Purchase Orders
-menu.cmd_acq_user_requests.tab=User Requests
-menu.cmd_acq_claim_eligible.tab=Claim-Eligible Items
+menu.cmd_acq_user_requests.tab=Patron Requests
+menu.cmd_acq_claim_eligible.tab=Claim-Ready Items
menu.cmd_booking_resource.tab=Resources
menu.cmd_booking_reservation.tab=Reservations
menu.cmd_booking_reservation_pickup.tab=Reservation Pickup
More information about the open-ils-commits
mailing list