Bug 26833

Summary: Logged in library doesn't show with suggestions count
Product: Koha Reporter: Séverine Queune <severine.queune>
Component: TemplatesAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: minor    
Priority: P5 - low CC: lucas, marjorie.barry-vila
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
20.11.00
Bug Depends on: 25033    
Bug Blocks:    
Attachments: Bug 26833: Logged in library doesn't show with suggestions count
Bug 26833: Logged in library doesn't show with suggestions count
Bug 26833: Logged in library doesn't show with suggestions count

Description Séverine Queune 2020-10-27 12:57:38 UTC
On acquisitions home, 2 colons are displayed on the 'Pending suggestions' block.
See screenshot : https://snipboard.io/nkLBJI.jpg.
Comment 1 Owen Leonard 2020-10-27 13:35:57 UTC
Bug 25033 added library information to the counts of suggestions shown on the staff interface home page and the acquisitions home page. The LoginBranchname used in the template doesn't exist, having been removed by Bug 25765.

The template should use [% Branches.GetLoggedInBranchname %] instead.
Comment 2 Owen Leonard 2020-10-27 14:07:02 UTC
Created attachment 112576 [details] [review]
Bug 26833: Logged in library doesn't show with suggestions count

This patch corrects the template variables used by the suggestions
counts shown on the staff interface home page and the acquisitions home
page. They should use [% Branches.GetLoggedInBranchname %]

To test you should have some suggestions from multiple libraries.

- Log in to the staff interface.
- On the home page you should see "Suggestions pending approval,"
  followed by the name of your logged-in library and the count of
  suggestions for your library.
- Go to the acquisitions page.
- In the "Pending suggestions" section you should see the same
  information: Your logged-in library name, suggestion count, and the
  count of suggestions at all libraries.
Comment 3 Séverine Queune 2020-10-27 16:31:03 UTC
Created attachment 112584 [details] [review]
Bug 26833: Logged in library doesn't show with suggestions count

This patch corrects the template variables used by the suggestions
counts shown on the staff interface home page and the acquisitions home
page. They should use [% Branches.GetLoggedInBranchname %]

To test you should have some suggestions from multiple libraries.

- Log in to the staff interface.
- On the home page you should see "Suggestions pending approval,"
  followed by the name of your logged-in library and the count of
  suggestions for your library.
- Go to the acquisitions page.
- In the "Pending suggestions" section you should see the same
  information: Your logged-in library name, suggestion count, and the
  count of suggestions at all libraries.

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Comment 4 Séverine Queune 2020-10-27 16:33:45 UTC
I've got a slightly different display from what is described.
Using 'independentbanches', a staff user sees only 'logged-in library: nb' on both pages while a superlibrarian sees 'logged-in library: nb / All libraries: nb'.
Without 'independentbanches', the 2 informations for the 'logged-in library' and 'all librairies' are display including in the home page.
I signed thought, because that's completely relevant and what I expected as display.
Let me know if I shouldn't have to.
Comment 5 Katrin Fischer 2020-11-01 12:34:03 UTC
Created attachment 112800 [details] [review]
Bug 26833: Logged in library doesn't show with suggestions count

This patch corrects the template variables used by the suggestions
counts shown on the staff interface home page and the acquisitions home
page. They should use [% Branches.GetLoggedInBranchname %]

To test you should have some suggestions from multiple libraries.

- Log in to the staff interface.
- On the home page you should see "Suggestions pending approval,"
  followed by the name of your logged-in library and the count of
  suggestions for your library.
- Go to the acquisitions page.
- In the "Pending suggestions" section you should see the same
  information: Your logged-in library name, suggestion count, and the
  count of suggestions at all libraries.

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

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 6 Jonathan Druart 2020-11-02 10:06:05 UTC
Pushed to master for 20.11, thanks to everybody involved!
Comment 7 Lucas Gass 2020-11-16 18:35:27 UTC
does not apply clean to 20.05.x, no backport