Bug 28073

Summary: Make patron modifications auto-open panel for referring patron record
Product: Koha Reporter: Owen Leonard <oleonard>
Component: PatronsAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Katrin Fischer <katrin.fischer>
Severity: enhancement    
Priority: P5 - low CC: gmcharlt, jonathan.druart, kyle.m.hall, kyle, severine.queune
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
21.11.00
Bug Depends on: 27873    
Bug Blocks:    
Attachments: Bug 28073: Patron modifications should auto-open panel for referring patron record
Bug 28073: Patron modifications should auto-open panel for referring patron record
Bug 28073: Patron modifications should auto-open panel for referring patron record

Description Owen Leonard 2021-04-01 21:12:39 UTC
The "Pending patron modifications" link from the checkout or patron details page should pass the borrowernumber so that the patron update page can expand the correct panel.
Comment 1 Owen Leonard 2021-04-02 11:17:00 UTC
Created attachment 119118 [details] [review]
Bug 28073: Patron modifications should auto-open panel for referring patron record

This patch makes it possible to link directly to the correct panel on
the "Update patron records" page. The link on the checkout and patron
details screen has been updated to read "Patron has pending
modifications."

Also changed: Moved the "Patron's address in doubt" message so that it
is above the table of changed fields.

To test, apply the patch and if necessary submit patron modification
requests from multiple patrons via the OPAC.

 - Open the checkout page for one of these patrons.
   - If you are logged in as a user with permission to edit patron
     records you should see a message, "Pending modifications: Review
     pending modifications," which links to the pending modifications
     page.
     - Clicking the link should open the page for reviewing pending
       patron modifications, and the correct panel should be
       automatically expanded.
   - If you are logged in as a user without permission to edit patrons
     you should see the message "Pending modifications: Patron has
     pending modifications," which isn't linked.
 - The process should work exactly the same from the patron detail page.
 - Following the "Pending modifications" link from the staff interface
   home page or the patrons home page should work as before: The page
   opens with the first panel expanded.
Comment 2 Séverine Queune 2021-04-02 13:30:38 UTC
>  - Open the checkout page for one of these patrons.
>    - If you are logged in as a user with permission to edit patron
>      records you should see a message, "Pending modifications: Review
>      pending modifications," which links to the pending modifications
>      page.

On the checkout page, the message (without link) is the same for users with and without the patron modification permission.
Except that point, the patch works correctly.
Comment 3 Owen Leonard 2021-04-02 13:43:20 UTC
(In reply to Séverine Queune from comment #2)
> On the checkout page, the message (without link) is the same for users with
> and without the patron modification permission.

I can't reproduce this problem. Can you double-check that the "edit_borrowers" permission is the one you're setting, and that you're logging that user out and back in after changing permissions?
Comment 4 PTFS Europe Sandboxes 2021-04-02 15:00:19 UTC
Created attachment 119128 [details] [review]
Bug 28073: Patron modifications should auto-open panel for referring patron record

This patch makes it possible to link directly to the correct panel on
the "Update patron records" page. The link on the checkout and patron
details screen has been updated to read "Patron has pending
modifications."

Also changed: Moved the "Patron's address in doubt" message so that it
is above the table of changed fields.

To test, apply the patch and if necessary submit patron modification
requests from multiple patrons via the OPAC.

 - Open the checkout page for one of these patrons.
   - If you are logged in as a user with permission to edit patron
     records you should see a message, "Pending modifications: Review
     pending modifications," which links to the pending modifications
     page.
     - Clicking the link should open the page for reviewing pending
       patron modifications, and the correct panel should be
       automatically expanded.
   - If you are logged in as a user without permission to edit patrons
     you should see the message "Pending modifications: Patron has
     pending modifications," which isn't linked.
 - The process should work exactly the same from the patron detail page.
 - Following the "Pending modifications" link from the staff interface
   home page or the patrons home page should work as before: The page
   opens with the first panel expanded.

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Comment 5 Séverine Queune 2021-04-02 15:01:40 UTC
Problem was on my devbox, works perfectly on sandbox !
Comment 6 Katrin Fischer 2021-04-02 15:40:21 UTC
Sorry, this is BLOCKED right now, we still need a sign-off on bug 27873!
Comment 7 Katrin Fischer 2021-07-24 23:07:59 UTC
Created attachment 123163 [details] [review]
Bug 28073: Patron modifications should auto-open panel for referring patron record

This patch makes it possible to link directly to the correct panel on
the "Update patron records" page. The link on the checkout and patron
details screen has been updated to read "Patron has pending
modifications."

Also changed: Moved the "Patron's address in doubt" message so that it
is above the table of changed fields.

To test, apply the patch and if necessary submit patron modification
requests from multiple patrons via the OPAC.

 - Open the checkout page for one of these patrons.
   - If you are logged in as a user with permission to edit patron
     records you should see a message, "Pending modifications: Review
     pending modifications," which links to the pending modifications
     page.
     - Clicking the link should open the page for reviewing pending
       patron modifications, and the correct panel should be
       automatically expanded.
   - If you are logged in as a user without permission to edit patrons
     you should see the message "Pending modifications: Patron has
     pending modifications," which isn't linked.
 - The process should work exactly the same from the patron detail page.
 - Following the "Pending modifications" link from the staff interface
   home page or the patrons home page should work as before: The page
   opens with the first panel expanded.

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 8 Jonathan Druart 2021-07-26 10:47:38 UTC
Pushed to master for 21.11, thanks to everybody involved!
Comment 9 Kyle M Hall 2021-07-30 15:16:41 UTC
Enhancement not backported for 21.05