TPAC results page does not respect items in non-visible copy locations

Bug #1062502 reported by Robert Soulliere
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Status tracked in Main
2.2
Fix Released
Undecided
Unassigned
Main
Fix Released
Undecided
Unassigned

Bug Description

EG version: 2.2
postgreSQL: 9.1
OpenSRF: 2.1

When listing copies in the results list, items show even though they are in copy locations set to be non-visble.

For example, we have a copy location "SIX_NATION" set to be non-visible in the OPAC. However, copies at that loction are displayed when copies exist at other locations.

Here is an example search:
http://libcat.mohawkcollege.ca/eg/opac/results?bool=and&qtype=subject&contains=contains&query=Maternity+nursing&bool=and&qtype=keyword&contains=contains&query=&bool=and&qtype=keyword&contains=contains&query=&fi%3Aaudience=&sort=pubdate&locg=1&pubdate=between&date1=2003&date2=2004&_adv=1

Compare to the record view of the first item:
http://libcat.mohawkcollege.ca/eg/opac/record/29135?bool=and;bool=and;bool=and;qtype=subject;qtype=keyword;qtype=keyword;contains=contains;contains=contains;contains=contains;query=Maternity%20nursing;query=;query=;sort=pubdate;locg=1;pubdate=between;date1=2003;date2=2004;_adv=1

Compare the copy tables. The copy at the non-visible location is displayed in the results page. Moreover, a "lost" item displays in the results list but not in the detail record view.

Tags: pullrequest
Revision history for this message
Dan Scott (denials) wrote :

Here's a branch built against master that fixes the problem with copy locations, copy statuses, and circulation libraries: http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/dbs/tpac_location_visibility

This should be backported to rel_2_3 and might be able to go into rel_2_2.

Changed in evergreen:
status: New → Confirmed
milestone: none → 2.3.1
tags: added: pullrequest
Revision history for this message
Robert Soulliere (rcsoulliere) wrote :

Thanks Dan, Code changes worked well on our 2.2.

One minor issue occurred with one line change in your branch:
http://git.evergreen-ils.org/?p=working/Evergreen.git;a=commitdiff;h=32a8b92041c61726367962aa35460c8eefe8b364

Changed From (original) :
circlib = copy.findnodes('./*[local-name()="circlib"]');

Changed To (in your branch):
circlib = copy.findnodes('./*[local-name()="circ_lib"]');

This caused the library location names to disappear on the results list.

Leaving that line as:
circlib = copy.findnodes('./*[local-name()="circlib"]');
worked for us on our 2.2 system.

Revision history for this message
Dan Scott (denials) wrote :

Robert, you're absolutely right - I didn't notice that change in behaviour at the slightly ungodly time I posted that. I've updated the branch accordingly, and confirmed that the circulation library name appears as expected. If you could sign off on the updated branch, I would greatly appreciate it.

Revision history for this message
Robert Soulliere (rcsoulliere) wrote :
Revision history for this message
Dan Scott (denials) wrote :

Excellent, thanks Robert! Pushed to master, rel_2_3, and rel_2_2.

Changed in evergreen:
status: Confirmed → Fix Committed
Changed in evergreen:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.