Dan Scott [Mon, 27 Jun 2011 18:18:39 +0000 (14:18 -0400)]
Meaningful title elements for record details and search results
Rather than the generic "Record Details" and "Search Results", populate
the <title> element with the actual title of the record or the search
query, respectively.
We punt on advanced search results for now, until we can parse the array
into something usable.
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Dan Scott <dan@coffeecode.net> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Bill Erickson [Fri, 24 Jun 2011 15:27:26 +0000 (11:27 -0400)]
Option to generate lacking overdues on lost checkin
New org unit setting "circ.lost.generate_overdue_on_checkin".
This org unit setting enables retroactive overdue fine generation for
lost item checkin. When enabled, the system will generate overdue fines
starting from the date of the last created overdue fine for the
circulation and working its way up to the checkin time or stopping at
the max fine amount (consistent with regular overdue fine generation).
This differs from the existing org unit setting
"circ.restore_overdue_on_lost_return", which only un-voids existing
overdue fines.
Consider an item whose due date is the 1st, that gets marked lost on the
7th, then checked in on the 14th. If set,
"circ.restore_overdue_on_lost_return" would un-void the fines created up
to the 7th and "circ.lost.generate_overdue_on_checkin" would create new
overdue fines from the 7th up to the 14th (or up to the max fine
amount).
Signed-off-by: Bill Erickson <berick@esilibrary.com> Signed-off-by: Mike Rylander <mrylander@gmail.com>
Jason Etheridge [Fri, 24 Jun 2011 19:40:32 +0000 (15:40 -0400)]
with scan missing pieces, retarget affected holds prior to recirculating to previous patron, lest the checkout reset the holds for us without retargeting
Signed-off-by: Jason Etheridge <jason@esilibrary.com> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Fri, 24 Jun 2011 23:29:30 +0000 (19:29 -0400)]
Show human label for Internet Access Level in Patron Search
Looks like fm_columns uses a prefix of "au_" for the column name defined
in util.js. Therefore, au_net_access_level lets us define the label to
display in place of the integer value.
Jason Etheridge [Tue, 31 May 2011 19:46:50 +0000 (15:46 -0400)]
Specify the display field for linked objects with fm_columns
If a display field isn't specified, it defaults to the key field,
which is essentially the same as not fleshing the object in the first
place. Let me know if fieldmapper has or gains a way of specifying
such "display" fields, and we can augment fm_columns to use it as well.
Signed-off-by: Jason Etheridge <jason@esilibrary.com> Signed-off-by: Dan Scott <dan@coffeecode.net>
Dan Scott [Fri, 24 Jun 2011 15:35:10 +0000 (11:35 -0400)]
Support Fedora 15 as a target in Makefile.install
Add Fedora 15 to the Makefile.install as a simple clone of the Fedora 14
target for now. Correct Makefile.install target names in README, and
point out that nothing special is required for Fedora 15 for PostgreSQL
9 support.
While we're in the README, rip out the Dojo toolkit install info as
packaged releases include Dojo now (we retain the developer instructions
for installing Dojo manually for git users, of course).
Jason Stephenson [Mon, 20 Jun 2011 18:07:54 +0000 (14:07 -0400)]
Add checkout override to SIP2 checkout & renew.
OpenILS::SIP::Transaction::Checkout was modified to allow for
the override of certain, configurable events much in the same
way that checkin currently does overrides.
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Ben Webb [Mon, 13 Jun 2011 12:31:53 +0000 (13:31 +0100)]
Respect DESTDIR during the build process
Add $(DESTDIR) to paths it is currently missing from
Manually specify the apxs2 install location so that DESTDIR can be prepended
Attempt to create the apache directory if it does not exist
Signed-off-by: Ben Webb <bjwebb67@googlemail.com> Signed-off-by: Dan Scott <dan@coffeecode.net>
Bill Erickson [Thu, 2 Jun 2011 18:44:28 +0000 (14:44 -0400)]
Option to force-delete copies during volume delete
Added a "force_delete_copies" option to
open-ils.cat.asset.volume.fleshed.batch.update* which forces deletion of
all copies attached to a volume if the volume is being deleted. There
are still scenarios that will result in copies not being deleted
(e.g. copy is checked out), in which case the override option will
behave here the same way it behaves in
open-ils.cat.asset.copy.fleshed.batch.update*
Signed-off-by: Bill Erickson <berick@esilibrary.com> Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Bill Erickson [Fri, 3 Jun 2011 13:27:26 +0000 (09:27 -0400)]
Permission to control patron-collections-exempt
Adds a new permission 'UPDATE_PATRON_COLLECTIONS_EXEMPT' which controls
who can toggle the circ.collections.exempt user setting in the patron
registration interface.
Signed-off-by: Bill Erickson <berick@esilibrary.com> Signed-off-by: Mike Rylander <mrylander@gmail.com>
Jason Stephenson [Wed, 22 Jun 2011 14:48:58 +0000 (10:48 -0400)]
Check if hold is really available in Trigger::Validator.
Add checks for shelf time and no fulfillment time in
HoldIsAvailable in OpenILS::Application::Trigger::Validator.
We've had some issues with poorly migrated data and people
messing with holds that causes the original logic to trigger
for unfilled holds. Plus, the extra precaution of checking
more precise conditions of an actually filled hold can't hurt,
can it?
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org> Signed-off-by: Mike Rylander <mrylander@gmail.com>
Dan Wells [Tue, 21 Jun 2011 21:09:58 +0000 (17:09 -0400)]
Further clean-up of Serials interfaces
When trying to come up with good tests, found a few bugs (imagine!).
Some have been nagging for a while now.
1) For 'MFHDDrawn' event, make sure it runs if deleting the last
serials data of any kind for that record (to unpopulate the menus
properly)
2) Make sure global mfhd member (g.mfhd) is cleared in the same case
(i.e. deleting the last serials data for that record)
3) Add a string to better indicate when no MFHD records are available
for 'Legacy Record Entry' drop-down
4) Convert submitted empty drop-down values to 'null' as needed in
distribution editor
5) Mark subscription 'start date' as a required field
6) Make serial virtual records better handle deleted 'legacy record
entries' attached to distributions, and also expose non-deleted
record entries even if in 'use_sdist_only' summary mode
Signed-off-by: Dan Wells <dbw2@calvin.edu> Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Dan Wells [Fri, 17 Jun 2011 19:26:39 +0000 (15:26 -0400)]
Better coordination of MFHD/SRE adding/deleting
Adding or deleting MFHD records from the XUL menus requires
coordinating the OPAC display, the XUL menus, and the Serial
Control distribution editors. The previous code frequently
required some non-obvious manual refreshing to make it work.
This commit keeps them in sync using custom events instead.
Signed-off-by: Dan Wells <dbw2@calvin.edu> Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Dan Scott [Wed, 22 Jun 2011 03:31:01 +0000 (23:31 -0400)]
Add unit tests for LP 800269 - holdings for captions only
Running "prove -l lib" in Open-ILS/src/perlmods shows that the two new
unit tests pass, whereas they fail using the previously installed
version of MFHD.pm. Good evidence that the fix from dbwells does indeed
solve the reported bug.
Dan Wells [Tue, 21 Jun 2011 15:44:10 +0000 (11:44 -0400)]
MFHD compressed holdings short-circuit logic
If you attempt to get compressed (or uncompressed) holdings from
a MFHD record with only a caption, the code should short-circuit
and return an empty list.
Signed-off-by: Dan Wells <dbw2@calvin.edu> Signed-off-by: Dan Scott <dan@coffeecode.net>
Record the date a copy first became "active" after creation in active_date.
Offer Org Unit setting for using the active date for age hold protection.
Any copy without an active_date, with age hold protect using it, will be
protected until it has an active date. Regardless of create_date.
Circ/Hold matrix can match on item age based on active_date.
Active is defined as entering a status with copy_active set to true. By default:
Available
Checked out
Reshelving
On holds shelf
ILL
Reserves
On reservation shelf
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Mon, 13 Jun 2011 01:24:01 +0000 (21:24 -0400)]
Refactor cover image fetching in OpenLibrary added content
We were only trying to retrieve images from the items array in the
OpenLibrary response, but there are only items if the OpenLibrary has
online editions available - whereas there may be covers attached to the
metadata for the work. So now we make the metadata work harder.
Also, cut down on broken images in search results by short-circuiting if
OpenLibrary doesn't have a matching record for a given ISBN.
Thanks to Bill Erickson for pointing out that there were a lot of blank
images getting returned due to the items reliance.
Signed-off-by: Dan Scott <dan@coffeecode.net> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Thu, 2 Jun 2011 18:40:57 +0000 (14:40 -0400)]
Teach result_common.js to OpenLibrary requests
Now that the proxied OpenLibrary requests are working, teach
result_common.js to use them and get an advantage from being an
access-rights-authenticated IP address (if applicable).
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Thu, 2 Jun 2011 17:03:22 +0000 (13:03 -0400)]
Support proxying bulk Read API requests for access rights
Using IP-based access right determination runs into problems with a pure
JavaScript API, as users may be accessing the API from any location in
the world. Proxying the requests via the library system server ensures
that the access rights for users of those libraries are properly
displayed.
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Thu, 2 Jun 2011 16:25:33 +0000 (12:25 -0400)]
Return transparent images if no cover art is found
For now the URL is hardcoded; later on we'll refactor AddedContent.pm to
give us access to more information about our Apache environment to
default to something much, much smarter.
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Thu, 2 Jun 2011 13:56:05 +0000 (09:56 -0400)]
Get OpenLibrary covers from any related items
Cover requests for exact matches sometimes fail to produce results, but
covers from similar items (other editions of the same work) are often
available. Take that!
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Thu, 2 Jun 2011 05:42:49 +0000 (01:42 -0400)]
Don't make OpenLibrary requests without an ID
It is rather silly to make requests if you have not pulled any IDs out
of the records to pass along to OpenLibrary, so do not do that. Also
refactor and add a bit more defensiveness.
Signed-off-by: Dan Scott <dan@coffeecode.net> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Wed, 1 Jun 2011 05:58:27 +0000 (01:58 -0400)]
Implement OpenLibrary ebook availability via Ajax
George Oates provided an OpenLibrary GIF to use for the
links, and we can drop the links right into the block of
white space between copy counts and bibliographic info.
Signed-off-by: Dan Scott <dan@coffeecode.net> Signed-off-by: Bill Erickson <berick@esilibrary.com>
Dan Scott [Fri, 17 Jun 2011 16:30:12 +0000 (12:30 -0400)]
Set AC timeout value to 3 seconds and describe tradeoffs
As discussed on the Evergreen Development mailing list, the higher the
AC timeout value, the greater the risk of a denial of service. 30 is
therefore too high to be comfortable as a default setting, so we're
dropping it down to 3 as a compromise between the original value of 1
(which resulted in a number of request timing out where added content
was actually available) and the much-less-safe 30.
In addition, we document inline the risk/reward of different values and
provide some justification for the default value that we chose, so that
Evergreen system administrators will have guidance when tweaking this
setting.
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Mike Rylander <mrylander@gmail.com>
Dan Scott [Mon, 20 Jun 2011 15:16:21 +0000 (11:16 -0400)]
DROP biblio.reingest_uris() after use
We will hopefully only need to reingest URIs in bulk once, and can
therefore DROP the biblio.reingest_uris() function after it has been
successfully invoked.
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Dan Scott [Mon, 20 Jun 2011 14:56:44 +0000 (10:56 -0400)]
Protect URI reingest from failure due to malformed XML
In an ideal world, there would be no malformed XML. But our world is the
real world of libraries, and while the well_formed_xml() protects
against malformed XML in Evergreen 2.0 systems, in some cases bad XML
has been able to find its way into Evergreen systems in the past.
A single biblio.record_entry row containing malformed XML in the marc
column will prevent the call to reingest URIs from succeeding. By
limiting the set of records to those with well-formed XML, we can
increase the chance of the URI reingest succeeding at the cost of more
processing time.
Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bill Erickson [Thu, 16 Jun 2011 15:50:16 +0000 (11:50 -0400)]
Repaired exchange rate PO activation bug
Code was using the wrong hash key to read data from cstore request,
resulting in a NULL debit amount when activating a PO with a different
provider => fund currencies. This resulted in POs that could not be
activated.
Signed-off-by: Bill Erickson <berick@esilibrary.com>
Add a stored procedure to reingest problematic URIs
Assuming that href = label in asset.uri is a red enough flag for the
problem in LP 797307 where the perfectly good label was being thrown
away, reingest the unique set of records connected with such asset.uri
rows.
Signed-off-by: Dan Scott <dscott@laurentian.ca>
commit 39fe0c4a8a3074ff4c1e427ad9f00a0760bac260
Author: Dan Scott <dan@coffeecode.net>
Date: Tue Jun 14 21:54:51 2011 -0400
Add unwrapped upgrade script for biblio.extract_located_uris
See XXXX.biblio.extract_located_uris.sql for the upgrade script, waiting
to be signed off and committed.
Signed-off-by: Dan Scott <dscott@laurentian.ca>
create mode 100644 Open-ILS/src/sql/Pg/upgrade/XXXX.biblio.extract_located_uris.sql
Avoid duplicate row issues in biblio.extract_located_uris
As there is currently no unique constraint on the non-ID columns of
asset.uri, ensure that we only select a single ID from the tables until
we dedupe the tables. Use an ORDER BY to grab the matching row with the
lowest ID so we can clear out the rows with higher IDs.
Signed-off-by: Dan Scott <dscott@laurentian.ca>
commit e79a805299ec734a29ee5bfa77dc74bc1fd208cd
Author: Dan Scott <dan@coffeecode.net>
Date: Tue Jun 14 14:02:49 2011 -0400
Fix LP 797304 and 797307 - asset.uri parsing bugs
Per 797304: one would expect asset.uri.label to be populated with the
value of 856 $y, however, it was getting populated with 856 $u - perhaps
as a result of the ordering of array entries in XPATH() not matching the
XPath expression. Instead of including 856 $u in the XPath expression
for uri_label, just assign its value to uri_label if uri_label is
otherwise NULL.
Per 797307: biblio.extract_located_uris() tries to reuse an existing
active asset.uri entry rather than create a new row; however, it does
not handle the case where there is no public note aka "use restriction"
and will end up creating a duplicate row every time the record is
reingested. Teach it to handle NULL values properly.
Jason Etheridge [Wed, 15 Jun 2011 07:13:50 +0000 (03:13 -0400)]
lp797321: Disable the Apply Payment button during payment processing to mitigate chance of duplicate payments.
I can't actually reproduce the creation of duplicate payments locally with
trunk/2.x, but there are reports of it, and this doesn't seem to hurt. Not
a complete solution, but better than before
Signed-off-by: Jason Etheridge <jason@esilibrary.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Dan Scott [Tue, 14 Jun 2011 02:54:27 +0000 (22:54 -0400)]
Resolve Squeeze installation problems with PostgreSQL 9.0
When you install OpenSRF on Debian Squeeze, one of the packages
(apache2-prefork-dev) installs 8.4 versions of libpq5 and libpq-dev as
dependencies. These conflict with the 9.0 versions that are required as
dependencies for PostgreSQL 9.0 - so get them out of the way, pin the
9.0 versions of the packages, and reinstall apache2-prefork-dev.
We will probably need to do something similar for Lucid.
Dan Wells [Mon, 13 Jun 2011 18:16:47 +0000 (14:16 -0400)]
Serial note perms and edit support
This expands the interface to allow for editing notes on serials
objects. At some point we will likely want to track edit dates as
well, but this gets the ball rolling.
Also renames some methods from 'create' to 'update' to match new
capabilities and make the overall API more consistent, and adds perm
checks based on related objects.
Dan Scott [Tue, 31 May 2011 17:55:29 +0000 (13:55 -0400)]
Remove all references to Cookie(s).js and Cookies.js
Dojo toolkit is the new Cookie manager, so any lingering
references to Cookie.js (a typo in any case) are no longer
valid, and we no longer need to ship Cookies.js with
Evergreen.
Cookie.js typo was reported by Steven Chan in LP 790429