]> git.evergreen-ils.org Git - contrib/Conifer.git/log
contrib/Conifer.git
7 years agoFallback to lulAffiliation for affiliation feature/tools/patron_load_2_4
Dan Scott [Wed, 14 Sep 2016 17:53:30 +0000 (13:53 -0400)]
Fallback to lulAffiliation for affiliation

Because some older (2011ish) LDAP accounts don't have
lulPrimaryAffiliation attributes.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
9 years agoWS and style cleanup
Dan Scott [Thu, 11 Sep 2014 02:33:49 +0000 (22:33 -0400)]
WS and style cleanup

Signed-off-by: Dan Scott <dscott@laurentian.ca>
9 years agoConvert usernames to lowercase
Dan Scott [Thu, 11 Sep 2014 02:31:52 +0000 (22:31 -0400)]
Convert usernames to lowercase

As our LDAP authentication is using all lowercase, we should
be generating accounts in the database in all lowercase too.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoAdjust ldap_osrf_sync for generic BC generation
Dan Scott [Thu, 10 Jan 2013 22:10:44 +0000 (17:10 -0500)]
Adjust ldap_osrf_sync for generic BC generation

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoLDAP: Create and push barcodes from Web UI
Dan Scott [Mon, 16 Jul 2012 16:24:44 +0000 (12:24 -0400)]
LDAP: Create and push barcodes from Web UI

Now that we're beyond basic testing, go ahead and create accounts or
push barcodes into LDAP for realz.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoEnsure we only generate unique barcodes
Dan Scott [Fri, 13 Jul 2012 15:20:15 +0000 (11:20 -0400)]
Ensure we only generate unique barcodes

Rather than looping over existing barcodes only when we update the
patron account, let's not return duplicate barcodes in the first place,
mmmkay?

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoPrep for use in mod_wsgi
Dan Scott [Wed, 11 Jul 2012 13:46:10 +0000 (09:46 -0400)]
Prep for use in mod_wsgi

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoUse synchronous methods and cleaner results
Dan Scott [Wed, 11 Jul 2012 01:20:41 +0000 (21:20 -0400)]
Use synchronous methods and cleaner results

Rather than calling ldap.result(), which results in awkward lists of
lists which are hard to handle, just iterate over the results from
ldap.search_s() (which, btw, is now a synchronous call).

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoRevert debug code that showed all LDAP attributes
Dan Scott [Tue, 10 Jul 2012 20:48:21 +0000 (16:48 -0400)]
Revert debug code that showed all LDAP attributes

Not that I mind verbosity, but unless you request the custom attributes
specifically, you only get the default LDAP attributes. And I'm more
interested in the custom ones.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoExperimental web.py frontend for creating Conifer accounts
Dan Scott [Tue, 10 Jul 2012 20:25:42 +0000 (16:25 -0400)]
Experimental web.py frontend for creating Conifer accounts

Use web.py to surface a simple Web UI for generating Conifer accounts
based on the Laurentian ID of a given user. Required a little
refactoring of ldap_osrf_sync to make it usable as a module rather than
just as a script, but that's all for the better.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoFully-qualified CN is not a good basis for email addresses
Dan Scott [Thu, 2 Feb 2012 20:09:00 +0000 (15:09 -0500)]
Fully-qualified CN is not a good basis for email addresses

Not unless you really like cn=Foo,ou=Bar@foobar.ca as an email address,
anyway.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoGenerate email addresses where none are in LDAP
Dan Scott [Tue, 24 Jan 2012 21:32:31 +0000 (16:32 -0500)]
Generate email addresses where none are in LDAP

Per discussion with MLaferriere, we should expect to see LDAP entries
without a 'mail' attribute, and should build email addresses based on
the CN. For additional flourish, append @laurentian.ca or
@laurentienne.ca based on the language preference.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoLDAP sync: If EG user found, reactivate
Dan Scott [Mon, 16 Jan 2012 22:53:27 +0000 (17:53 -0500)]
LDAP sync: If EG user found, reactivate

In theory, we won't be asked to create a user that already exists in
Evergreen if they are already there and active. So, go ahead and set the
"active" flag to true and update the account expiry date when we are
asked to create an existing user.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoMore robust identity value handling for LDAP tooling
Dan Scott [Tue, 10 Jan 2012 19:00:16 +0000 (14:00 -0500)]
More robust identity value handling for LDAP tooling

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoAdjust to new values of permission groups in 2.1
Dan Scott [Tue, 10 Jan 2012 18:47:06 +0000 (13:47 -0500)]
Adjust to new values of permission groups in 2.1

We shifted the permission group IDs when we upgraded to 2.1 and have to
compensate accordingly in this hard-coded script.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoLDAP: More robust processing and error reporting
Dan Scott [Mon, 5 Dec 2011 16:44:30 +0000 (11:44 -0500)]
LDAP: More robust processing and error reporting

Don't die if we don't have an lulColleagueId; spit out the attributes
that we have ready at hand to help identify the problem record.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoHandle "thornloe" profile
Dan Scott [Fri, 7 Oct 2011 17:21:55 +0000 (13:21 -0400)]
Handle "thornloe" profile

Apparently our LDAP system or a system upon which it depends is either
enforcing an 8-char limit for some reason, or we have to deal with
typos. Whatever.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoLDAP patron load: map "thornloe" to staff
Dan Scott [Fri, 7 Oct 2011 17:19:43 +0000 (13:19 -0400)]
LDAP patron load: map "thornloe" to staff

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoLDAP patron load: handle more errors more gracefully
Dan Scott [Fri, 7 Oct 2011 17:16:09 +0000 (13:16 -0400)]
LDAP patron load: handle more errors more gracefully

It's possible for users in LDAP to not have email; instead of absolutely
dying, just warn and move on to the next user.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoDon't update the barcode if user was not created
Dan Scott [Wed, 14 Sep 2011 20:47:38 +0000 (16:47 -0400)]
Don't update the barcode if user was not created

Check the return value and bail if the user creation was a failure.
For large updates, one can use --create and --push to update barcodes
for users who already exist.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoUse the new opt_in_override method to search for users
Dan Scott [Wed, 14 Sep 2011 20:03:08 +0000 (16:03 -0400)]
Use the new opt_in_override method to search for users

Now that we have the opt_in_override method, use it to find users who
might exist in any OU in the consortium, rather than just the
workstation OU.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoMore defensive error handling
Dan Scott [Wed, 14 Sep 2011 19:00:18 +0000 (15:00 -0400)]
More defensive error handling

When users aren't opted-in, we can't search for them. Fiddlesticks! This
was breaking the script rather annoyingly; now we print out an error and
move on to the next user.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoCorrect a dangling reference to a raw variable
Dan Scott [Wed, 14 Sep 2011 16:33:10 +0000 (12:33 -0400)]
Correct a dangling reference to a raw variable

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoPass User objects rather than raw vars
Dan Scott [Wed, 14 Sep 2011 15:56:09 +0000 (11:56 -0400)]
Pass User objects rather than raw vars

Also strip out functions that are not used in this script relating to
the creation of barcodes.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoHandle new 'Proxy' lulAffiliation a bit more gracefully
Dan Scott [Mon, 12 Sep 2011 21:27:46 +0000 (17:27 -0400)]
Handle new 'Proxy' lulAffiliation a bit more gracefully

In general, if we don't have an explicit profile, just return.

Signed-off-by: Dan Scott <dan@coffeecode.net>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoNew --push-barcode option updates LDAP with Evergreen barcodes
Dan Scott [Fri, 9 Sep 2011 04:45:30 +0000 (00:45 -0400)]
New --push-barcode option updates LDAP with Evergreen barcodes

By default, the --create-users option will update LDAP with the new
barcode that was generated for the new users.

One can also use a --query of some type and pass --push-barcode to
retrieve the barcodes for all of the LDAP users from Evergreen and then
push those barcodes into their respective LDAP accounts.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoGenerate barcodes and push them into LDAP
Dan Scott [Tue, 7 May 2013 18:48:51 +0000 (14:48 -0400)]
Generate barcodes and push them into LDAP

Call the new custom API to open-ils.actor for generating barcodes;
accepts one argument, user ID, which gets the barcode set to their new
value. If no arg is passed, just generates a new barcode and returns it
(should be useful on the patron editor screen).

As far as pushing the barcodes into LDAP goes, I can't confirm that the
updates are actually working, because I can't see them, but the lack of
errors suggests that it's working.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoCommand line options for queries and actions
Dan Scott [Thu, 8 Sep 2011 15:35:31 +0000 (11:35 -0400)]
Command line options for queries and actions

Use the argparse module to enable override of user/password/hostname
options at the command line, as well as to enable different types of
queries (for example, via LDAP cn / sn / id / createTimestamp) and
enable particular actions (display the LDAP data and/or create new users
in Evergreen).

Much better than manually editing the script each time.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoGetting LDAP synchronization production ready
Dan Scott [Wed, 7 Sep 2011 15:34:04 +0000 (11:34 -0400)]
Getting LDAP synchronization production ready

* Search for user before attempting to create the user
* Set the default expiry date by profile
* Document how we're currently populating barcodes

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoGet working OpenSRF integration, genericize a bit
Dan Scott [Wed, 7 Sep 2011 07:12:56 +0000 (03:12 -0400)]
Get working OpenSRF integration, genericize a bit

Still need to teach the beast how to provision barcodes, then write
those back to LDAP as well. Pushing the LDAP mapping into the User class
init method seems like a reasonable way to genericize this a bit; sites
could replace the User class implementation.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 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>
10 years agoImport initial student data loading script
Dan Scott [Wed, 8 May 2013 13:45:41 +0000 (09:45 -0400)]
Import initial student data loading script

Signed-off-by: Dan Scott <dscott@laurentian.ca>
10 years agoAdd params support to show in opac function
Thomas Berezansky [Sun, 7 Oct 2012 15:58:37 +0000 (11:58 -0400)]
Add params support to show in opac function

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Ben Shum <bshum@biblio.org>
10 years agoLP#1175287: make sure tsearch2 is removed, regardless of its origin
Galen Charlton [Wed, 1 May 2013 20:33:39 +0000 (16:33 -0400)]
LP#1175287: make sure tsearch2 is removed, regardless of its origin

A sufficiently old Evergreen database might still have tsearch2
exist as an unpackaged contrib, so convert it to an extension first.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
10 years agoadjust release notes references to refer to 2.4.0
Galen Charlton [Wed, 1 May 2013 21:35:30 +0000 (17:35 -0400)]
adjust release notes references to refer to 2.4.0

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
10 years agoupdate upgrade instructions for 2.4.0 release
Galen Charlton [Wed, 1 May 2013 21:34:02 +0000 (17:34 -0400)]
update upgrade instructions for 2.4.0 release

- specify minimum supported PostgreSQL version as 9.1
- specify minimum supported OpenSRF version as 2.2.0
- update schema upgrade instructions and miscellaneous
  references to 2.3

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
10 years agorevisions to installation instructions
Galen Charlton [Wed, 1 May 2013 21:02:57 +0000 (17:02 -0400)]
revisions to installation instructions

- Remove references to PostgreSQL 9.0; 9.1 is recommended
  for Evergreen 2.4.
- Clarify that the latest version of OpenSRF now means 2.2
  or later.
- Increase chances that somebody following the instructions
  precisely doesn't run into a problem during the configure step.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
10 years agoMake sure the "running" indicator goes away
Mike Rylander [Tue, 30 Apr 2013 15:26:00 +0000 (11:26 -0400)]
Make sure the "running" indicator goes away

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
10 years agoAdd a $cache_timeout-based backstop for infinite loops
Mike Rylander [Fri, 26 Apr 2013 15:28:38 +0000 (11:28 -0400)]
Add a $cache_timeout-based backstop for infinite loops

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
10 years ago"Queue Compression" -- let one do the work for all identical, concurrent searches
Mike Rylander [Fri, 26 Apr 2013 14:49:17 +0000 (10:49 -0400)]
"Queue Compression" -- let one do the work for all identical, concurrent searches

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jason Etheridge <jason@esilibrary.com>
10 years agoLP#1174359: follow-up on dropping the reporter.classic_item_list view
Galen Charlton [Wed, 1 May 2013 19:01:30 +0000 (15:01 -0400)]
LP#1174359: follow-up on dropping the reporter.classic_item_list view

Add note for the benefit of any Evergreen admin who may
need to recreate that view.  Also, update the point schema
update script.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
10 years agoLP#1174359 Need to drop reporter.classic_item_list
Michael Peters [Mon, 29 Apr 2013 15:14:39 +0000 (11:14 -0400)]
LP#1174359 Need to drop reporter.classic_item_list

ERROR: cannot drop view metabib.full_rec because other objects depend on it
DETAIL: view reporter.classic_item_list depends on view metabib.full_rec
HINT: Use DROP ... CASCADE to drop the dependent objects too.

Beginning at line 55 of the upgrade script, several views and functions are dropped
so metabib.full_rec can be dropped. One of them is missing.

We need to drop reporter.classic_item_list as well, for the script to work.

Signed-off-by: Michael Peters <mpeters@emeralddata.net>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
10 years agoImproved AC socket fix
Jason Stephenson [Wed, 1 May 2013 16:08:29 +0000 (12:08 -0400)]
Improved AC socket fix

This provides better coverage for socket shutdown needs, but intends
to fix the same issue as the previous commit.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
10 years agoShutdown added content sockets to prevent hung connections.
Jason Stephenson [Tue, 30 Apr 2013 17:23:24 +0000 (13:23 -0400)]
Shutdown added content sockets to prevent hung connections.

We were getting several thousand sockets hanging around in a
CLOSE_WAIT state on our server.  The connections were from our
server and to our server.  Further investigation showed it to be
caused by the stage2 added content lookup not closing the request
sockets when it was done reading data.  This branch fixes that.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
10 years agoLP1076411 Return updated circ object from checkin
Bill Erickson [Fri, 29 Mar 2013 13:41:44 +0000 (09:41 -0400)]
LP1076411 Return updated circ object from checkin

Retrieve an updated copy of the circulation object to return to the
caller during checkin.  This ensures the data in the circ object, in
particular date fields, are consistent with the database.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
10 years agoWhen adding errors from failed processing to acq.edi_message, set error_time
Lebbeous Fogle-Weekley [Wed, 3 Apr 2013 19:31:09 +0000 (15:31 -0400)]
When adding errors from failed processing to acq.edi_message, set error_time

This has obvious benefits in facilitating log analysis after a problem.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
10 years agoAdd accepting_usr to IDL to fix reporter field
Remington Steed [Thu, 14 Mar 2013 18:37:17 +0000 (14:37 -0400)]
Add accepting_usr to IDL to fix reporter field

In the reporter interface, the view 'Payments: Brick-and-mortar' is
missing the 'Accepting User' field, which is present in the similar view
'Payments: Desk'. This field is already present in the database view and
is simply missing from the IDL.  Since it is needed for certain kinds of
reports, this commit adds the missing IDL fields. It also adds the
missing 'reporter:datatype' to an existing instance of the IDL field.

Signed-off-by: Remington Steed <rjs7@calvin.edu>
Signed-off-by: Ben Shum <bshum@biblio.org>
10 years agoLP1170861 Remove unused lineitem alert field
Bill Erickson [Tue, 23 Apr 2013 15:47:37 +0000 (11:47 -0400)]
LP1170861 Remove unused lineitem alert field

Remove extraneous field from the IDL field list for acq lineitem alerts.
The extra field prevented new alerts from getting saved.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Signed-off-by: Ben Shum <bshum@biblio.org>
10 years agoLP1104823 - OPAC search results "Limit to available items" toggles
Kyle Tomita [Tue, 9 Apr 2013 20:51:14 +0000 (13:51 -0700)]
LP1104823 - OPAC search results "Limit to available items" toggles
off "Show more details"

Added a hidden input to the form when "Show more details" is selected
so that when the form is reloaded, "Show more details" will be still
selected.

Signed-off-by: Kyle Tomita <ktomita@catalystitservices.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
10 years agoLP#1172893: fix query for retrieving available holds
Bill Erickson [Thu, 25 Apr 2013 15:54:40 +0000 (11:54 -0400)]
LP#1172893: fix query for retrieving available holds

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
11 years agoAdd 2.4 release notes for Novelist Select changes.
Jason Stephenson [Tue, 23 Apr 2013 14:39:55 +0000 (10:39 -0400)]
Add 2.4 release notes for Novelist Select changes.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
11 years agoAdding 2.3-2.4RC upgrade script
Mike Rylander [Mon, 22 Apr 2013 19:04:07 +0000 (15:04 -0400)]
Adding 2.3-2.4RC upgrade script

Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoUnbreak make install for apache config files
Dan Scott [Mon, 22 Apr 2013 17:00:05 +0000 (13:00 -0400)]
Unbreak make install for apache config files

The new install process installs the Apache sample configs into the
DOCDIR for Evergreen, with the expectation that packagers will pick up
the examples from the doc directory and that users will eventually be
expected to copy them from there, rather than from the source tree.

However, currently the Apache 2.2 and 2.4 sample configs have the same
names, and that causes a conflict at "make install" time. Kudos to Jason
Stephenson for catching this. The temporary solution is to rename the
Apache 2.4 files to avoid the conflict; longer term, we need to teach
make install to only make & install the files that are pertinent to the
environment on which it was built (either Apache 2.2, or Apache 2.4).

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
11 years agoUpdating PO files from LaunchPad
Mike Rylander [Mon, 22 Apr 2013 14:17:46 +0000 (10:17 -0400)]
Updating PO files from LaunchPad

Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoFix version number in 0793.data.best-hold-order-traditional-approx.sql
Jason Stephenson [Sat, 20 Apr 2013 13:49:27 +0000 (09:49 -0400)]
Fix version number in 0793.data.best-hold-order-traditional-approx.sql

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Ben Shum <bshum@biblio.org>
11 years agoAdd missing [% in prefs_settings.tt2.
Jason Stephenson [Sat, 20 Apr 2013 13:28:37 +0000 (09:28 -0400)]
Add missing [% in prefs_settings.tt2.

Signed-off-by: Jason Stephenson <jason@sigio.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
11 years agoLP#1162907: install RPC::XML as Evergreen dependency
Galen Charlton [Fri, 5 Apr 2013 03:45:14 +0000 (23:45 -0400)]
LP#1162907: install RPC::XML as Evergreen dependency

RPC::XML used to be installed as part of installing
the OpenSRF deps, but since OpenSRF itself doesn't
use it, this belongs in Evergreen.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoRepair too-timid hold targeter (it misses copies at other org units)
Lebbeous Fogle-Weekley [Fri, 19 Apr 2013 19:23:05 +0000 (15:23 -0400)]
Repair too-timid hold targeter (it misses copies at other org units)

The patch to address bug 1162989 overreached.  Whereas before that
patch, the hold targeter was wont to target copies with unholdable
statuses, after the patch the hold targeter got the statuses right but
undesirably filtered out copies whose circ_lib doesn't match the hold
pickup lib.  This again probably stems from the differences between
FulfILLment's hold targeter and Evergreen's in the context of merging
the calculated proximity code.

This patch should resolve the issue.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoStamping best-hold-order update script
Mike Rylander [Fri, 19 Apr 2013 20:19:11 +0000 (16:19 -0400)]
Stamping best-hold-order update script

Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoFix various Traditional and holds-go-home best-hold sort orders
Lebbeous Fogle-Weekley [Wed, 3 Apr 2013 20:35:51 +0000 (16:35 -0400)]
Fix various Traditional and holds-go-home best-hold sort orders

Use copy's call number's owning_lib instead of copy's circ_lib

    Should compare checkin lib to copy's (call number's) owning_lib, not
    hold request lib.

    You might think the comparison should be to acp.circ_lib, but that
    doesn't work with floating copies (for non-floaters, acp.circ_lib
    should be equal to acp.call_number.owning_lib).

approx is a more correct first determinant to give the behavior sites
are used to.

    hprox can cause copies to be too eager to go home when
    there are holds with that copy's circ lib as its request lib (if that's
    what you want, then you do pick or create a sort-order with hprox near
    the top).

Address a problem in the copy_has_not_been_home CTE.
    This expression was always meant to provide a TRUE or FALSE value as its
    lone result, but would return NULL in cases where copies had no transit
    history.

Use pickup_lib, not request_lib, as the determinant of
    nearness-to-home.  request_lib was used with the thinking that an item's
    "owning" patrons should have their wishes favored at holds-go-home time,
    even if where they wanted to send the copy was not actually home, but
    that's neither necessarily desired nor very intuitive.

Clear up holds-go-home logic with better code AND add TechRef
documentation with diagram in attempt to be as clear as possible.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoConfirm URL_VERIFY_UPDATE_SETTINGS permission code is fixed
Mike Rylander [Fri, 19 Apr 2013 15:45:32 +0000 (11:45 -0400)]
Confirm URL_VERIFY_UPDATE_SETTINGS permission code is fixed

Jeff Davis spotted, and fixed, a problem with upgrade script 0754. If
someone has already applied that, this will address.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoUse correct perm code in upgrade scripts for SQL update 0754
Jeff Davis [Thu, 18 Apr 2013 23:09:40 +0000 (16:09 -0700)]
Use correct perm code in upgrade scripts for SQL update 0754

Signed-off-by: Jeff Davis <jdavis@sitka.bclibraries.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoMerge changes to Apache 2.4 example config files
Dan Scott [Fri, 19 Apr 2013 15:06:27 +0000 (11:06 -0400)]
Merge changes to Apache 2.4 example config files

Not only do we need the JSPAC->TPAC changes that went into the base
Apache example configs, we should also move to generating these files
instead of having hardcoded values. Longer term, we should probably just
generate the right example configs from one common base until Apache 2.2
is dead and gone, but this improves the Apache 2.4 experience greatly.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoStamping upgrade for #deleted search modifier (and friends) fix
Mike Rylander [Thu, 18 Apr 2013 19:45:15 +0000 (15:45 -0400)]
Stamping upgrade for #deleted search modifier (and friends) fix

Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoQP: Repair edit_date, create_date, and bib_source filters
Lebbeous Fogle-Weekley [Wed, 17 Apr 2013 22:16:09 +0000 (18:16 -0400)]
QP: Repair edit_date, create_date, and bib_source filters

And also make records undeletable, where reingestion at undelete time
formerly balked in this manner:

> ERROR: duplicate key value violates unique constraint
> "record_attr_pkey" DETAIL: Key (id)=(1) already exists. CONTEXT: SQL
> statement "INSERT INTO metabib.record_attr (id, attrs) VALUES (NEW.id,
> new_attrs)" PL/pgSQL function "indexing_ingest_or_delete" line 129 at
> SQL statement

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoQP: Limit to deleted records for #deleted modifier at this level
Lebbeous Fogle-Weekley [Wed, 17 Apr 2013 21:24:59 +0000 (17:24 -0400)]
QP: Limit to deleted records for #deleted modifier at this level

Down in the DB's query_parser_fts procedure, we also know whether we're
in a deleted_search, and in those cases we skip all visibility and
similar testing accordingly.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoBring back #deleted modifier post-revive-qp-fts
Mike Rylander [Fri, 5 Apr 2013 20:46:21 +0000 (16:46 -0400)]
Bring back #deleted modifier post-revive-qp-fts

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoTPAC schema.org: Add Organization types for contributors
Dan Scott [Sun, 7 Apr 2013 22:14:58 +0000 (18:14 -0400)]
TPAC schema.org: Add Organization types for contributors

Given a 110 / 710 field, when generating the record details for authors
and contributors we can declare an http://schema.org/Organization
itemtype rather than just jamming the name under the "contributor"
property. This is more in accordance with schema.org directions.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoTPAC: Fix schema.org name / dates for authors
Dan Scott [Fri, 5 Apr 2013 20:10:01 +0000 (16:10 -0400)]
TPAC: Fix schema.org name / dates for authors

Per http://schema.org/Person, the birth date and death date are not
supposed to be part of the name of a Person. We can separate these out
correctly based on subfield d for 100 fields.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoFix schema.org mapping for MusicAlbum, add Map
Dan Scott [Fri, 5 Apr 2013 17:21:47 +0000 (13:21 -0400)]
Fix schema.org mapping for MusicAlbum, add Map

We had set LDR[06] = j to MusicRecording, but that is really meant for
individual songs. Use MusicAlbum instead, and per
http://schema.org/MusicAlbum, use a new MusicGroup itemtype with a
'byArtist' property for the primary artist rather than the generic
'accountablePerson'.

Also map LDR[06] = e to Map, because that seems like a safe bet.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoStamping upgrade script for optional combined search by class
Ben Shum [Thu, 18 Apr 2013 17:45:54 +0000 (13:45 -0400)]
Stamping upgrade script for optional combined search by class

Signed-off-by: Ben Shum <bshum@biblio.org>
11 years agoAllow combined search to be optional per class
Mike Rylander [Tue, 16 Apr 2013 19:08:10 +0000 (15:08 -0400)]
Allow combined search to be optional per class

Relevance is thrown off for, in paticular, the keyword class when combined
search is used.  This is because the effect of an opaque blob of data, such
as the keyword|keyword index definition, is to applify the inclusion of spurious
(to the user) data in matching attempts.

This commit adds the ability to specify, per class, whether combined FTS should
be used, and turns this on for only the subject class by default.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
11 years agoAcq: re-use more code for two ways of creating invoices (EDI and manual)
Lebbeous Fogle-Weekley [Wed, 20 Feb 2013 14:41:03 +0000 (09:41 -0500)]
Acq: re-use more code for two ways of creating invoices (EDI and manual)

This solves two problems.

 1) With EDI invoices, we had been failing to disencumber fund debits
    related to the invoiced lineitems, although that worked for manual
    invoices.
 2) With manual invoices, we would not automatically uncancel copies
    when the user decided to invoice them despite their canceled status.
    This was already working in EDI invoices though.  This is especially
    important since our schema lumps "backordered" in with "canceled,"
    and in theory backordered things do show up eventually.

There were earlier version of this commit out there with bugs that
prevented the EDI workflow from working correctly (the manual invoice
flow worked and still should).

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoApproximate number of search results
Kathy Lussier [Sun, 14 Apr 2013 04:38:53 +0000 (00:38 -0400)]
Approximate number of search results

The number of results listed on the search results page is often an
estimate when working with a large set. Let's add the word "about" to
reflect the fact that it is indeed an estimate.

At the same time, I moved the <strong> tags out of the code, adding a CSS
class in its place, moved the HTML tags out of the translatable
string (as recommended by Pasi Kallinen), and fixed a typo in the
stylesheet.

Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoMinor change to chrome/content/util/list.js.
Jason Stephenson [Thu, 18 Apr 2013 14:49:06 +0000 (10:49 -0400)]
Minor change to chrome/content/util/list.js.

Change the initializer of this.count_for_display from 0 to 1 in
order to match the counting of other lists in the client and to
provide something that staff are likely to prefer.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
11 years agoFixed bug in staff client offline mode.
Dmitry Nechai [Tue, 16 Apr 2013 21:33:57 +0000 (00:33 +0300)]
Fixed bug in staff client offline mode.

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

In list.js at start you create obj.columns for lineno, but later
you don`t process this value so it`s return default render
function.  This code repairs this.

Signed-off-by: Dmitry Nechai <nechai.dmitry@gmail.com>
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
11 years agoPrevent compiler warning about unused numtype var
Dan Scott [Fri, 5 Apr 2013 05:53:55 +0000 (01:53 -0400)]
Prevent compiler warning about unused numtype var

There was a dangling variable left around that was making noise in the
compiler. Credit to Jeff Godin for the heads-up.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years agoAddress SQL injection vulnerability in SQL ORM layer
Mike Rylander [Fri, 5 Apr 2013 05:52:16 +0000 (01:52 -0400)]
Address SQL injection vulnerability in SQL ORM layer

If the user-supplied value and the db column are both numbers
(jsonObject->type == JSON_NUMBER, get_primitive(field) == "number") then
don't quote. Otherwise, quote.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
11 years ago2.2.7-2.2.8 database upgrade script
Lebbeous Fogle-Weekley [Wed, 17 Apr 2013 02:24:07 +0000 (22:24 -0400)]
2.2.7-2.2.8 database upgrade script

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
11 years ago2.3.5 -> 2.3.6 SQL upgrade
Bill Erickson [Wed, 17 Apr 2013 19:47:59 +0000 (15:47 -0400)]
2.3.5 -> 2.3.6 SQL upgrade

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
11 years agoStamping upgrade script for reinstate tsconfigs.
Jason Stephenson [Wed, 17 Apr 2013 18:33:48 +0000 (14:33 -0400)]
Stamping upgrade script for reinstate tsconfigs.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
11 years agoReinstate required TEXT SEARCH CONFIGURATION data
Mike Rylander [Wed, 17 Apr 2013 18:04:11 +0000 (14:04 -0400)]
Reinstate required TEXT SEARCH CONFIGURATION data

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
11 years agoAddress hash/list thinko; Ensure initialization
Mike Rylander [Wed, 17 Apr 2013 16:08:41 +0000 (12:08 -0400)]
Address hash/list thinko; Ensure initialization

Two cascading defects were identified after being reported by users. The
first, which was only a potential issue, was an apparent lack of mod_perl
initialization for the item-age record feed.  While not the direct cause
of the error message, a lack of initialization here would manifest in the
same way.  So, we check that initialization.

Feed-generating callbacks were not being constructed properly due to a
simple thinko in the construction of the default record format list provided
by the SuperCat backend.  We need a list of two hashes, not a hash of two
keys.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
11 years agoTPAC bucket item retrieval operates in streaming mode
Bill Erickson [Tue, 9 Apr 2013 17:45:24 +0000 (13:45 -0400)]
TPAC bucket item retrieval operates in streaming mode

TPAC bucket item retreive fleshes bib records with large blobs of MARC
data.  When a bucket contains a few thousand items, the size of the
data passed around in atomic retreival mode will exceed the typical jabber
max stanza size and result in a failure.  Retrieve the records in
streaming mode instead.

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
11 years agoTPAC: Render record titles and authors consistently
Dan Scott [Thu, 11 Apr 2013 12:56:50 +0000 (05:56 -0700)]
TPAC: Render record titles and authors consistently

Yamil Suarez noticed that the titles and authors in the call number
browse results page were presented differently than the regular search
results. This change removes some of the hard-coded <em> tags and "bold"
classes, in favour of new "record_author" and "record_title" CSS
classes. Now sites can simply change the CSS in one place to keep things
consistent between the two search results pages.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Yamil Suarez <yamil@yamil.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
11 years agoUse inline-block for opac-multiline-button style
Ben Shum [Wed, 27 Mar 2013 15:48:58 +0000 (11:48 -0400)]
Use inline-block for opac-multiline-button style

Follow up for LP1102934 which introduced CSS for opac-multiline-button.

The button appeared noticeably larger if using the english text for
"FAQs" on the login help button. Using inline-block for the style shrinks
it to fit more appropriately based on actual amount of text instead of
leaving it an unusually large looking button.

Signed-off-by: Ben Shum <bshum@biblio.org>
Signed-off-by: Kyle Tomita <ktomita@catalystitservices.com>
11 years agoTPAC Turn dashes into space in subject search links for better matching
Lebbeous Fogle-Weekley [Wed, 10 Apr 2013 17:23:28 +0000 (13:23 -0400)]
TPAC Turn dashes into space in subject search links for better matching

Thanks to Dan Wells for finding a bug and fixing it for demonstration
purposes.

Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Signed-off-by: Dan Wells <dbw2@calvin.edu>
11 years agoAdd summary creation to embedded alt dist editor
Dan Wells [Thu, 4 Apr 2013 20:43:38 +0000 (16:43 -0400)]
Add summary creation to embedded alt dist editor

In the Serial Control View, summaries are created automatically with
a new distribution. To avoid unhappy surprises, the embedded version
of the alt distribution editor should do the same.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>