evergreen/tadl.git
13 years agoAdded missing Penalty module import for AssetCommon
Bill Erickson [Thu, 29 Sep 2011 15:57:46 +0000 (11:57 -0400)]
Added missing Penalty module import for AssetCommon

The lack of import primarily affected the Action/Trigger MarkItemLost
reactor, which does not already import OpenILS::Utils::Penalty directly
or indirectly.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoRemove an installation step: Listen 443 uncommenting
Dan Scott [Thu, 29 Sep 2011 03:06:19 +0000 (23:06 -0400)]
Remove an installation step: Listen 443 uncommenting

Every distribution known to man ships Apache listening on port 443, so
installers always have to comment out the "Listen 443" directive - so
why not just comment it out ourselves and save a step in the
installation instructions?

Also, merge Apache configuration instructions from master.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoA slight modification to prevent clipping in the EDI Accounts interface
Michael Peters [Wed, 28 Sep 2011 13:09:33 +0000 (09:09 -0400)]
A slight modification to prevent clipping in the EDI Accounts interface

Just a few tweaks via CSS to make sure the footer notes don't clip off part of the main grid.

Signed-off-by: Michael Peters <mrpeters@library.in.gov>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoProvide proper hrefs for links back from report debugging pages
Mike Rylander [Wed, 28 Sep 2011 19:45:36 +0000 (15:45 -0400)]
Provide proper hrefs for links back from report debugging pages

Reimplementation of a fix provided by Michael Peters.  The originally submitted
patch included several fixes provided by an unrelated patch, and a regression
in build-time embedded tokens.

Original branch at: http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/mrpeters-isl/clark_kent_back_links

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoLP856567: Mark HTML report output as Unicode-encoded
Dan Scott [Thu, 22 Sep 2011 16:51:22 +0000 (12:51 -0400)]
LP856567: Mark HTML report output as Unicode-encoded

Non-ASCII characters in report ouput that has been generated in HTML
format appears to be corrupted when viewed in a browser. This can be
manually corrected by switching the "Encoding" browser option, but it
would be better to include <meta charset='utf-8'> in the output HTML to
tell the browser directly.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoMFHD compression fails with pattern-less captions
Dan Wells [Tue, 27 Sep 2011 16:22:38 +0000 (12:22 -0400)]
MFHD compression fails with pattern-less captions

The current code assumes that if you try to compress a range of
MFHD holdings, you actually have the necessary pattern information.
This commit introduces a very basic check to avoid the most common
failure case.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoLP857460: Get the generic class scheme when adding vols
Dan Scott [Fri, 23 Sep 2011 14:55:28 +0000 (10:55 -0400)]
LP857460: Get the generic class scheme when adding vols

In a default Evergreen instance, in the "Add Volumes" interface for a
bib record with both LC and Dewey call numbers, the list of call numbers
from which you can select appears to be limited to Dewey, even though
the "Bib Call #" field is populated with an LC call number.

The problem is that here we're grabbing the first entry from the
asset.call_number_classification table, and you might expect that to be
the "Generic" entry - however, it turns out to be the "Dewey" entry
because the entries are ordered alphabetically by .name(), not by
database ID. (You can test this be changing the name of "Dewey" to
"Vicious" and see that the "Generic" entry is chosen instead).

This commit changes the process to first search the acnc array for a
name() = "Generic"; and then if we don't find that, fall back to the
first entry in the classification scheme.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Dan Wells <dbw2@calvin.edu>
13 years ago2.1-ish upgrade script preamble
Mike Rylander [Mon, 26 Sep 2011 16:43:37 +0000 (12:43 -0400)]
2.1-ish upgrade script preamble

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoStamping upgrade script for EDI cleanup
Mike Rylander [Mon, 26 Sep 2011 16:18:03 +0000 (12:18 -0400)]
Stamping upgrade script for EDI cleanup

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoSome EDI translation fixes for troublesome input characters
Lebbeous Fogle-Weekley [Mon, 19 Sep 2011 17:19:22 +0000 (13:19 -0400)]
Some EDI translation fixes for troublesome input characters

This attempts to address enough of the issues in
https://bugs.launchpad.net/evergreen/+bug/812593 to move forward.

When the ? character appears in lineitem attributes for a PO that we
send off for EDI translation, the translator fails if that ? is the last
character of the string.  This commit avoids that situation.

This commit also removes any Unicode characters from the JEDI (the input
to the translator process), as they're not going to make it to the
EDIFACT output anyhow, and will just confound the translator.

This commit also pre-escapes quotation marks in lineitem attributes so
that we don't produce invalid JSON for our JEDI.

This commit also destroys the death star.

Seriously, the right way to fix some of the issues people have had is
for somebody to learn Ruby and to address them either in edi_webrick.rb, in
edi4r, or in openils-mapper (wherever the issues may be).  Working on
that.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agolp859190: make marc_stream_import always import non-matches
Galen Charlton [Sun, 25 Sep 2011 20:55:38 +0000 (16:55 -0400)]
lp859190: make marc_stream_import always import non-matches

Fixes regression of (implicit, undocumented) functionality
introduced in commit da3a45344205.  Current use case for
the streaming MARC importer for OCLC Connexion exports assumes
that non-matching records should always be added.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoFix: Current Bills thinks it is Bill History
Jeff Godin [Wed, 21 Sep 2011 20:41:19 +0000 (16:41 -0400)]
Fix: Current Bills thinks it is Bill History

This fixes LP 855894: Bills interface calls itself Bill History,
uses bills_historical receipt template

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

At some point in development, the Current Bills and the Bill History
interface were in a unified file, with an xul_param of "current" used
to switch between the two.

Nothing currently sets the xul_param "current", so the Current Bills
interface (bill2.xul and bill2.js) was improperly:

* not hiding the xact_finish column
* using a caption label of "Bill History"
* using the bills_historical receipt template

The Bill History interface was okay -- "not current" was the default.

This commit removes the tests for xul_param('current') and uses the
appropriate code for each interface.

// this code in both bill2.js and bill_history.js:
var template = 'bills_historical';
if (xul_param('current')) template = 'bills_current';

// becomes:
var template = 'bills_current';    // in bill2.js
var template = 'bills_historical'; // in bill_history.js

Also: added missing staff.patron.bill_interface.caption.label entity

Signed-off-by: Jeff Godin <jgodin@tadl.org>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoRemove the old bills interface.
Jeff Godin [Tue, 20 Sep 2011 18:41:10 +0000 (14:41 -0400)]
Remove the old bills interface.

Remove the old bills interface and references to it.

see https://bugs.launchpad.net/evergreen/+bug/854951

Also remove the XUL_PATRON_BILL_ALTERNATE_VIEW constant and the
bills_main_view receipt template, as they were only referenced
in bills.js.

The bills_main_view template will still persist in existing
workstation configurations until such time as we have code to
remove unused templates.

I made no effort to remove strings which may have only been used
by the old bills interface.

Signed-off-by: Jeff Godin <jgodin@tadl.org>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoStamped upgrade script for ACQ fund view repairs
Bill Erickson [Thu, 22 Sep 2011 15:10:09 +0000 (11:10 -0400)]
Stamped upgrade script for ACQ fund view repairs

At the heart of this change is the need to force acq.fund_debit_total to
return exactly 1 row per fund, instead of 1 per fund + encumbrance
value.  However, such a change required rearranging a number of
dependent views.

Also added acq.fund_spent_balance to the set of views that needs
dropping and re-building.

Minor SQL format change to match surrounding code in schema file

See also https://bugs.launchpad.net/evergreen/+bug/800477

Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoAddresses LP#800477 where some acq views calculate the totals incorrectly or in unexp...
James Fournie [Mon, 19 Sep 2011 23:01:01 +0000 (16:01 -0700)]
Addresses LP#800477 where some acq views calculate the totals incorrectly or in unexpected ways.

Signed-off-by: James Fournie <jfournie@sitka.bclibraries.ca>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoFix broken Work Log UI
Jason Etheridge [Thu, 22 Sep 2011 14:36:57 +0000 (10:36 -0400)]
Fix broken Work Log UI

Missed a map_row_to_columns when I was ripping those out in c9c05ce8e179d7a9d4325ac1f429e91fcfe7c9a0

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agobump xulrunner version
Jason Etheridge [Wed, 21 Sep 2011 15:16:08 +0000 (11:16 -0400)]
bump xulrunner version

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoproperties in chrome:// return XHR status 0
Jason Etheridge [Wed, 21 Sep 2011 15:47:36 +0000 (11:47 -0400)]
properties in chrome:// return XHR status 0

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoLP#854760 messagecat fails with certain 404 pages
Jason Etheridge [Tue, 20 Sep 2011 14:52:02 +0000 (10:52 -0400)]
LP#854760 messagecat fails with certain 404 pages

We were failing to check the HTTP status on the underlying XHR requests.

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoCan't have two identical IDs on the same page
Dan Scott [Sat, 17 Sep 2011 03:44:28 +0000 (23:44 -0400)]
Can't have two identical IDs on the same page

Nobody who cares about the pure Web experience ever noticed that this
page has two identical IDs. Chromium and other browsers complain,
though, so make them happy.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agofix Show in Catalog for part holds
Jason Etheridge [Tue, 20 Sep 2011 13:48:05 +0000 (09:48 -0400)]
fix Show in Catalog for part holds

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
13 years agoClear hold shelf [expire] time at checkout to alternate patron
Bill Erickson [Thu, 25 Aug 2011 18:20:56 +0000 (14:20 -0400)]
Clear hold shelf [expire] time at checkout to alternate patron

When an item on the holds shelf is checked out to an alternate patron
(i.e. not the hold user), clear the shelf_time and shelf_expire_time
along with capture_time, current_copy, etc. on the hold.

tsbere++ for isolating the problem.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years ago2.1-ish backport of 1725fef40b6d09a57355eb750cf206960b93d1a6
Mike Rylander [Fri, 16 Sep 2011 15:38:58 +0000 (11:38 -0400)]
2.1-ish backport of 1725fef40b6d09a57355eb750cf206960b93d1a6

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agolp 851915: remove last references to /openils/lib/perl5
Galen Charlton [Fri, 16 Sep 2011 14:23:32 +0000 (10:23 -0400)]
lp 851915: remove last references to /openils/lib/perl5

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
13 years agoLP 851915: Remove references to /openils/lib/perl5
Dan Scott [Fri, 16 Sep 2011 13:59:54 +0000 (09:59 -0400)]
LP 851915: Remove references to /openils/lib/perl5

To prevent old versions of the OpenSRF and Evergreen Perl modules from
conflicting with the new versions of these modules (which are now
located in the default system Perl package directories), remove
references to them.

Also, O:W:AddedContent contains an old reference to a distro-specific
Perl directory that we can clean up at the same time.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
13 years agoSet ind2 to the value of indicicator 2 supplied by the user, not ind1
Mike Rylander [Thu, 15 Sep 2011 13:11:47 +0000 (09:11 -0400)]
Set ind2 to the value of indicicator 2 supplied by the user, not ind1

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agolp834961: fix authoritative versions of callnumber retrieval calls
Galen Charlton [Wed, 14 Sep 2011 16:27:45 +0000 (12:27 -0400)]
lp834961: fix authoritative versions of callnumber retrieval calls

Makes open-ils.search.callnumber[.fleshed].retrieve.authoritative
actually be authoritative.  Fixes bug where adding a volume
could result in a false ASSET_CALL_NUMBER_NOT_FOUND error if using
database replication and Slony-II.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoProvide a default value for, and explicitly change, the record type so the type dropd...
Mike Rylander [Tue, 13 Sep 2011 19:37:06 +0000 (15:37 -0400)]
Provide a default value for, and explicitly change, the record type so the type dropdown works as intended

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoDisplay warning message and prompt before PostgreSQL removal
Dan Scott [Wed, 7 Sep 2011 19:18:07 +0000 (15:18 -0400)]
Display warning message and prompt before PostgreSQL removal

Building on the good work in LP# 801624, use the -P "prompt" flag
instead of -yq for apt(itude) to ensure that the user has the ability to
quit the dependency install and reevaluate whether they want to actually
destroy their existing PostgreSQL databases. Note that this is
specifically in the context of the removal of the database packages,
rather than a global change.

Also, turn the inline comment into a displayed description of what is
happening and why, along with a nice big warning.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoconditional remove of libpq5 libpq-dev in Makefile
Jason Etheridge [Fri, 19 Aug 2011 16:20:19 +0000 (12:20 -0400)]
conditional remove of libpq5 libpq-dev in Makefile

In Makefile.install for the install_pgsql_client_debs_90 target.  Only
do it if version 8 of libpq-dev is installed.

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoWhen checking postgresql version use postgres db
Thomas Berezansky [Fri, 9 Sep 2011 14:25:10 +0000 (10:25 -0400)]
When checking postgresql version use postgres db

Otherwise we may get an error instead of a version number.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoTake a stab at 9.1 support
Thomas Berezansky [Thu, 8 Sep 2011 22:09:49 +0000 (18:09 -0400)]
Take a stab at 9.1 support

Second create database SQL to deal with
CREATE EXTENSION
instead of contrib files.

Check create DB steps for errors. If any found, die.
This should cover "could not load file" from pre-9.1 as well.

Also copied the 9.0 fts-config as 9.1 to avoid that warning during
database load.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoCorrect pg_config failure in eg_db_config.pl
Thomas Berezansky [Fri, 26 Aug 2011 17:56:21 +0000 (13:56 -0400)]
Correct pg_config failure in eg_db_config.pl

Missing a =s in getopts config means it becomes a 0 or 1, when it should
be a string.

The problem only occurs when you are specifying a particular postgresql
pg_config file (for example, if you have multiple versions of postgresql
installed).

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd --create-database option to eg_db_config.pl
Thomas Berezansky [Thu, 18 Aug 2011 16:06:46 +0000 (12:06 -0400)]
Add --create-database option to eg_db_config.pl

Uses create_database.sql and superuser rights to do all
database creation steps other than making a usable superuser
account to begin with.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoRemove references to Fedora 13 and 14
Dan Scott [Sat, 10 Sep 2011 16:36:14 +0000 (12:36 -0400)]
Remove references to Fedora 13 and 14

Fedora 13 has not been supported for months, Fedora 14 is about to lose
support. Simplifies README and prereq installer a bit.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoRefresh dynamic link cache after libjs install
Dan Scott [Sat, 10 Sep 2011 16:28:32 +0000 (12:28 -0400)]
Refresh dynamic link cache after libjs install

The build of SpiderMonkey can fail if it can't find the freshly
installed libjs library, so run ldconfig after building libjs to avoid
that bit o' fun.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoFix prerequisite install on Fedora 15
Dan Scott [Sat, 10 Sep 2011 16:27:41 +0000 (12:27 -0400)]
Fix prerequisite install on Fedora 15

The postgresql package shipped in Fedora proper is just called
'postgresql-devel', so get that right.

Also, try to put 64-bit libraries in the right directory.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoStamping upgrade for standing penalty fixes, and updating 2.0-2.1 upgrade script...
Mike Rylander [Fri, 9 Sep 2011 19:48:46 +0000 (15:48 -0400)]
Stamping upgrade for standing penalty fixes, and updating 2.0-2.1 upgrade script to match

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFix some standing penalty issues
Thomas Berezansky [Fri, 9 Sep 2011 18:31:27 +0000 (14:31 -0400)]
Fix some standing penalty issues

Circulations were using the circ matchpoint org unit for blocking.
That could, depending on the matchpoint that matched, result in staff
not being able to see the penalty that is being blocked for.

In addition, blocking is done based on the full path, not ancestors.
But, backend functions only used ancestors. Changed them to use the
full_path variant instead.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFix dos_print when NSPrint interface is used
Thomas Berezansky [Fri, 9 Sep 2011 19:23:09 +0000 (15:23 -0400)]
Fix dos_print when NSPrint interface is used

By adding params.dos_print = true where needed.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoCalculate penalties when marking items lost
Jason Etheridge [Thu, 8 Sep 2011 20:08:30 +0000 (16:08 -0400)]
Calculate penalties when marking items lost

For example, if you a max fines threshold of $10, and a lost processing fee of
$50, currently if you mark an item lost (or an item ages to lost) and a patron
gets billed that $50, they won't automatically have the max fines penalty.  This
change calculates such penalties at the time a copy is marked and lost and money
is juggled, within the same transaction.

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoA/T reactor 'AstCall' can't have global CStoreEditor
Lebbeous Fogle-Weekley [Wed, 7 Sep 2011 20:15:20 +0000 (16:15 -0400)]
A/T reactor 'AstCall' can't have global CStoreEditor

It's not good for any Evergreen service to try to have a global
cstoreeditor instance.  Scope it to the handler() sub that needs it, and
comment out the thus-far unused/unfinished retrieve() sub.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFix unified interface w/ editing multiple volumes
Jason Etheridge [Wed, 7 Sep 2011 07:29:40 +0000 (03:29 -0400)]
Fix unified interface w/ editing multiple volumes

Breakage if editing existing items across volumes with non-default values for
call number class, prefix, or suffix.  This was due to some logic happening
within a loop that was sadly referencing data that changed out from under it
with every loop iteration (so for example, we were effectively referencing the
last rendered class menu instead of each in turn).

Remember folks:

for (var unsafe = 0; unsafe < 10; unsafe++) {
    setTimeout(
        function(safe) {
            return function() {
                do_something_with(safe); // good
                do_something_with(unsafe); // bad
            };
        }(unsafe),
        1000
    );
}

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoLP#838311 acn_id = undefined error in vol/copy ui
Jason Etheridge [Wed, 7 Sep 2011 20:34:00 +0000 (16:34 -0400)]
LP#838311 acn_id = undefined error in vol/copy ui

Fixes race condition between multiple event listeners on drop-down menus.  Bug
happened most often when batch applying values across multiple volumes and then
hitting save/create/update.

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Resolved conflict:

Open-ILS/xul/staff_client/server/cat/volume_copy_creator.js

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoRemove "fallback to old style" UPDATE perm
Thomas Berezansky [Wed, 7 Sep 2011 17:39:32 +0000 (13:39 -0400)]
Remove "fallback to old style" UPDATE perm

The middle layer no longer supports the
UPDATE_ORG_UNIT_SETTING. + name
form of editing permissions. Don't use it as a fallback.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoLibrary Settings Editor: Use real perms
Thomas Berezansky [Tue, 30 Aug 2011 21:04:57 +0000 (17:04 -0400)]
Library Settings Editor: Use real perms

When update_perm exists use that permission, instead of a permission based
solely on the name of the permission.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoMake sure that title and author sorting data is available after a 2.0-2.1 upgrade
Mike Rylander [Wed, 7 Sep 2011 18:05:25 +0000 (14:05 -0400)]
Make sure that title and author sorting data is available after a 2.0-2.1 upgrade

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFix for LP bug #702422.
Jason Stephenson [Tue, 30 Aug 2011 17:05:16 +0000 (13:05 -0400)]
Fix for LP bug #702422.

Add @libdir@/javascript/ path in legacy script section of
oils_sip.xml.example so that legacy scripts work with SIP2.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoAdding org unit context selector to providers screen
James Fournie [Wed, 31 Aug 2011 17:37:21 +0000 (10:37 -0700)]
Adding org unit context selector to providers screen
This helps alleviate the bug reported in LP 731510 and
generally improves usability.

Signed-off-by: James Fournie <jfournie@sitka.bclibraries.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoClear org_unit cache fix for autogen.sh
Dan Wells [Tue, 6 Sep 2011 16:14:39 +0000 (12:14 -0400)]
Clear org_unit cache fix for autogen.sh

autogen.sh is not properly clearing the org_tree cache.  It is
unclear how this hasn't caused a problem before, but this fix
works for me and should be at least harmless in other enviroments.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoUpdate 2.0-2.1 upgrade script to work from 2.0.9
Mike Rylander [Tue, 6 Sep 2011 18:20:26 +0000 (14:20 -0400)]
Update 2.0-2.1 upgrade script to work from 2.0.9

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoPull in custom.js with offline/chrome overlays
Jason Etheridge [Tue, 6 Sep 2011 19:14:20 +0000 (15:14 -0400)]
Pull in custom.js with offline/chrome overlays

Or at least try to.  Main goal here is for browser.xul to see url constant
changes from custom.js and feed them to embedded Acquisition interfaces via
xulG.urls

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoRepaired field name thinko for config.record_attr_index_norm_map
Bill Erickson [Tue, 6 Sep 2011 15:28:00 +0000 (11:28 -0400)]
Repaired field name thinko for config.record_attr_index_norm_map

Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoHourly fine periods do not charge enough
Dan Wells [Thu, 1 Sep 2011 13:13:47 +0000 (09:13 -0400)]
Hourly fine periods do not charge enough

Hourly fine periods are not charging for the first period of
overdue-ness. If an item is due at 2:00pm and has a fine of
$.50 per hour, the first fine should be eligible for generation
at 2:01pm. As it stands, the first fine does not generate until
an entire fine period has elapsed, so in this case, 3:00pm.

The previous version of the code had a special case for day-
granular fine periods, so a majority of fines were not affected.
This commit expands the same idea (charging for the fine period
you are currently "in") to all fine periods.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoStamping upgrade script for LP#837566
Mike Rylander [Fri, 2 Sep 2011 16:09:27 +0000 (12:09 -0400)]
Stamping upgrade script for LP#837566

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoLP#837566 undeleting a bib record causes an error
Jason Etheridge [Fri, 2 Sep 2011 15:13:07 +0000 (11:13 -0400)]
LP#837566 undeleting a bib record causes an error

fixes a column reference

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agofix Acq -> Update Barcodes post-parts
Jason Etheridge [Fri, 2 Sep 2011 03:18:03 +0000 (23:18 -0400)]
fix Acq -> Update Barcodes post-parts

Items from acquisitions were having null instead of [] for .parts()

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoLP#838969 Silent print cannot be unselected
Jason Etheridge [Thu, 1 Sep 2011 18:06:53 +0000 (14:06 -0400)]
LP#838969 Silent print cannot be unselected

Thanks Bill!

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoLP#824257 Fix nasty overlapping when patron has more than 6 notes
Michael Peters [Thu, 11 Aug 2011 01:31:02 +0000 (21:31 -0400)]
LP#824257 Fix nasty overlapping when patron has more than 6 notes

Signed-off-by: Michael Peters <mrpeters@library.in.gov>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoPush phrases down to be subqueries, so they can be ORed together
Mike Rylander [Thu, 25 Aug 2011 19:56:15 +0000 (15:56 -0400)]
Push phrases down to be subqueries, so they can be ORed together

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoCorrect make target for lucid
Mike Rylander [Wed, 24 Aug 2011 19:24:24 +0000 (15:24 -0400)]
Correct make target for lucid

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoProtect against div-by-0 for negated words
Mike Rylander [Wed, 24 Aug 2011 18:36:54 +0000 (14:36 -0400)]
Protect against div-by-0 for negated words

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
13 years agoTrack count of dummy atoms and use a NULL tsquery when all dummy
Mike Rylander [Wed, 24 Aug 2011 17:44:04 +0000 (13:44 -0400)]
Track count of dummy atoms and use a NULL tsquery when all dummy

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
13 years agoUse unphrases in SQL generation
Mike Rylander [Wed, 24 Aug 2011 15:05:55 +0000 (11:05 -0400)]
Use unphrases in SQL generation

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
13 years agoadd "unphrases" to capture negated phrases ( -"foo bar" ) and make the negator config...
Mike Rylander [Wed, 24 Aug 2011 15:03:34 +0000 (11:03 -0400)]
add "unphrases" to capture negated phrases ( -"foo bar" ) and make the negator configurable

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
13 years agoIgnore empty atoms in query decomposition
Mike Rylander [Tue, 23 Aug 2011 19:03:56 +0000 (15:03 -0400)]
Ignore empty atoms in query decomposition

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
13 years ago2.[01]-stamped upgrade script for LP#816131
Mike Rylander [Tue, 23 Aug 2011 18:34:55 +0000 (14:34 -0400)]
2.[01]-stamped upgrade script for LP#816131

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoReverse direction of org_unit_ancestors
Thomas Berezansky [Mon, 22 Aug 2011 18:44:17 +0000 (14:44 -0400)]
Reverse direction of org_unit_ancestors

Apparently callers expect it to start at the top of the org tree.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoUnwrapped upgrade script for oua_force_order
Thomas Berezansky [Thu, 11 Aug 2011 13:36:36 +0000 (09:36 -0400)]
Unwrapped upgrade script for oua_force_order

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoNew version of actor.org_unit_ancestors
Thomas Berezansky [Thu, 11 Aug 2011 13:35:18 +0000 (09:35 -0400)]
New version of actor.org_unit_ancestors

Preserves order through joins

Basically actor.org_unit_ancestors_distance with a join to get the
entire org units, rather than just IDs and a distance.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFixed seaching for a colon (:) surrounded by white space
Liam Whalen [Thu, 11 Aug 2011 18:36:19 +0000 (14:36 -0400)]
Fixed seaching for a colon (:) surrounded by white space

When searching for a colon surrounded by white space the search would
freeze.  An example of such a search would be:
Climate change economics and policy : an RFF anthology
This was happening because the decompose function within QueryParser.pm
Would build a regular expression that would search the query for both
classes and class aliases e.g (keyword and kw).  However, when buliding
the regex for aliases QueryParser would add extraneous or symbols (|)
to the end of the regex without adding the accompanying alias.
This was happening because there was a check to see if the corresponding
class to each alias had already been added to the regex.  But, the
check to see if the alias had already been appened to the regex happened
too late.  I have moved the check to encopase the appending of the or
symbols and the class.
Signed-off-by: Liam Whalen <lwhalen@evergreen-dev.catalogue.nrcan.gc.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoBranchify patch for LP bug #802523 for rel_2_1.
Jason Stephenson [Tue, 9 Aug 2011 17:45:45 +0000 (13:45 -0400)]
Branchify patch for LP bug #802523 for rel_2_1.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFix penalty generation during billing creation
Jason Etheridge [Fri, 19 Aug 2011 22:22:28 +0000 (18:22 -0400)]
Fix penalty generation during billing creation

by passing the editor object referencing the database transaction to xact_org

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFurther upgrade script cleanup: address hold matrix DDL/DML ordering; use code instea...
Mike Rylander [Mon, 22 Aug 2011 16:47:34 +0000 (12:47 -0400)]
Further upgrade script cleanup: address hold matrix DDL/DML ordering; use code instead of id for permission addition; include recent updates for lasso visiblity

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoDisplay only available formats for metarecord holds in IE
Lebbeous Fogle-Weekley [Mon, 22 Aug 2011 14:37:30 +0000 (10:37 -0400)]
Display only available formats for metarecord holds in IE

The OPAC's usual hideMe()/unHideMe() tricks don't work for <option>
elements in Internet Explorer 8.  Use the disabled attribute.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoAddressing some more upgrade script issues spotted by Ben Shum
Mike Rylander [Fri, 19 Aug 2011 20:04:01 +0000 (16:04 -0400)]
Addressing some more upgrade script issues spotted by Ben Shum

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoAddressing upgrade script issues spotted by Robert Soulliere in LP#828032
Mike Rylander [Fri, 19 Aug 2011 19:22:14 +0000 (15:22 -0400)]
Addressing upgrade script issues spotted by Robert Soulliere in LP#828032

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoVandelay: repair item attr context org selector
Bill Erickson [Fri, 19 Aug 2011 19:50:22 +0000 (15:50 -0400)]
Vandelay: repair item attr context org selector

1. Prevents resetting the context selector to the workstation org unit
each time it's changed.

2. Prevent the unintentional pileup of dojo.connect() events, which
can lead to exponential growth in the number of server calls to fetch
import-item-attribute-definitions with each change of the context org
selector.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years ago#LP801961, error when running edi_fetcher.pl
Ben Shum [Tue, 2 Aug 2011 15:15:57 +0000 (11:15 -0400)]
#LP801961, error when running edi_fetcher.pl

This patch addresses an error encountered when running edi_fetcher.pl.
The method "is_dir" should be just plain "dir" in RemoteAccount.pm file.
Signed-off-by: Ben Shum <bshum@biblio.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoBranchify second patch from James Fournie on LP bug #791941.
Jason Stephenson [Tue, 9 Aug 2011 19:46:30 +0000 (15:46 -0400)]
Branchify second patch from James Fournie on LP bug #791941.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoBranchify first patch from James Fournie on LP bug #791941.
Jason Stephenson [Tue, 9 Aug 2011 19:45:38 +0000 (15:45 -0400)]
Branchify first patch from James Fournie on LP bug #791941.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoBranchify patch from LP bug #809478 and forward port to rel 2.1.
Robert Soulliere [Tue, 9 Aug 2011 19:15:08 +0000 (15:15 -0400)]
Branchify patch from LP bug #809478 and forward port to rel 2.1.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoImprove Vandelay Import/Merge Checkbox Labels
Dan Wells [Tue, 16 Aug 2011 15:22:36 +0000 (11:22 -0400)]
Improve Vandelay Import/Merge Checkbox Labels

Since these labels are used both for the initial import and also
for imports from the queue, the use of the word "Auto" can be
confusing and misleading.  This commit reflects changes already
made in trunk for these labels.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoFix importing of 'No Match' records from a queue
Dan Wells [Tue, 16 Aug 2011 15:03:16 +0000 (11:03 -0400)]
Fix importing of 'No Match' records from a queue

This small change honors the 'No Match' checkbox when importing
from a queue.

This bug has existed for a while, but was only recently exposed
by 06e4d3370068002a303c9a5a03448ee0e1249fc0.  Before that commit,
no-match records always imported, even when you didn't want them.
After that commit, they import when wanted on the initial load,
but could not be imported from the queue.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoStricter order for actor.org_unit_parent_protect()
Dan Wells [Tue, 16 Aug 2011 21:22:47 +0000 (17:22 -0400)]
Stricter order for actor.org_unit_parent_protect()

actor.org_unit_parent_protect() may not work due to the fact
that 'IF' conditions in PL/pgSQL are not necessarily processed
in the order written. This line:

"IF TG_OP = 'INSERT' OR NEW.parent_ou
IS DISTINCT FROM OLD.parent_ou THEN"

may fail because the 'IS DISTINCT FROM' happens before the
'INSERT' check, and and that fails because there is no 'OLD'
variable for INSERTs.

This commit may not be the optimal style for this circumstance
in this language, but it works.  It also appears to change more
than it really does due to a loss of one level of indentation in
the structure.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoWhitespace Only Changes
Dan Wells [Tue, 16 Aug 2011 21:16:35 +0000 (17:16 -0400)]
Whitespace Only Changes

Files uses primarily tabs, function used both spaces and tabs.
It now uses all tabs.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoLP 799719: Pass the DESTDIR variable to python installer
Dan Scott [Tue, 16 Aug 2011 15:50:45 +0000 (11:50 -0400)]
LP 799719: Pass the DESTDIR variable to python installer

Based on Ben Webb's patch, but using the same triple-slash to avoid any
possibility of confusion about the installation location (see also the
same adjustment made to OpenSRF).

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoStamped upgrade scripts for LP#790329
Mike Rylander [Tue, 16 Aug 2011 15:14:58 +0000 (11:14 -0400)]
Stamped upgrade scripts for LP#790329

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoLP#790329 org_lasso search is broken
Dan Scott [Thu, 28 Jul 2011 18:29:48 +0000 (14:29 -0400)]
LP#790329 org_lasso search is broken

Fix the JavaScript error when we attempt to create a feed for the
shortname of the org_unit_lasso (lassos have no shortname) - which lets
the request hit the backend Perl module, which in turn chokes on a test
for OU that only allows two conditions: either all digits is treated as
a numeric ID for an org unit, or it is a shortname. Of course, lassos
are negative integers, so we have to modify the test slightly to make it
happier.

There was no depth for org lasso copy counts, and this was handled
correctly in the main case by the asset.opac_lasso_record_copy_count()
function and its staff variant, but when a copy was not found at a given
org_unit in the lasso a request was made for the non-existent depth and
the function would error out.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoPlaceholder for 2.0-only LP#790329 fix
Mike Rylander [Tue, 16 Aug 2011 15:08:02 +0000 (11:08 -0400)]
Placeholder for 2.0-only LP#790329 fix

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoKeep the logging output of the EDI translator by default
Lebbeous Fogle-Weekley [Tue, 16 Aug 2011 13:10:45 +0000 (09:10 -0400)]
Keep the logging output of the EDI translator by default

There is valuable troubleshooting information there that is otherwise hard to
find.  This particularly matters when the output of an EDI
Action/Trigger template (JEDI) doesn't successfully get translated to
EDIFACT for nonobvious reasons.

In production environments, you might instead pipe to logger so that you can
collect output with syslog, rather than in a flat file.  As long as
output goes *somewhere.*

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoLP#820409 fix org unit admin UI
Jason Etheridge [Mon, 15 Aug 2011 19:34:07 +0000 (15:34 -0400)]
LP#820409 fix org unit admin UI

This reverts part of 17e659eec3e23caf5d301b33aa5019b672ecd0e8, which was
tightening checks against null and '' to avoid implicit type-casting.

This line var modified_ou = new aou().fromStoreItem( current_ou ); was
producing a fieldmapper object where certain fields were being set to
contain the string "undefined" rather than a null.

The update method would take isdeleted == "undefined" as True.

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoStamped upgrades for LP#825303
Mike Rylander [Tue, 16 Aug 2011 13:04:09 +0000 (09:04 -0400)]
Stamped upgrades for LP#825303

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoreturn only the one applicable OU setting value
Galen Charlton [Fri, 12 Aug 2011 20:09:11 +0000 (16:09 -0400)]
return only the one applicable OU setting value

Correct actor.org_unit_ancestor_setting so that it returns
at most one setting value, rather than the entire set
 of values defined for the OU and its ancestors.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agolp#825303: fix cat.default_classification_scheme lookup
Galen Charlton [Fri, 12 Aug 2011 16:18:54 +0000 (12:18 -0400)]
lp#825303: fix cat.default_classification_scheme lookup

Fixes a bug where the wrong default classification scheme
could be chosen when adding a new volume whose classification
scheme was not explicitly set.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoUpgrade script (based on 2.0.8, currently)
Mike Rylander [Sat, 13 Aug 2011 01:31:39 +0000 (21:31 -0400)]
Upgrade script (based on 2.0.8, currently)

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoStamped upgrade script for "lp 823496: do not fail to index personal names that have...
Mike Rylander [Sat, 13 Aug 2011 01:13:20 +0000 (21:13 -0400)]
Stamped upgrade script for "lp 823496: do not fail to index personal names that have relators"

Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agolp 823496: don't fail to index personal names that have relators
Galen Charlton [Tue, 9 Aug 2011 19:30:56 +0000 (15:30 -0400)]
lp 823496: don't fail to index personal names that have relators

The default definition for the author|other index inadvertantly
excluded names from 600, 700, 720, and 800 fields that have
relator values ($e) or codes ($4).

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoDon't escape_html numbers in util/print.js
Thomas Berezansky [Fri, 12 Aug 2011 19:47:25 +0000 (15:47 -0400)]
Don't escape_html numbers in util/print.js

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
13 years agoEscape HTML characters in template subs
Thomas Berezansky [Thu, 11 Aug 2011 01:37:54 +0000 (21:37 -0400)]
Escape HTML characters in template subs

This prevents injection of random HTML from various sources.

Like bad bib records, org unit settings, patron info, etc.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>