From: senator Date: Tue, 29 Jun 2010 21:51:34 +0000 (+0000) Subject: Booking: bit-by-bit forward-port; see commit msg for r16827 X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=55c0c94209f06485a9d05d0396fcd24368e0d962;p=evergreen%2Fbjwebb.git Booking: bit-by-bit forward-port; see commit msg for r16827 git-svn-id: svn://svn.open-ils.org/ILS/trunk@16832 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/sql/Pg/002.schema.config.sql b/Open-ILS/src/sql/Pg/002.schema.config.sql index ca3b0eb97..5e6bdcf73 100644 --- a/Open-ILS/src/sql/Pg/002.schema.config.sql +++ b/Open-ILS/src/sql/Pg/002.schema.config.sql @@ -68,7 +68,7 @@ CREATE TABLE config.upgrade_log ( install_date TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW() ); -INSERT INTO config.upgrade_log (version) VALUES ('0322'); -- Scott McKellar +INSERT INTO config.upgrade_log (version) VALUES ('0323'); -- senator CREATE TABLE config.bib_source ( id SERIAL PRIMARY KEY, diff --git a/Open-ILS/src/sql/Pg/950.data.seed-values.sql b/Open-ILS/src/sql/Pg/950.data.seed-values.sql index b7fd545a1..78e1fe03b 100644 --- a/Open-ILS/src/sql/Pg/950.data.seed-values.sql +++ b/Open-ILS/src/sql/Pg/950.data.seed-values.sql @@ -952,6 +952,17 @@ INSERT INTO actor.org_address VALUES (DEFAULT,DEFAULT,DEFAULT,1,'123 Main St.',N UPDATE actor.org_unit SET holds_address = 1, ill_address = 1, billing_address = 1, mailing_address = 1; +-- In booking, elbow room defines: +-- a) how far in the future you must make a reservation on a given item if +-- that item will have to transit somewhere to fulfill the reservation. +-- b) how soon a reservation must be starting for the reserved item to +-- be op-captured by the checkin interface. +INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( + (SELECT id FROM actor.org_unit WHERE parent_ou IS NULL), + 'circ.booking_reservation.default_elbow_room', + '"1 day"' +); + INSERT INTO config.billing_type (id, name, owner) VALUES ( 1, oils_i18n_gettext(1, 'Overdue Materials', 'cbt', 'name'), 1); INSERT INTO config.billing_type (id, name, owner) VALUES @@ -2118,6 +2129,26 @@ INSERT INTO config.org_unit_setting_type ( name, label, description, datatype ) 'bool' ); +-- 0323.data.booking.elbow_room.sql +INSERT INTO config.org_unit_setting_type + (name, label, description, datatype) VALUES ( + 'circ.booking_reservation.default_elbow_room', + oils_i18n_gettext( + 'circ.booking_reservation.default_elbow_room', + 'Booking: Elbow room', + 'coust', + 'label' + ), + oils_i18n_gettext( + 'circ.booking_reservation.default_elbow_room', + 'Elbow room specifies how far in the future you must make a reservation on an item if that item will have to transit to reach its pickup location. It secondarily defines how soon a reservation on a given item must start before the check-in process will opportunistically capture it for the reservation shelf.', + 'coust', + 'label' + ), + 'interval' + ); + + -- Org_unit_setting_type(s) that need an fm_class: INSERT into config.org_unit_setting_type ( name, label, description, datatype, fm_class ) VALUES diff --git a/Open-ILS/src/sql/Pg/upgrade/0323.data.booking.elbow_room.sql b/Open-ILS/src/sql/Pg/upgrade/0323.data.booking.elbow_room.sql new file mode 100644 index 000000000..514c056cc --- /dev/null +++ b/Open-ILS/src/sql/Pg/upgrade/0323.data.booking.elbow_room.sql @@ -0,0 +1,35 @@ +BEGIN; + +INSERT INTO config.upgrade_log (version) VALUES ('0323'); -- senator + +-- In booking, elbow room defines: +-- a) how far in the future you must make a reservation on a given item if +-- that item will have to transit somewhere to fulfill the reservation. +-- b) how soon a reservation must be starting for the reserved item to +-- be op-captured by the checkin interface. + +INSERT INTO config.org_unit_setting_type + (name, label, description, datatype) VALUES ( + 'circ.booking_reservation.default_elbow_room', + oils_i18n_gettext( + 'circ.booking_reservation.default_elbow_room', + 'Booking: Elbow room', + 'coust', + 'label' + ), + oils_i18n_gettext( + 'circ.booking_reservation.default_elbow_room', + 'Elbow room specifies how far in the future you must make a reservation on an item if that item will have to transit to reach its pickup location. It secondarily defines how soon a reservation on a given item must start before the check-in process will opportunistically capture it for the reservation shelf.', + 'coust', + 'label' + ), + 'interval' + ); + +INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( + (SELECT id FROM actor.org_unit WHERE parent_ou IS NULL), + 'circ.booking_reservation.default_elbow_room', + '"1 day"' +); + +COMMIT; diff --git a/Open-ILS/web/css/skin/default/booking.css b/Open-ILS/web/css/skin/default/booking.css index 2c4240436..f020ded24 100644 --- a/Open-ILS/web/css/skin/default/booking.css +++ b/Open-ILS/web/css/skin/default/booking.css @@ -87,3 +87,21 @@ div#patron_info { font-size: 12pt; font-weight: bold; } div#no_ready_bresv, div#no_out_bresv, div#no_in_bresv { font-style: italic; } +.tundra .dojoxGridRowSelected { + background-color: #006699 !important; + color: #ffffff; +} +.pull_list_resv_detail { + border-bottom: 1px dashed #999999; + margin-bottom: 4px; +} +.pull_list_will_transit { font-weight: bold; color: #ff6666; } +iframe#printing_iframe { + border-top: 1px dashed #333333; + border-left: 0; + border-right: 0; + border-bottom: 0; +} +button.print_slip { + margin-left: 24px; +} diff --git a/Open-ILS/web/opac/locale/en-US/lang.dtd b/Open-ILS/web/opac/locale/en-US/lang.dtd index f8ec360f5..60bd730ae 100644 --- a/Open-ILS/web/opac/locale/en-US/lang.dtd +++ b/Open-ILS/web/opac/locale/en-US/lang.dtd @@ -846,7 +846,8 @@ - + + diff --git a/Open-ILS/web/opac/locale/en-US/opac.dtd b/Open-ILS/web/opac/locale/en-US/opac.dtd index 3ea8c4c6d..9c74dd3f9 100644 --- a/Open-ILS/web/opac/locale/en-US/opac.dtd +++ b/Open-ILS/web/opac/locale/en-US/opac.dtd @@ -496,6 +496,7 @@ Please see a librarian to renew your account."> + diff --git a/Open-ILS/web/opac/skin/default/js/copy_details.js b/Open-ILS/web/opac/skin/default/js/copy_details.js index 94adfd1f7..e5c50c093 100644 --- a/Open-ILS/web/opac/skin/default/js/copy_details.js +++ b/Open-ILS/web/opac/skin/default/js/copy_details.js @@ -232,6 +232,29 @@ function cpdDrawCopy(r) { ); } + /* show the book now link */ + l = $n(row, 'copy_reserve_link'); + unHideMe(l); + l.onclick = function() { + // XXX FIXME this duplicates things in cat/util.js + // Also needs i18n + dojo.require("fieldmapper.Fieldmapper"); + var r = fieldmapper.standardRequest( + ["open-ils.booking", + "open-ils.booking.resources.create_from_copies"], + [G.user.session, [copy.id()]] + ); + if (!r) { + alert("No response from server!"); + } else if (r.ilsevent != undefined) { + alert("Error from server:\n" + js2JSON(r)); + } else { + xulG.auth = {"session": {"key": G.user.session}}; + xulG.bresv_interface_opts = {"booking_results": r}; + location.href = "/eg/booking/reservation"; + } + } + if( copy.age_protect() ) appendClear($n(row, 'age_protect_value'), text(copy.age_protect().name())); diff --git a/Open-ILS/web/opac/skin/default/xml/rdetail/rdetail_cn_details.xml b/Open-ILS/web/opac/skin/default/xml/rdetail/rdetail_cn_details.xml index 0da7af96b..09765fd4e 100644 --- a/Open-ILS/web/opac/skin/default/xml/rdetail/rdetail_cn_details.xml +++ b/Open-ILS/web/opac/skin/default/xml/rdetail/rdetail_cn_details.xml @@ -29,6 +29,8 @@ &rdetail.cn.less; &rdetail.cn.hold; + &rdetail.cn.reserve;