Missing Working Location Causes Angular Staff Catalog Not to Display

Bug #1969641 reported by John Amundson
28
This bug affects 10 people
Affects Status Importance Assigned to Milestone
Evergreen
Fix Released
Medium
Unassigned
3.9
Fix Released
Medium
Unassigned

Bug Description

Evergreen 3.7.2ish

We recently upgraded to Evergreen 3.7.2 and have had a couple complaints about getting a white screen when accessing the new Angular staff catalog.

Instead of going to https://bark.cwmars.org/eg2/en-US/staff/catalog/search, the URL displays as https://bark.cwmars.org/eg2/en-US/

After some investigation, it appears that this is happening only to staff records without a working location.

I'm not sure if the permission issue goes deeper than that, yet, but it appears that adding a working location fixes the issue.

Console gives the following error: "ERROR Error: Uncaught (in promise): User does not have staff permissions"

It should be more obvious to the user what the issue is so that it can be fixed.

Bill Erickson (berick)
Changed in evergreen:
assignee: nobody → Bill Erickson (berick)
status: New → Confirmed
Revision history for this message
Bill Erickson (berick) wrote :

Here's a patch:

https://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/berick/lp1969641-no-work-org-msg

Note the new message only appears if the user logging in has STAFF_LOGIN permissions but does not have any working locations.

Lack of a STAFF_LOGIN permission will continue to result in a vanilla login failure.

Changed in evergreen:
milestone: none → 3.9-rc
assignee: Bill Erickson (berick) → nobody
tags: added: pullrequest
Changed in evergreen:
importance: Undecided → Medium
Changed in evergreen:
milestone: 3.9-rc → 3.9.1
Revision history for this message
Terran McCanna (tmccanna) wrote :

I have tested this and it works for the Angular staff catalog, but before I sign off I wonder if it would be better to do this check / alert immediately upon login?

I ask because the patron registration/edit form will not load without a working location either - I don't know if there are others.

We assign working locations to all staff, but are there libraries that have types of staff that legitimately do not need working locations?

tags: added: needsdiscussion
Revision history for this message
Jennifer Pringle (jpringle-u) wrote :

I agree with Terran that doing the check/alert at login would be more useful. Depending on what staff are doing they can go a while before encountering one of the interfaces that won't load without a working location.

For us, all library staff have to have at least one working location.

Revision history for this message
John Amundson (jamundson) wrote :

I also agree with others here.

All of our staff records have (or should have) a working location. If one is missing, there are many features of the staff client affected. The white screen in the catalog is just one more. It would be better if staff are alerted upon sign in.

tags: added: needswork
removed: needsdiscussion pullrequest
Revision history for this message
Bill Erickson (berick) wrote :

Hi, the patch provided performs the check at login. It's not catalog-specific.

However, you have to log in via the Angular (/eg2/staff/login) page, not the old AngJS login page.

tags: added: pullrequest
removed: needswork
Revision history for this message
John Amundson (jamundson) wrote :

Thanks, Bill! This is working for me. It's actually working from the AngJS login page as well (I think because the splash screen on the test server defaults to eg2).

I have tested this code and consent to signing off on it with my name, John Amundson, and my email address, <email address hidden>.

tags: added: signedoff
Changed in evergreen:
milestone: 3.9.1 → 3.9.2
Galen Charlton (gmc)
Changed in evergreen:
milestone: 3.9.2 → 3.10.1
Revision history for this message
Galen Charlton (gmc) wrote :

Pushed down to rel_3_9. Thanks, Bill and John!

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.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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