Bug 18869

Summary: Patron clubs and templates tables look strange when empty
Product: Koha Reporter: Aleisha Amohia <aleisha>
Component: ToolsAssignee: Aleisha Amohia <aleisha>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: fridolin.somers, mtompset
Version: unspecifiedKeywords: Academy
Hardware: All   
OS: All   
Change sponsored?: Sponsored Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Bug Depends on:    
Bug Blocks: 19215    
Attachments: Patron clubs interface showing tables
Bug 18869: Fixing display of patron clubs tables
Bug 18869: [FOLLOW-UP] Make page reload after club or template delete
Bug 18869: [FOLLOW-UP] Show enrollments as disabled link
[SIGNED-OFF] Bug 18869: Fixing display of patron clubs tables
[SIGNED-OFF] Bug 18869: [FOLLOW-UP] Make page reload after club or template delete
[SIGNED-OFF] Bug 18869: [FOLLOW-UP] Show enrollments as disabled link
Bug 18869: Fixing display of patron clubs tables
Bug 18869: [FOLLOW-UP] Make page reload after club or template delete
Bug 18869: [FOLLOW-UP] Show enrollments as disabled link

Description Aleisha Amohia 2017-06-27 22:02:17 UTC
Created attachment 64684 [details]
Patron clubs interface showing tables

The tables for patron clubs and club templates should not show at all if they are empty. Also the clubs table is slightly broken. See screenshot.
Comment 1 Aleisha Amohia 2017-06-28 02:34:03 UTC
Created attachment 64687 [details] [review]
Bug 18869: Fixing display of patron clubs tables

This patch
1) Hides the club templates table if there are no club templates, shows
an appropriate message
2) Hides the clubs table if there are no clubs. Shows an appropriate
message for whether templates exist
3) Puts the actions in one column, or a dropdown menu

Sponsored-by: Catalyst IT
Comment 2 Mark Tompsett 2017-06-29 16:12:52 UTC
It looks good.

REPRODUCE OUTPUT QUESTION:
Add a template
Add a club
Delete a club

Just quick question. If there are no templates or clubs, should it not revert to this new style of nothing? Or is this okay?

If it is okay, then I'll sign off. If it should revert to the initial nothing style, then this needs a tweak.
Comment 3 Aleisha Amohia 2017-07-09 22:00:42 UTC
Created attachment 64936 [details] [review]
Bug 18869: [FOLLOW-UP] Make page reload after club or template delete

If deleting the last club or template in a table, the row is deleted
from the webpage by ajax so the nice blue bubble message does not show.
This patch forces the page to reload so the blue bubble message shows
instead of the empty table.

To test:
Confirm that the blue message shows when tables are empty. Add a
template and a club, then delete a club. Confirm the page reloads and
the message shows. Test with template

Sponsored-by: Catalyst IT
Comment 4 Aleisha Amohia 2017-07-10 03:40:11 UTC
Created attachment 64946 [details] [review]
Bug 18869: [FOLLOW-UP] Show enrollments as disabled link

if club has no enrolled patrons
Comment 5 Mark Tompsett 2017-08-03 02:26:48 UTC
Created attachment 65443 [details] [review]
[SIGNED-OFF] Bug 18869: Fixing display of patron clubs tables

This patch
1) Hides the club templates table if there are no club templates, shows
an appropriate message
2) Hides the clubs table if there are no clubs. Shows an appropriate
message for whether templates exist
3) Puts the actions in one column, or a dropdown menu

Sponsored-by: Catalyst IT

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Comment 6 Mark Tompsett 2017-08-03 02:26:51 UTC
Created attachment 65444 [details] [review]
[SIGNED-OFF] Bug 18869: [FOLLOW-UP] Make page reload after club or template delete

If deleting the last club or template in a table, the row is deleted
from the webpage by ajax so the nice blue bubble message does not show.
This patch forces the page to reload so the blue bubble message shows
instead of the empty table.

To test:
Confirm that the blue message shows when tables are empty. Add a
template and a club, then delete a club. Confirm the page reloads and
the message shows. Test with template

Sponsored-by: Catalyst IT

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Comment 7 Mark Tompsett 2017-08-03 02:26:53 UTC
Created attachment 65445 [details] [review]
[SIGNED-OFF] Bug 18869: [FOLLOW-UP] Show enrollments as disabled link

if club has no enrolled patrons

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Comment 8 Mark Tompsett 2017-08-03 02:28:47 UTC
I figured I wouldn't let it languish.
Comment 9 Jonathan Druart 2017-08-30 19:48:44 UTC
Created attachment 66650 [details] [review]
Bug 18869: Fixing display of patron clubs tables

This patch
1) Hides the club templates table if there are no club templates, shows
an appropriate message
2) Hides the clubs table if there are no clubs. Shows an appropriate
message for whether templates exist
3) Puts the actions in one column, or a dropdown menu

Sponsored-by: Catalyst IT

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 10 Jonathan Druart 2017-08-30 19:48:47 UTC
Created attachment 66651 [details] [review]
Bug 18869: [FOLLOW-UP] Make page reload after club or template delete

If deleting the last club or template in a table, the row is deleted
from the webpage by ajax so the nice blue bubble message does not show.
This patch forces the page to reload so the blue bubble message shows
instead of the empty table.

To test:
Confirm that the blue message shows when tables are empty. Add a
template and a club, then delete a club. Confirm the page reloads and
the message shows. Test with template

Sponsored-by: Catalyst IT

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 11 Jonathan Druart 2017-08-30 19:48:51 UTC
Created attachment 66652 [details] [review]
Bug 18869: [FOLLOW-UP] Show enrollments as disabled link

if club has no enrolled patrons

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 12 Jonathan Druart 2017-08-30 20:01:43 UTC
Pushed to master for 17.11, thanks to everybody involved!
Comment 13 Fridolin Somers 2017-09-29 13:52:55 UTC
Enhancement not pushed to 17.05.x