contrib/Conifer.git
13 years agoTowards a periodic OpenSRF-speaking LDAP patron sync script
Dan Scott [Tue, 6 Sep 2011 20:16:51 +0000 (16:16 -0400)]
Towards a periodic OpenSRF-speaking LDAP patron sync script

Still need to factor out the mapping of LDAP schema to Evergreen
attributes further but patience, patience.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoWhat we _actually_ ran for the first load of student data
Dan Scott [Fri, 2 Sep 2011 12:54:19 +0000 (08:54 -0400)]
What we _actually_ ran for the first load of student data

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd lulStudentLevel filter for students
Dan Scott [Fri, 2 Sep 2011 01:34:54 +0000 (21:34 -0400)]
Add lulStudentLevel filter for students

Prefer lulStudentLevel to distinguish between undergrad and grad
students.

Left-pad, with zeroes, Colleague IDs that are shorter than 7 digits.

Don't update names from LDAP as they appear to lack Unicode support.

Sundry small pylint fixes.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoIt's nice when a script actually runs
Dan Scott [Thu, 1 Sep 2011 18:06:04 +0000 (14:06 -0400)]
It's nice when a script actually runs

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAvoid generating barcodes that are already in the database
Dan Scott [Thu, 1 Sep 2011 18:03:54 +0000 (14:03 -0400)]
Avoid generating barcodes that are already in the database

And complain when we get a colleague ID that is not the expected size.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoPush errors to STDERR consistently
Dan Scott [Thu, 1 Sep 2011 16:58:07 +0000 (12:58 -0400)]
Push errors to STDERR consistently

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoClean up LDAP synchronization tool further
Dan Scott [Thu, 1 Sep 2011 16:51:04 +0000 (12:51 -0400)]
Clean up LDAP synchronization tool further

A few syntax errors here, a few logic errors there... that's what we
have test servers for.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd email address into COPY input
Dan Scott [Thu, 1 Sep 2011 04:34:25 +0000 (00:34 -0400)]
Add email address into COPY input

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoFix filter error, improve key existence test
Dan Scott [Wed, 31 Aug 2011 20:42:39 +0000 (16:42 -0400)]
Fix filter error, improve key existence test

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoBreak barcode generator into smaller pieces
Dan Scott [Wed, 31 Aug 2011 20:08:48 +0000 (16:08 -0400)]
Break barcode generator into smaller pieces

This should make it easier to expose evergreen.lu_generate_barcode() for
manual purposes (e.g. for creating a new user on the fly in the Register
Patron UI).

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoProgress on the LDAP patron loading script
Dan Scott [Wed, 31 Aug 2011 19:54:42 +0000 (15:54 -0400)]
Progress on the LDAP patron loading script

Many functions defined and individually tested, still need to put this
together in working order.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoProgress towards reality - generating staging table inserts
Dan Scott [Wed, 31 Aug 2011 13:29:48 +0000 (09:29 -0400)]
Progress towards reality - generating staging table inserts

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoLU loaded T&F content onto ebrary, thus no CRKN T&F for them
Dan Scott [Thu, 25 Aug 2011 21:04:23 +0000 (17:04 -0400)]
LU loaded T&F content onto ebrary, thus no CRKN T&F for them

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd a script for quickly checking for encoding errors
Dan Scott [Wed, 24 Aug 2011 17:00:16 +0000 (13:00 -0400)]
Add a script for quickly checking for encoding errors

Also update the ldap_sync script to be more grown-up.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoWay too little LDAP code
Dan Scott [Mon, 22 Aug 2011 20:22:33 +0000 (16:22 -0400)]
Way too little LDAP code

Signed-off-by: Dan Scott <dan@coffeecode.net>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoLaurentian _does_ have T&F - just not on ScholarsPortal for now
Dan Scott [Fri, 19 Aug 2011 18:10:46 +0000 (14:10 -0400)]
Laurentian _does_ have T&F - just not on ScholarsPortal for now

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAutomate the CRKN processing with a little script
Dan Scott [Mon, 15 Aug 2011 17:03:24 +0000 (13:03 -0400)]
Automate the CRKN processing with a little script

Parallelized via ( &) for your convenience.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoEnsure fixed fields are correct and avoid bad public notes
Dan Scott [Fri, 12 Aug 2011 15:52:45 +0000 (11:52 -0400)]
Ensure fixed fields are correct and avoid bad public notes

One more iteration based on the UWin team's set of feedback on the
hopefully penultimate processing round for the CRKN records.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd a few more T&F data uncorruption fixes
Dan Scott [Thu, 11 Aug 2011 20:45:45 +0000 (16:45 -0400)]
Add a few more T&F data uncorruption fixes

Note that we're now seeing conflicting patterns, so some
legitimate characters are getting corrupted by the script,
while others could go either way (l stroke vs modifier prime).
As long as the fix rate is 95%+ then I'm happy.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAnd append the ' ; ' to 506 $b as well
Dan Scott [Thu, 11 Aug 2011 16:24:50 +0000 (12:24 -0400)]
And append the ' ; ' to 506 $b as well

In our refactoring, we messed up the 506 $b. Sigh.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoFor the Oxford vs. Cambridge thing, add periods
Dan Scott [Thu, 11 Aug 2011 16:02:20 +0000 (12:02 -0400)]
For the Oxford vs. Cambridge thing, add periods

We lost consistency due to the sorting out of the combined CUP & OUP
MARC records in that the hard-coded publisher names did not end with a
period.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoBe more consistent when applying the period to 710 $a
Dan Scott [Thu, 11 Aug 2011 15:38:42 +0000 (11:38 -0400)]
Be more consistent when applying the period to 710 $a

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoRefine based on feedback from Windsor
Dan Scott [Thu, 11 Aug 2011 15:25:33 +0000 (11:25 -0400)]
Refine based on feedback from Windsor

1) 506 $a and $b both need to end with ' ; '; try to make this happen
   even if the command line is screwed up.

2) Ensure the incoming 710 $a ends with a period.

Also, do not generate a 506 for Algoma if publisher == Cambridge

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd more carons, based on outliers from CRKN_OUP
Dan Scott [Tue, 2 Aug 2011 20:38:03 +0000 (16:38 -0400)]
Add more carons, based on outliers from CRKN_OUP

Note that in at least one case, this would result in MUSICA becoming
MSICA. Sigh. Finally the conflicts arrive.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoCorrect I BREVE for Mr. Sakharov
Dan Scott [Tue, 2 Aug 2011 19:44:36 +0000 (15:44 -0400)]
Correct I BREVE for Mr. Sakharov

We were adding an extra i to the composed I BREVE chars.

Also log diffs so we can eyeball the changes and know that they are
good.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoReplace C with acute accent as well
Dan Scott [Fri, 29 Jul 2011 21:54:08 +0000 (17:54 -0400)]
Replace C with acute accent as well

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoMore search and replace operations
Dan Scott [Fri, 29 Jul 2011 19:49:10 +0000 (15:49 -0400)]
More search and replace operations

S cedilla, combining ligatures, modifier letter prime

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoUse composed breves, add combining dot above
Dan Scott [Fri, 29 Jul 2011 18:34:42 +0000 (14:34 -0400)]
Use composed breves, add combining dot above

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoR CARON is another good one
Dan Scott [Fri, 29 Jul 2011 18:19:30 +0000 (14:19 -0400)]
R CARON is another good one

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoS with combining acute accent (lower and uppercase)
Dan Scott [Fri, 29 Jul 2011 18:11:05 +0000 (14:11 -0400)]
S with combining acute accent (lower and uppercase)

We can use the composed codepoint for these instead of going the
decomposed route, for more accuracy and great justice.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoApply the modified letter half ring throughout
Dan Scott [Fri, 29 Jul 2011 17:54:05 +0000 (13:54 -0400)]
Apply the modified letter half ring throughout

Looks like it can be an inplace modification, so let's do it.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoCombining breve for Mr. Sakharov
Dan Scott [Fri, 29 Jul 2011 17:50:08 +0000 (13:50 -0400)]
Combining breve for Mr. Sakharov

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoIterating through CRKN_OUP.mrc for more corruption to fix
Dan Scott [Fri, 29 Jul 2011 17:21:30 +0000 (13:21 -0400)]
Iterating through CRKN_OUP.mrc for more corruption to fix

Tildes, accute accents, cedillas, we got em all.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoBegin addressing the specific manglings of the CRKN records
Dan Scott [Fri, 29 Jul 2011 15:58:36 +0000 (11:58 -0400)]
Begin addressing the specific manglings of the CRKN records

To begin with, correct the mangled macrons and modifier letter half ring
that are popular in the Arabic language. Here's hoping that correcting
these byte sequences doesn't lead to corruption elsewhere.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoReuse an existing 040 if possible
Dan Scott [Thu, 28 Jul 2011 20:41:09 +0000 (16:41 -0400)]
Reuse an existing 040 if possible

The switcharound left us still appending the 040 to the new record,
which had no fields, rather than amending the existing 040 on the
incoming record.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoSupport optional --platform argument
Dan Scott [Thu, 28 Jul 2011 16:19:20 +0000 (12:19 -0400)]
Support optional --platform argument

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoRevert inadvertent damage caused by last commit
Dan Scott [Thu, 28 Jul 2011 15:53:27 +0000 (11:53 -0400)]
Revert inadvertent damage caused by last commit

Two different copies of the Conifer repo = damage!

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoCheck for 020$z, 024$a,$z for ISBNs
Dan Scott [Thu, 28 Jul 2011 15:16:42 +0000 (11:16 -0400)]
Check for 020$z, 024$a,$z for ISBNs

Either our MARC record sources are horribly corrupted, or the SFX
knowledge base is questionable, or both, as we're having to search
cancelled/invalid/non-ISBNs to get matches in SFX for our electronic
records.

Also, use 506 $9 to record our institutional ID in authorization notes.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoRefine the 506 $3 punctuation decision
Dan Scott [Wed, 20 Jul 2011 19:23:32 +0000 (15:23 -0400)]
Refine the 506 $3 punctuation decision

From Graham Staffen:

My definitive answer (until I develop a revised definitive answer) is
that a period would always punctuate the end of the subfield except in
two instances: 1) a closing parenthesis, 2) a closing square bracket. I
have this from our MARC coding trainer who could think of no other
instances when a period is not employed.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoInclude an ISBN in the error log if available
Dan Scott [Wed, 20 Jul 2011 16:10:21 +0000 (12:10 -0400)]
Include an ISBN in the error log if available

This should help with identifying problem records.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoInclude record count in 598 $c, conditional . in 506 $e
Dan Scott [Wed, 20 Jul 2011 14:28:30 +0000 (10:28 -0400)]
Include record count in 598 $c, conditional . in 506 $e

We might as well include the record offset in the 598 so that we can
track which record includes a given problem.

Also, according to Shuzhen, we only want to add a period at the end of
the 506 $e subfield in particular cases (like when it ends in a letter
or number; not with punctuation).

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoFinal (?) tweaks for ebook processing
Dan Scott [Fri, 15 Jul 2011 21:20:27 +0000 (17:20 -0400)]
Final (?) tweaks for ebook processing

  * 506 punctuation
  * Enable Algoma to not have 856s in Cambridge records
  * Add the --platform option (although we might not use it)

Dan Scott <dscott@laurentian.ca>

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd 598 field to track MARC file source
Dan Scott [Thu, 14 Jul 2011 21:27:02 +0000 (17:27 -0400)]
Add 598 field to track MARC file source

Also shift 506 institutional code to subfield 9 despite the MARC
standard suggesting that it should be in subfield 5.

Also add semicolons to the 506 fields for better display. Still
need to add spaces, though.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoChange link text for Windsor to "Available online"
Dan Scott [Thu, 23 Jun 2011 17:51:19 +0000 (13:51 -0400)]
Change link text for Windsor to "Available online"

Per proposal #1 of the June 22, 2011 Conifer ebook specification
document, Windsor wanted to change their link text to the simpler
"Available online". Making it so.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoCheck for a hit in SFX for every library we have enabled
Dan Scott [Wed, 22 Jun 2011 18:50:08 +0000 (14:50 -0400)]
Check for a hit in SFX for every library we have enabled

It's possible that one of the libraries has not yet turned on a given
target in SFX, so we don't want any false negatives. And if a library
hasn't opted into a particular package, they shouldn't be one of the
enabled flags passed to this script.

Also, clean up ISBN marking and access note creation, as we were
modifying the wrong MARC record.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoImplement ISBN lookup in SFX
Dan Scott [Wed, 22 Jun 2011 16:04:10 +0000 (12:04 -0400)]
Implement ISBN lookup in SFX

Check the SFX knowledgebase for a matching ISBN and mark it via the
magical $9 SFX subfield so that we can key off of that for subsequent
queries via the catalogue.

Given that only one library may be running this script for a set of
ebook records, ensure that we're checking the results.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoOn closer inspection, 506$e != 710$a
Dan Scott [Wed, 22 Jun 2011 14:16:55 +0000 (10:16 -0400)]
On closer inspection, 506$e != 710$a

The 710 is being used for the imprint, while the 506$e is being used to
identify the online platform.

It's questionable whether this should be required - for example, a 506
wouldn't be necessary for Project Gutenberg materials - but let's go
with that for now anyway.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd 506 note handling per Windsor proposal
Dan Scott [Wed, 22 Jun 2011 14:01:31 +0000 (10:01 -0400)]
Add 506 note handling per Windsor proposal

The 506 note is for access restrictions; we will generate one 506 field
per instutition, with a customized $a message, the consortial license
identified in the $b, and the publisher in $e, along with the library
symbol in $5 to enable the catalogue to control the display of the
message in an appropriate scope.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd Conifer's laundry list of tools and scripts
Dan Scott [Mon, 6 Jun 2011 15:33:57 +0000 (11:33 -0400)]
Add Conifer's laundry list of tools and scripts

Again, in the interest of expediency, get the Conifer tools into a
branch, we can factor them out further later.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoMake it possible to suppress IDL fields
Mike Rylander [Wed, 10 Oct 2012 21:36:52 +0000 (17:36 -0400)]
Make it possible to suppress IDL fields

Some clients of external services, particularly pcrud and reporter-store,
need to be able to access tables that contain columns we'd rather restrict.
For instance, the passwd field on actor.usr.

To effect this feature we provide a blacklist attribute for fields, called
suppress_controller, which works in the same way as the class controller
attribute but names controllers not allowed to use the field.  When the field
is explicitly named in a query (fieldmapper select block or json_query) an
error is thrown, and suppressed fields are ingored in general fieldmapper
search/retreive requests.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoCStoreEditor auto-activity log redaction
Bill Erickson [Fri, 2 Nov 2012 19:28:27 +0000 (15:28 -0400)]
CStoreEditor auto-activity log redaction

CStoreEditor logs all update calls to the activity log as key/value
pairs on the updated object.  Avoid loging key/value pairs for objects
when the API call being relayed by CStoreEditor is on the list of
log-protect API calls.  Instead, log "**DETAILS REDACTED**".

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAdd sample log redaction config to EG opensrf_core
Bill Erickson [Wed, 31 Oct 2012 13:00:19 +0000 (09:00 -0400)]
Add sample log redaction config to EG opensrf_core

Redact parameter logging for the following API calls:

Login:
open-ils.auth.authenticate.verify
open-ils.auth.authenticate.complete
open-ils.auth_proxy.login

User updates:
open-ils.actor.user.password
open-ils.actor.user.username
open-ils.actor.user.email
open-ils.actor.patron.update
open-ils.cstore.direct.actor.user.create
open-ils.cstore.direct.actor.user.update
open-ils.cstore.direct.actor.user.delete

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoCan't use README for version, so use configure.ac
Thomas Berezansky [Tue, 19 Jun 2012 16:23:09 +0000 (12:23 -0400)]
Can't use README for version, so use configure.ac

Because one good "this works for now" being broken can be replaced with
another one easily.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoBump README for 2.1.3a release
Dan Scott [Thu, 13 Sep 2012 17:08:52 +0000 (13:08 -0400)]
Bump README for 2.1.3a release

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agorel_2_1 does not have a config.upgrade_log.applied_to column
Dan Scott [Thu, 13 Sep 2012 16:47:32 +0000 (12:47 -0400)]
rel_2_1 does not have a config.upgrade_log.applied_to column

Thanks to Michael Peters for running into & reporting this problem when
attempting to upgrade from 2.1.2 to 2.1.3!

Fix the version upgrade script.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agorel_2_1 does not have a config.upgrade_log.applied_to column
Dan Scott [Thu, 13 Sep 2012 16:46:23 +0000 (12:46 -0400)]
rel_2_1 does not have a config.upgrade_log.applied_to column

Thanks to Michael Peters for running into & reporting this problem when
attempting to upgrade from 2.1.2 to 2.1.3!

Fix the base scripts and schema creation.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoBumping version numbers and adding Changelog
Dan Scott [Wed, 22 Aug 2012 18:09:45 +0000 (14:09 -0400)]
Bumping version numbers and adding Changelog

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoChanged the thawing of a hold to first update the hold record and then re-target.
Steven Callender [Tue, 10 Jul 2012 19:43:59 +0000 (15:43 -0400)]
Changed the thawing of a hold to first update the hold record and then re-target.

When thawing a hold, originaly we were first re-targeting before actually saving the hold record. On items with large quantities, sometimes the hold would timeout on targetig before getting a chance to actually save. This patch moves things around to first save the hold record before attempting to retarget.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoAdd 2.1.2-2.1.3 database schema upgrade script
Dan Scott [Thu, 23 Aug 2012 13:43:18 +0000 (09:43 -0400)]
Add 2.1.2-2.1.3 database schema upgrade script

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoHide OPAC-invisible holdings from SRU/Z39.50
Dan Scott [Mon, 16 Jul 2012 17:27:54 +0000 (13:27 -0400)]
Hide OPAC-invisible holdings from SRU/Z39.50

The basic_holdings Supercat method filtered out deleted call numbers and
copies, but didn't filter out copies based on the OPAC visibility status
of copy location / status / the copy itself. This has undesired results
when third-party services request copies via SRU or Z39.50 and expose
copies that should not be visible to the public.

We wrap all of the visibility and deletedness checks for a given copy up
into a subroutine so that we can avoid repeating ourselves in the
basic_holdings logic. Also, if we missed a test, we can add it in one
handy place :)

(Thanks to Galen Charlton for finding two missing tests: circ lib
visibility and owning lib visibility!)

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Art Rhyno <art632000@yahoo.ca>
13 years agoChange grammar for lost and missing failure messages
Melissa Lefebvre [Tue, 14 Aug 2012 16:58:18 +0000 (12:58 -0400)]
Change grammar for lost and missing failure messages

Update to the lost and missing failure wording to make it
gramatically correct.  Removed the word "has" from both
messages.

Signed-off-by: Melissa Lefebvre <mlefebvre@biblio.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoFix LP 829630, Show in Catalogue not working on Bills screen
Steven Chan [Sun, 8 Jul 2012 18:20:11 +0000 (11:20 -0700)]
Fix LP 829630, Show in Catalogue not working on Bills screen

The page is looking for a messagecatalog XUL element with id
'catStrings', but is not finding it, and so we add it to the relevant
XUL file.

It's odd why it is omitted, because a browse through the repository
doesn't show any changes that would explain the error.

Signed-off-by: James Fournie <jfournie@sitka.bclibraries.ca>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoUse MARC::Field objects to append new fields
Dan Scott [Fri, 27 Jul 2012 20:27:29 +0000 (16:27 -0400)]
Use MARC::Field objects to append new fields

While the deprecated MARC::Record::add_fields() method allows you to add
a list of fields using a list object, append_fields() requires
MARC::Field objects.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Conflicts:
Open-ILS/src/sql/Pg/002.schema.config.sql

13 years agolp1028514: fix syntax-o in PL/PERLU version of maintain_901()
Galen Charlton [Fri, 27 Jul 2012 15:23:46 +0000 (11:23 -0400)]
lp1028514: fix syntax-o in PL/PERLU version of maintain_901()

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
Conflicts:
Open-ILS/src/sql/Pg/002.schema.config.sql

13 years agoSwitch to a PLPERLU maintain_901() trigger function
Dan Scott [Tue, 24 Jul 2012 18:14:01 +0000 (14:14 -0400)]
Switch to a PLPERLU maintain_901() trigger function

We've been burned by regexes that fail to grok XML properly numerous
times now. Standardizing on something that actually understands MARC
seems like a good idea.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agolp1028514: fix regex replace in maintain_901()
Galen Charlton [Tue, 24 Jul 2012 15:51:52 +0000 (11:51 -0400)]
lp1028514: fix regex replace in maintain_901()

The regex used to insert the 901 field can put the new
field in the wrong location if the MARCXML record being
modified uses namespace prefixes.  This patch tightens
the regexp to avoid this problem.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agopatron name border color for Notes
Jason Etheridge [Mon, 18 Jun 2012 18:09:51 +0000 (14:09 -0400)]
patron name border color for Notes

not Notes specifically, but this catches any non-alert non-blocking penalties
and prevents a colorless border from happening

Colors chosen from mrpeters' patch at
https://bugs.launchpad.net/evergreen/+bug/921817

Thanks!

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Conflicts:

Open-ILS/xul/staff_client/server/skin/patron_display.css

13 years agoAdd constraint to ACQ PO state value
Bill Erickson [Wed, 23 Nov 2011 15:54:51 +0000 (10:54 -0500)]
Add constraint to ACQ PO state value

Limit 'state' values to

'new','pending','on-order','received','cancelled'

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

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoMove Prefix field ahead of Names in patron editor
Ben Shum [Wed, 27 Jun 2012 18:01:24 +0000 (14:01 -0400)]
Move Prefix field ahead of Names in patron editor

In earlier versions of Evergreen (1.6 and earlier), the Prefix field
was used to enter title information, such as Mr., Mrs., etc. When the
field was eventually added to the newer patron registration screens
(2.0+), it was added before the patron's last name field. Ideally,
the prefix should be listed prior to the patron's first name instead.

In addition, address label issues by changing "Suffix/Title" back to
only "Suffix" and making "Prefix" into "Prefix/Title".

Note: string changes would normally not be allowed in a stable release,
however in this case the previous translation (if any) will still get
pulled from the IDL for the field in question, so English will not
suddenly start showing up in the patron registration form.

Signed-off-by: Ben Shum <bshum@biblio.org>
Signed-off-by: James Fournie <jfournie@sitka.bclibraries.ca>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoSquelch uninitialized var warning from hold_copy_targeter
Bill Erickson [Mon, 16 Jul 2012 20:56:10 +0000 (16:56 -0400)]
Squelch uninitialized var warning from hold_copy_targeter

open-ils.storage_stderr.log was getting filled with entries like:

"Use of uninitialized value in concatenation (.) or string at
/usr/local/share/perl/5.10.1/OpenILS/Application/Storage/Publisher/action.pm"

... consuming disk space endlessly. Stop that!

(Stealing Lebbeous' footwork and providing a slightly different solution.)

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoSecurity fix: For auth, give same stacktrace for all cases of LOGIN_FAILED
Lebbeous Fogle-Weekley [Tue, 12 Jun 2012 21:26:39 +0000 (17:26 -0400)]
Security fix: For auth, give same stacktrace for all cases of LOGIN_FAILED

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoSecurity fix: Prevent login by deleted and barred users
Lebbeous Fogle-Weekley [Mon, 11 Jun 2012 18:16:34 +0000 (14:16 -0400)]
Security fix: Prevent login by deleted and barred users

An existing comment in the code suggested that we thought we were already
keeping barred users out.  LP #1010671 brings up that deleted users were
not being kept out.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoSecurity fix for Launchpad Bug 1003052.
Jason Stephenson [Mon, 11 Jun 2012 20:12:54 +0000 (16:12 -0400)]
Security fix for Launchpad Bug 1003052.

Bug reported by James Fournie:

Revoking the UPDATE_MARC permission doesn't actually seem to prevent a
user from editing a record. Our use case is that we would like a user
to create new records but not edit existing MARC records.

Changing CREATE_MARC to UPDATE_MARC in OpenILS::Application::Cat's
biblio_record_replace_marc() method seems to fix the problem.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoFix in-transit hold retarget
Thomas Berezansky [Wed, 13 Jun 2012 14:12:05 +0000 (10:12 -0400)]
Fix in-transit hold retarget

Tell the abort transit function to not commit our editor on us, basically.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agofix double-click in Holdings Maintenance
Jason Etheridge [Fri, 20 Apr 2012 02:37:56 +0000 (22:37 -0400)]
fix double-click in Holdings Maintenance

so that it won't attempt to spawn the Item Editor for non-items

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoLP1009752: activate purchase orders with patron requests
James Fournie [Wed, 6 Jun 2012 21:47:30 +0000 (14:47 -0700)]
LP1009752: activate purchase orders with patron requests

Simple typo: "actor_hold_request" should be "action_hold_request".

Signed-off-by: Dan Scott <dan@coffeecode.net>
13 years agoUpdate 2.1.2 DB schema upgrade script
Dan Scott [Thu, 7 Jun 2012 03:19:10 +0000 (23:19 -0400)]
Update 2.1.2 DB schema upgrade script

As part of the march to 2.1.2, and in time for 2.2.0, update the
2.1.1-2.1.2 update script.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoMove 2.0.11 upgrade script into version_upgrade dir
Dan Scott [Tue, 5 Jun 2012 13:17:52 +0000 (09:17 -0400)]
Move 2.0.11 upgrade script into version_upgrade dir

Signed-off-by: Dan Scott <dan@coffeecode.net>
13 years agoAdd the 2.0.10-2.0.11 upgrade script.
Jason Stephenson [Thu, 10 May 2012 17:56:41 +0000 (13:56 -0400)]
Add the 2.0.10-2.0.11 upgrade script.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Dan Scott <dan@coffeecode.net>
13 years agoDistinguish route-to-cataloging exception circ messages
Dan Scott [Sun, 3 Jun 2012 00:06:30 +0000 (20:06 -0400)]
Distinguish route-to-cataloging exception circ messages

It appears as though a copy-and-paste error introduced duplicate keys in
circ.properties, which in turn makes newer versions of the Translate
Toolkit unhappy and results in empty translated files. Tracing through
the pertinent code in xul/staff_client/server/circ/util.js, it looks
like the desired key was for "not_found" for the second "cataloging" key
- so change that accordingly.

Signed-off-by: Dan Scott <dan@coffeecode.net>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoFix check for duplicate strings in i18n properties
Dan Scott [Sat, 2 Jun 2012 23:51:55 +0000 (19:51 -0400)]
Fix check for duplicate strings in i18n properties

We had the core of the check in place - just failed to check the
property we were iterating over. Doh.

Signed-off-by: Dan Scott <dan@coffeecode.net>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoClean up and refine serial note support, part 1
Dan Wells [Tue, 17 Apr 2012 21:34:06 +0000 (17:34 -0400)]
Clean up and refine serial note support, part 1

This commit fixes a number of minor problems with serial notes:

1) Serial notes are currently returned in "random" (database)
order.  Adding a create_date sort is a sensible default.

2) If you have many notes, they start to display in a squashed and
unreadable fashion.  Switching from a groupbox to a styled vbox
provides a simple workaround.

3) It is currently impossible to display newlines in notes.  We can
deal with this by changing the display style.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Dan Scott <dan@coffeecode.net>
13 years agoLimit excess serial data fetching
Dan Wells [Tue, 17 Apr 2012 20:02:49 +0000 (16:02 -0400)]
Limit excess serial data fetching

Overfetching and duplication of data in the interface is both
inefficient and bug-inducing.  This reduces a couple big offenders.

First, in the items tab, we will store distribution and subscription
data separately, rather than duplicating for every row.  Second, we
will only redraw rows as needed rather than refresh the whole list so
often.  Finally, we no longer need to lookup call numbers separately,
as they are included in the one-time distribution fetch.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Dan Scott <dan@coffeecode.net>
13 years agoLP975422 patron search from portal/splash page
Jason Etheridge [Wed, 9 May 2012 14:30:17 +0000 (10:30 -0400)]
LP975422 patron search from portal/splash page

make it consider the "Patron circulation summary is horizontal" library setting

Signed-off-by: Jason Etheridge <jason@esilibrary.com>
Signed-off-by: Dan Scott <dan@coffeecode.net>
13 years agoACQ guarantee no PO re-activation
Bill Erickson [Fri, 23 Mar 2012 19:17:50 +0000 (15:17 -0400)]
ACQ guarantee no PO re-activation

Prevent the possibility of double PO activation by preventing it within
the API.  There have been reports in the wild of double-activation, even
though the UI is supposed to prevent it.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Michael Peters <mrpeters@library.in.gov>
Signed-off-by: Dan Scott <dan@coffeecode.net>
Conflicts:
Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Order.pm

13 years agolp#1007248: tweak order in which pgt rows are renumbered
Galen Charlton [Fri, 1 Jun 2012 03:31:11 +0000 (23:31 -0400)]
lp#1007248: tweak order in which pgt rows are renumbered

Need to renumber from highest to lowest.  Because the primary
key constraint is not deferred, doing the renumbering in a single
statement will fail if there is overlap between the set of
existing pgt.id values and the set of {pgt.id + 100}.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
13 years agoLP#856708 - Scrolling/div size issues in action trigger interface
Jeff Davis [Wed, 11 Apr 2012 16:04:19 +0000 (12:04 -0400)]
LP#856708 - Scrolling/div size issues in action trigger interface

The event definition content pane does not properly accommodate its contents.
In the Event Definitions tab, the list of event definitions exceeds the height of the
pane, but you can't scroll all the way down to the bottom of the list -- some of the
content gets cut off. Likewise, when editing an event definition, you can't scroll
all the way to the bottom of the page; the Cancel and Save buttons are cut off, and
you have to use the Tab key to move the focus down to those buttons, which forces
the pane to scroll to the bottom so that they're visible.

Signed-off-by: Jeff Davis <jdavis@sitka.bclibraries.ca>
Signed-off-by: Michael Peters <mrpeters@library.in.gov>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoAdd missing weights fm_IDL entries
Thomas Berezansky [Wed, 18 Apr 2012 16:05:20 +0000 (12:05 -0400)]
Add missing weights fm_IDL entries

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoCheck if transaction needs closing after adding billings
Bill Erickson [Fri, 4 May 2012 13:18:10 +0000 (09:18 -0400)]
Check if transaction needs closing after adding billings

This addresses the issue where issuing refunds results in a negative
ballance and it is then impossible to close the transaction by creating
new billings.

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

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
13 years agoThrow out non-digit barcodes for strict check
Thomas Berezansky [Thu, 22 Sep 2011 13:24:56 +0000 (09:24 -0400)]
Throw out non-digit barcodes for strict check

Characters like "." are valid for numbers, but not the algorithm.

Thus, we need to throw out "16.00" despite the check for
"16.00" == Number("16.00")
returning true.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoDon't check barcode without strict enabled
Thomas Berezansky [Thu, 22 Sep 2011 13:16:31 +0000 (09:16 -0400)]
Don't check barcode without strict enabled

Item status was, unlike other interfaces, doing the strict check, THEN
looking at the checkbox and if it was checked return.

This caused issues when the barcode crashes out the strict checking.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoInstall RPC::XML::Function on Ubuntu Lucid.
Jason Stephenson [Mon, 23 Jan 2012 16:49:07 +0000 (11:49 -0500)]
Install RPC::XML::Function on Ubuntu Lucid.

Change the LUCID_CPAN target to install RPC::XML::Function instead of
XML::RPC.

Based on public bug report by Ben Shum (LP 920535).

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agolp996776: Patch to fix the response if no configured status is detected.
Steven Callender [Tue, 8 May 2012 21:15:14 +0000 (17:15 -0400)]
lp996776: Patch to fix the response if no configured status is detected.

SIP response messages that use circulation_status where defaulting to just 1
rather than 01 if the status was not detected. Since SIP needs a 2 character
response, this was causing issues in some 3rd party devices. Added quoting
around the 01 to force the 2 characters.

Signed-off-by: Steven Callender <stevecallender@esilibrary.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
13 years agoSmall fix to Holding Code wizard widget
Dan Wells [Mon, 26 Mar 2012 20:17:03 +0000 (16:17 -0400)]
Small fix to Holding Code wizard widget

The issuance editor has a wizard widget for the holding code field
which expected a 'grid' as an argument, but then referenced a global
'iss_grid' variable.  This hurt reusability of this widget.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoSerial Control: Refresh node map on edit
Dan Wells [Mon, 26 Mar 2012 20:07:58 +0000 (16:07 -0400)]
Serial Control: Refresh node map on edit

While it would be nice to redraw any affected tree nodes when
editing, we should at least replace the map data in case it is
used in other functions.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoAllow subscriptions at org units without volumes
Dan Wells [Wed, 25 Apr 2012 19:56:20 +0000 (15:56 -0400)]
Allow subscriptions at org units without volumes

Subscriptions are sometimes owned at the consortium or system
level, so forcing can_have_vols() to be true was incorrect.

This commit removes those checks.  In addition, we also remove
some dead code and make the subscription org unit selector
consistent with the distribution org unit selector.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
13 years agoAdd indexes to 2.1.2 upgrade script to speed up acq search
Dan Scott [Thu, 3 May 2012 20:44:14 +0000 (16:44 -0400)]
Add indexes to 2.1.2 upgrade script to speed up acq search

Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoAcq: General Search refactor
Lebbeous Fogle-Weekley [Tue, 14 Feb 2012 22:49:54 +0000 (17:49 -0500)]
Acq: General Search refactor

This is a combination of the following three commits from master:

3149433d354889fb
56121886c72b2d41
35fe5b9cbe10b132

The first two were meant for backport to rel_2_0 and rel_2_1 at the
time, but the backport wasn't done.  They were buggy anyway, and now it
makes the most sense (I hope) to backport them together with the
corrective commit all at once.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
13 years agoFix LP 984039: correct Syndetic Kirkus Reviews
Jeff Godin [Tue, 17 Apr 2012 14:46:22 +0000 (10:46 -0400)]
Fix LP 984039: correct Syndetic Kirkus Reviews

Use correct "filename" component of URL for retrieving Kirkus
Reviews content from Syndetic Solutions.

Correct filename confirmed by Bowker technical support, and by
empirical tests.

Signed-off-by: Jeff Godin <jgodin@tadl.org>
Signed-off-by: Michael Peters <mrpeters@library.in.gov>
13 years agoFix some "null" instead of blank values in JSPac
Thomas Berezansky [Tue, 3 Apr 2012 18:45:10 +0000 (14:45 -0400)]
Fix some "null" instead of blank values in JSPac

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Michael Peters <mrpeters@library.in.gov>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>