[open-ils-commits] SPAM: r9391 - in branches/acq-experiment: .
Open-ILS/src/extras Open-ILS/src/sql/Pg Open-ILS/web/js/dojo/openils
svn at svn.open-ils.org
svn at svn.open-ils.org
Sun Apr 20 09:43:01 EDT 2008
Author: erickson
Date: 2008-04-20 09:04:12 -0400 (Sun, 20 Apr 2008)
New Revision: 9391
Modified:
branches/acq-experiment/
branches/acq-experiment/Open-ILS/src/extras/Makefile.install
branches/acq-experiment/Open-ILS/src/sql/Pg/110.hold_matrix.sql
branches/acq-experiment/Open-ILS/src/sql/Pg/950.data.seed-values.sql
branches/acq-experiment/Open-ILS/web/js/dojo/openils/User.js
Log:
Merged revisions 9388-9390 via svnmerge from
svn://svn.open-ils.org/ILS/trunk
........
r9388 | dbs | 2008-04-19 23:09:22 -0400 (Sat, 19 Apr 2008) | 2 lines
Use 950.data.seed-values.sql to avoid referential integrity errors
........
r9389 | dbs | 2008-04-19 23:26:38 -0400 (Sat, 19 Apr 2008) | 2 lines
XML::LibXML::XPathContext is a prerequisite for Application::Fielder and Application::PermaCrud
........
r9390 | erickson | 2008-04-20 09:02:32 -0400 (Sun, 20 Apr 2008) | 1 line
added a method to build a Tree based on perm orgs.
........
Property changes on: branches/acq-experiment
___________________________________________________________________
Name: svnmerge-integrated
- /trunk:1-9386
+ /trunk:1-9390
Modified: branches/acq-experiment/Open-ILS/src/extras/Makefile.install
===================================================================
--- branches/acq-experiment/Open-ILS/src/extras/Makefile.install 2008-04-20 13:02:32 UTC (rev 9390)
+++ branches/acq-experiment/Open-ILS/src/extras/Makefile.install 2008-04-20 13:04:12 UTC (rev 9391)
@@ -188,7 +188,8 @@
JSON::XS\
SRU \
Net::Z3950::ZOOM \
- Business::CreditCard::Object
+ Business::CreditCard::Object \
+ XML::LibXML::XPathContext
# ----------------------------------------------------------------------------
Modified: branches/acq-experiment/Open-ILS/src/sql/Pg/110.hold_matrix.sql
===================================================================
--- branches/acq-experiment/Open-ILS/src/sql/Pg/110.hold_matrix.sql 2008-04-20 13:02:32 UTC (rev 9390)
+++ branches/acq-experiment/Open-ILS/src/sql/Pg/110.hold_matrix.sql 2008-04-20 13:04:12 UTC (rev 9391)
@@ -34,8 +34,6 @@
CONSTRAINT hous_once_per_grp_loc_mod_marc UNIQUE (user_home_ou, request_ou, pickup_ou, item_owning_ou, item_circ_ou, requestor_grp, usr_grp, circ_modifier, marc_type, marc_form, marc_vr_format)
);
-INSERT INTO config.hold_matrix_matchpoint (requestor_grp) VALUES (1);
-
-- Tests to determine if hold against a specific copy is possible for a user at (and from) a location
CREATE TABLE config.hold_matrix_test (
matchpoint INT PRIMARY KEY REFERENCES config.hold_matrix_matchpoint (id),
Modified: branches/acq-experiment/Open-ILS/src/sql/Pg/950.data.seed-values.sql
===================================================================
--- branches/acq-experiment/Open-ILS/src/sql/Pg/950.data.seed-values.sql 2008-04-20 13:02:32 UTC (rev 9390)
+++ branches/acq-experiment/Open-ILS/src/sql/Pg/950.data.seed-values.sql 2008-04-20 13:04:12 UTC (rev 9391)
@@ -1284,6 +1284,10 @@
INSERT INTO config.circ_matrix_matchpoint (org_unit,grp) VALUES (1,1);
INSERT INTO config.circ_matrix_ruleset (matchpoint,duration_rule,recurring_fine_rule,max_fine_rule) VALUES (1,11,1,1);
+
+-- hold matrix - 110.hold_matrix.sql:
+INSERT INTO config.hold_matrix_matchpoint (requestor_grp) VALUES (1);
+
-- Staged Search (for default matchpoints)
INSERT INTO search.relevance_adjustment (field, bump_type, multiplier) VALUES(1, 'first_word', 1.5);
INSERT INTO search.relevance_adjustment (field, bump_type, multiplier) VALUES(1, 'full_match', 20);
Modified: branches/acq-experiment/Open-ILS/web/js/dojo/openils/User.js
===================================================================
--- branches/acq-experiment/Open-ILS/web/js/dojo/openils/User.js 2008-04-20 13:02:32 UTC (rev 9390)
+++ branches/acq-experiment/Open-ILS/web/js/dojo/openils/User.js 2008-04-20 13:04:12 UTC (rev 9391)
@@ -19,7 +19,7 @@
dojo._hasResource["openils.User"] = true;
dojo.provide("openils.User");
dojo.require('openils.Event');
- dojo.require('DojoSRF');
+ dojo.require('fieldmapper.Fieldmapper');
dojo.declare('openils.User', null, {});
@@ -109,6 +109,41 @@
req.send();
}
+
+ /**
+ * Builds a dijit.Tree using the orgs where the user has the requested permission
+ * @param perm The permission to check
+ * @param domId The DOM node where the tree widget should live
+ * @param onClick If defined, this will be connected to the tree widget for
+ * onClick events
+ */
+ openils.User.buildPermOrgTreePicker = function(perm, domId, onClick) {
+
+ function buildTreePicker(r) {
+ var orgList = r.recv().content();
+ var store = new dojo.data.ItemFileReadStore({data:aou.toStoreData(orgList)});
+ var model = new dijit.tree.ForestStoreModel({
+ store: store,
+ query: {_top:'true'},
+ childrenAttrs: ["children"],
+ rootLabel : "Location" /* XXX i18n */
+ });
+
+ var tree = new dijit.Tree({model : model}, dojo.byId(domId));
+ if(onClick)
+ dojo.connect(tree, 'onClick', onClick);
+ tree.startup()
+ }
+
+ fieldmapper.standardRequest(
+ ['open-ils.actor', 'open-ils.actor.user.work_perm.org_unit_list'],
+ {
+ params: [openils.User.authtoken, 'ADMIN_FUNDING_SOURCE'],
+ oncomplete: buildTreePicker,
+ async: true
+ }
+ )
+ }
}
More information about the open-ils-commits
mailing list