Cannot replace barcode if patron does not have card

Bug #851110 reported by Jeff Davis
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Fix Released
Undecided
Unassigned

Bug Description

On our Evergreen 2.0.8 system, it sometimes arises that a patron's card gets deleted. If it was the patron's only card, it becomes impossible to add a new card to the account via the staff client.

How to reproduce:
1. Retrieve a patron record for a patron who has no associated card.
2. Click the Edit button.
3. Click Replace Barcode and enter a new barcode.
4. Click Save. This does not work - the process hangs, and if you hit Reload, you will find that your changes were not saved.

I believe this happens because some code in register.js assumes the patron has at least one card. I have a potential fix that this comment box is too small to contain ... uh, that is to say, I will post it momentarily.

Tags: pullrequest
Revision history for this message
Jeff Davis (jdavis-sitka) wrote :
Revision history for this message
Jeff Davis (jdavis-sitka) wrote :

And here it is in patch form.

tags: added: pullrequest
Revision history for this message
Thomas Berezansky (tsbere) wrote :

Any chance you can force-push the commit with a sign-off?

Revision history for this message
Mike Rylander (mrylander) wrote :

In the interest of getting the code in, I've applied the patch to master and backported through 2.0. Thanks, Jeff!

Changed in evergreen:
status: New → Fix Committed
Ben Shum (bshum)
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.