Bug 32530 - When duplicating child card, guarantor is not saved
Summary: When duplicating child card, guarantor is not saved
Status: Pushed to stable
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Baptiste Wojtkowski (bwoj)
QA Contact: Martin Renvoize (ashimema)
URL:
Keywords:
: 34763 (view as bug list)
Depends on:
Blocks: 37881
  Show dependency treegraph
 
Reported: 2022-12-23 22:36 UTC by Benjamin Daeuber
Modified: 2024-10-21 13:38 UTC (History)
11 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.11.00,24.05.05
Circulation function:


Attachments
Bug 32530: When duplicating child card, guarantor is not saved (2.88 KB, patch)
2024-07-11 14:59 UTC, Baptiste Wojtkowski (bwoj)
Details | Diff | Splinter Review
Bug 32530: When duplicating child card, guarantor is not saved (2.89 KB, patch)
2024-07-11 15:04 UTC, Baptiste Wojtkowski (bwoj)
Details | Diff | Splinter Review
Bug 32530: When duplicating child card, guarantor is not saved (2.92 KB, patch)
2024-07-12 10:21 UTC, Emmi Takkinen
Details | Diff | Splinter Review
Bug 32530: When duplicating child card, guarantor is not saved (3.02 KB, patch)
2024-07-17 16:18 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Daeuber 2022-12-23 22:36:57 UTC
When duplicating a child card with a guarantor, the guarantor information appears during the card creation process, but disappears as soon as saving the card. To recreate:

1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card creation screen.
3. Save the patron after completing the form. The guarantor is now gone.
Comment 1 Caroline Cyr La Rose 2023-05-23 15:00:16 UTC
Still valid in master (22.12.00.048)
Comment 2 Michael Spagnuolo 2023-07-10 16:36:44 UTC
Our library staff have noticed this bug, and it is causing extra steps during family card creation. We would like to see it fixed.
Comment 3 Emmi Takkinen 2023-09-14 07:54:02 UTC
*** Bug 34763 has been marked as a duplicate of this bug. ***
Comment 4 Baptiste Wojtkowski (bwoj) 2024-07-11 13:37:30 UTC
Hi,
I do not reproduce on main (v24.05.01), is it still valid ?
Comment 5 Baptiste Wojtkowski (bwoj) 2024-07-11 13:48:14 UTC
I finally reproduce on main, looking forward to fix it
Comment 6 Benjamin Daeuber 2024-07-11 14:01:44 UTC
It is still occurring on main (23.06). It does appear to work until you save the duplicated card, at which point the guarantor is not attached.
Comment 7 Baptiste Wojtkowski (bwoj) 2024-07-11 14:59:22 UTC
Created attachment 168833 [details] [review]
Bug 32530: When duplicating child card, guarantor is not saved

When duplicating a child card with a guarantor, the guarantor information appears during the card creation process, but disappears as soon as saving the card. To recreate:

1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card creation screen.
3. Save the patron after completing the form. The guarantor is now gone.

New test plan:
1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card creation screen.
3. Save the patron after completing the form. The guarantor is now gone.
Apply patch and repeat, the guarantor should stay after 3.

Note, I may not have understood the code but it looks like nothing is
searching for the content of the displayed information. Therefore I add
hidden fields that are copies of those provided in guarantor_template
class
Comment 8 Baptiste Wojtkowski (bwoj) 2024-07-11 15:04:38 UTC
Created attachment 168834 [details] [review]
Bug 32530: When duplicating child card, guarantor is not saved

When duplicating a child card with a guarantor, the guarantor information appears during the card creation process, but disappears as soon as saving the card. To recreate:

1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card creation screen.
3. Save the patron after completing the form. The guarantor is now gone.

New test plan:
1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card creation screen.
3. Save the patron after completing the form. The guarantor is now gone.
Apply patch and repeat, the guarantor should stay after 3.

Note, I may not have understood the code but it looks like nothing is
searching for the content of the displayed information. Therefore I add
hidden fields that are copies of those provided in guarantor_template
class
Comment 9 Emmi Takkinen 2024-07-12 10:21:29 UTC
Created attachment 168873 [details] [review]
Bug 32530: When duplicating child card, guarantor is not saved

When duplicating a child card with a guarantor, the guarantor information appears during the card creation process, but disappears as soon as saving the card. To recreate:

1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card creation screen.
3. Save the patron after completing the form. The guarantor is now gone.

New test plan:
1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card creation screen.
3. Save the patron after completing the form. The guarantor is now gone.
Apply patch and repeat, the guarantor should stay after 3.

Note, I may not have understood the code but it looks like nothing is
searching for the content of the displayed information. Therefore I add
hidden fields that are copies of those provided in guarantor_template
class

Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi>
Comment 10 Martin Renvoize (ashimema) 2024-07-17 16:18:16 UTC
Created attachment 169101 [details] [review]
Bug 32530: When duplicating child card, guarantor is not saved

When duplicating a child card with a guarantor, the guarantor information
appears during the card creation process, but disappears as soon as saving
the card. To recreate:

1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card
   creation screen.
3. Save the patron after completing the form. The guarantor is now gone.

New test plan:
1. Find a card with a guarantor, either patron or non-patron guarantor.
2. Duplicate the card. Note that it appears to be working on the card
   creation screen.
3. Save the patron after completing the form. The guarantor is now gone.
Apply patch and repeat, the guarantor should stay after 3.

Note, I may not have understood the code but it looks like nothing is
searching for the content of the displayed information. Therefore I add
hidden fields that are copies of those provided in guarantor_template
class

Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 11 Martin Renvoize (ashimema) 2024-07-17 16:18:42 UTC
Thanks for the fix guys, Passing QA
Comment 12 Katrin Fischer 2024-07-18 15:57:07 UTC
Pushed for 24.11!

Well done everyone, thank you!
Comment 13 Jonathan Druart 2024-09-10 12:59:06 UTC
This introduced a critical issue when editing patron, see bug 37881. Please fix ASAP.
Comment 14 Lucas Gass (lukeg) 2024-10-09 22:03:37 UTC
BAckported to 24.05.x for upcoming 24.05.05
Comment 15 Fridolin Somers 2024-10-21 13:38:52 UTC
(In reply to Jonathan Druart from comment #13)
> This introduced a critical issue when editing patron, see bug 37881. Please
> fix ASAP.

Bug 37881 currently only in main so I do not backport this one.

@Lucas revert this one or backport also Bug 37881