Patron search modal on Holds screen fails with barcode search

Bug #1955927 reported by Terran McCanna
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Fix Released
Medium
Unassigned
3.7
Fix Released
Undecided
Unassigned
3.8
Fix Released
Undecided
Unassigned

Bug Description

In 3.6 & 3.8:

If you click on the "Search for Patron" button on the Place Hold screen in the staff client, the modal pops up and all searches by patron barcode fail with "Error Retrieving Results" and errors in the browser console. (Name and other searches work fine.)

Revision history for this message
Michele Morgan (mmorgan) wrote :
Download full text (8.2 KiB)

Confirmed in 3.6. This error occurs in the angular staff catalog only. Here's a scrape of the errors from the console:

open-ils.actor.patron.search.advanced.fleshed failed! stat=500 msg= *** Call to [open-ils.actor.patron.search.advanced.fleshed] failed for session [0.0498150658169456141640785275365], thread trace [0]:
Exception: OpenSRF::EX::ERROR 2021-12-29T08:41:13 OpenSRF::Application /usr/local/share/perl/5.28.1/OpenSRF/Application.pm:243 System ERROR: Call to open-ils.storage for method open-ils.storage.actor.user.crazy_search
 failed with exception: Exception: OpenSRF::EX::ERROR 2021-12-29T08:41:13 OpenILS::Application::AppUtils /usr/local/share/perl/5.28.1/OpenILS/Application/AppUtils.pm:203 System ERROR: Exception: OpenSRF::DomainObject::oilsMethodException 2021-12-29T08:41:13 OpenSRF::AppRequest /usr/local/share/perl/5.28.1/OpenSRF/AppSession.pm:1159 <500> *** Call to [open-ils.storage.actor.user.crazy_search] failed for session [1640785273.5920524601.8847601974], thread trace [1]:
DBD::Pg::db selectcol_arrayref failed: ERROR: column "barcode" does not exist
LINE 4: ...or.usr u WHERE evergreen.unaccent_and_squash(CAST(barcode AS...
                                                             ^
HINT: Perhaps you meant to reference the column "u.barred" or the column "users.barred". [for Statement " SELECT evergreen.lowercase(CAST(users.family_name AS text)), evergreen.lowercase(CAST(users.first_given_name AS text)), evergreen.lowercase(CAST(users.second_given_name AS text)), evergreen.lowercase(CAST(users.dob AS text)), evergreen.lowercase(CAST(users.id AS text))
          FROM actor.usr AS users
            JOIN actor.org_unit_descendants(1) d ON (d.id = users.home_ou)
            JOIN (SELECT id as id FROM actor.usr u WHERE evergreen.unaccent_and_squash(CAST(barcode AS text)) ~ ?) AS search ON (search.id = users.id)

          WHERE users.deleted = FALSE
            AND users.active = TRUE

          GROUP BY evergreen.lowercase(CAST(users.family_name AS text)), evergreen.lowercase(CAST(users.first_given_name AS text)), evergreen.lowercase(CAST(users.second_given_name AS text)), evergreen.lowercase(CAST(users.dob AS text)), evergreen.lowercase(CAST(users.id AS text))
          ORDER BY evergreen.lowercase(CAST(users.family_name AS text)) ASC, evergreen.lowercase(CAST(users.first_given_name AS text)) ASC, evergreen.lowercase(CAST(users.second_given_name AS text)) ASC, evergreen.lowercase(CAST(users.dob AS text)) DESC, evergreen.lowercase(CAST(users.id AS text))
          LIMIT 100
          OFFSET 0
"] at /usr/local/share/perl/5.28.1/OpenILS/Application/Storage/Publisher/actor.pm line 903.

grid getRows() error open-ils.actor.patron.search.advanced.fleshed failed! stat=500 msg= *** Call to [open-ils.actor.patron.search.advanced.fleshed] failed for session [0.0498150658169456141640785275365], thread trace [0]:
Exception: OpenSRF::EX::ERROR 2021-12-29T08:41:13 OpenSRF::Application /usr/local/share/perl/5.28.1/OpenSRF/Application.pm:243 System ERROR: Call to open-ils.storage for method open-ils.storage.actor.user.crazy_search
 failed with exception: Exception: OpenSRF::EX::ERROR 20...

Read more...

Changed in evergreen:
status: New → Confirmed
importance: Undecided → Medium
tags: added: staffcatalog
Revision history for this message
Garry Collum (gcollum) wrote :
tags: added: pullrequest
Revision history for this message
Terran McCanna (tmccanna) wrote :
tags: added: signedoff
Changed in evergreen:
milestone: none → 3.9-beta
Revision history for this message
Jason Stephenson (jstephenson) wrote :

Works for me, also. I have pushed the patch to master, rel_3_7, and rel_3_8.

Thanks, Garry, Terran, and Michele!

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.