Bug 30978 - Potential data loss when using Quick add new patron
Summary: Potential data loss when using Quick add new patron
Status: RESOLVED DUPLICATE of bug 31497
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: Main
Hardware: All All
: P5 - low major with 10 votes (vote)
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-06-16 13:47 UTC by Sally
Modified: 2023-05-04 08:45 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sally 2022-06-16 13:47:22 UTC
When using the Quick add new patron form with mandatory fields, if a mistake is made, data can be lost.

To replicate:

- In System Preferences, go to:  BorrowerMandatoryField
- Put in some mandatory fields - e.g. firstname, surname, cardnumber
- Go to Patrons
- Press +Quick add new patron
- Choose patron as a category type
- Note that firstname, surname and cardnumber are all mandatory fields
- Put data into firstname and cardnumber
- Do not put any data in surname
- Press Save

The form will not submit because surname is a required field - and a prompt is shown:  "This field is required."

- Now correct your mistake and fill in the surname
- Press Save
- The form now submits and creates an account - but the corrected surname field is still blank

I've tested this with a range of fields - and I've added 10 mandatory fields and submitted a form with 2, then corrected 4, then submitted again etc - and the form always sends the very first version and disregards any amendments.
Comment 1 Katrin Fischer 2022-06-17 19:51:44 UTC
Confirmed on master, updating severity.
Comment 2 Sally 2023-05-04 08:45:53 UTC

*** This bug has been marked as a duplicate of bug 31497 ***