Bug 20343

Summary: Show number of checkouts by itemtype in circulation.pl
Product: Koha Reporter: Julian Maurice <julian.maurice>
Component: CirculationAssignee: Julian Maurice <julian.maurice>
Status: CLOSED FIXED QA Contact: Katrin Fischer <katrin.fischer>
Severity: enhancement    
Priority: P5 - low CC: fridolin.somers, gmcharlt, jonathan.druart, katrin.fischer, kyle.m.hall, oleonard, sandboxes
Version: master   
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:
Attachments: Bug 20343: Show number of checkouts by itemtype in circulation.pl
Bug 20343: Show number of checkouts by itemtype in circulation.pl
Bug 20343: Show number of checkouts by itemtype in circulation.pl
Bug 20343: Show number of checkouts by itemtype in circulation.pl
Bug 20343: Show number of checkouts by itemtype in circulation.pl
Bug 20343: Show number of checkouts by itemtype in circulation.pl
Bug 20343: Put translatable strings in strings.tt
Bug 20343: Show number of checkouts by itemtype in circulation.pl
Bug 20343: Put translatable strings in strings.tt

Description Julian Maurice 2018-03-06 15:05:41 UTC
It is sometimes useful to have the number of checkouts grouped by itemtype (to see if we're approaching the maximum number of checkouts allowed for instance).
Comment 1 Julian Maurice 2018-03-06 15:06:25 UTC
Created attachment 72482 [details] [review]
Bug 20343: Show number of checkouts by itemtype in circulation.pl

It is sometimes useful to have the number of checkouts grouped by
itemtype (to see if we're approaching the maximum number of checkouts
allowed for instance).
This patch adds this information above the checkouts table, in
circ/circulation.pl

Test plan:
1. Check out some items with various item types to a patron
2. In circ/circulation.pl, click on 'Show checkouts' button to display
   the table
3. Notice the line "Number of checkouts by item type" above the table,
   click on it
4. See that the list of item types is displayed with a count in front of
   each one
5. Compare the numbers to the checkouts in the table and verify that the
   numbers are correct
Comment 2 Biblibre Sandboxes 2018-03-12 11:35:11 UTC
Patch tested with a sandbox, by delaye <stephane.delaye@biblibre.com>
Comment 3 Biblibre Sandboxes 2018-03-12 11:35:33 UTC Comment hidden (obsolete)
Comment 4 Biblibre Sandboxes 2018-03-12 11:42:11 UTC
Patch tested with a sandbox, by claude <claude.brayer@cea.fr>
Comment 5 Biblibre Sandboxes 2018-03-12 11:42:32 UTC Comment hidden (obsolete)
Comment 6 Jesse Maseto 2018-03-12 11:56:50 UTC
Created attachment 72675 [details] [review]
Bug 20343: Show number of checkouts by itemtype in circulation.pl

It is sometimes useful to have the number of checkouts grouped by
itemtype (to see if we're approaching the maximum number of checkouts
allowed for instance).
This patch adds this information above the checkouts table, in
circ/circulation.pl

Test plan:
1. Check out some items with various item types to a patron
2. In circ/circulation.pl, click on 'Show checkouts' button to display
   the table
3. Notice the line "Number of checkouts by item type" above the table,
   click on it
4. See that the list of item types is displayed with a count in front of
   each one
5. Compare the numbers to the checkouts in the table and verify that the
   numbers are correct

Signed-off-by: claude <claude.brayer@cea.fr>

Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com>

Works as described. Maybe remove one of the arrows from the display.
Comment 7 Katrin Fischer 2018-03-30 12:25:20 UTC
Created attachment 73475 [details] [review]
Bug 20343: Show number of checkouts by itemtype in circulation.pl

It is sometimes useful to have the number of checkouts grouped by
itemtype (to see if we're approaching the maximum number of checkouts
allowed for instance).
This patch adds this information above the checkouts table, in
circ/circulation.pl

Test plan:
1. Check out some items with various item types to a patron
2. In circ/circulation.pl, click on 'Show checkouts' button to display
   the table
3. Notice the line "Number of checkouts by item type" above the table,
   click on it
4. See that the list of item types is displayed with a count in front of
   each one
5. Compare the numbers to the checkouts in the table and verify that the
   numbers are correct

Signed-off-by: claude <claude.brayer@cea.fr>

Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 8 Jonathan Druart 2018-04-02 20:52:02 UTC
Any good reasons to use custom tag elements here?
Comment 9 Jonathan Druart 2018-04-02 20:52:57 UTC
Translatable strings must be put in .tt files.
Comment 10 Julian Maurice 2018-04-18 13:23:44 UTC
Created attachment 74430 [details] [review]
Bug 20343: Show number of checkouts by itemtype in circulation.pl

It is sometimes useful to have the number of checkouts grouped by
itemtype (to see if we're approaching the maximum number of checkouts
allowed for instance).
This patch adds this information above the checkouts table, in
circ/circulation.pl

Test plan:
1. Check out some items with various item types to a patron
2. In circ/circulation.pl, click on 'Show checkouts' button to display
   the table
3. Notice the line "Number of checkouts by item type" above the table,
   click on it
4. See that the list of item types is displayed with a count in front of
   each one
5. Compare the numbers to the checkouts in the table and verify that the
   numbers are correct
Comment 11 Julian Maurice 2018-04-18 13:23:48 UTC
Created attachment 74431 [details] [review]
Bug 20343: Put translatable strings in strings.tt

Also add a CSS class on <details> for easier styling and change the
list style so it take less space on screen
Comment 12 Julian Maurice 2018-04-18 13:25:00 UTC
Created attachment 74432 [details] [review]
Bug 20343: Show number of checkouts by itemtype in circulation.pl

It is sometimes useful to have the number of checkouts grouped by
itemtype (to see if we're approaching the maximum number of checkouts
allowed for instance).
This patch adds this information above the checkouts table, in
circ/circulation.pl

Test plan:
1. Check out some items with various item types to a patron
2. In circ/circulation.pl, click on 'Show checkouts' button to display
   the table
3. Notice the line "Number of checkouts by item type" above the table,
   click on it
4. See that the list of item types is displayed with a count in front of
   each one
5. Compare the numbers to the checkouts in the table and verify that the
   numbers are correct

Signed-off-by: claude <claude.brayer@cea.fr>

Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 13 Julian Maurice 2018-04-18 13:25:05 UTC
Created attachment 74433 [details] [review]
Bug 20343: Put translatable strings in strings.tt

Also add a CSS class on <details> for easier styling and change the
list style so it take less space on screen
Comment 14 Julian Maurice 2018-04-18 13:26:51 UTC
(In reply to Jonathan Druart from comment #8)
> Any good reasons to use custom tag elements here?

If you're talking about <details> and <summary> they are standard elements :
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/summary
Comment 15 Jonathan Druart 2018-04-18 13:39:22 UTC
(In reply to Julian Maurice from comment #14)
> (In reply to Jonathan Druart from comment #8)
> > Any good reasons to use custom tag elements here?
> 
> If you're talking about <details> and <summary> they are standard elements :
> https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details
> https://developer.mozilla.org/en-US/docs/Web/HTML/Element/summary

I was not aware of them, thanks for the links.
Comment 16 Jonathan Druart 2018-04-19 15:42:52 UTC
Pushed to master for 18.05, thanks to everybody involved!
Comment 17 Fridolin Somers 2018-06-05 07:49:33 UTC
Pushed to 17.11.x for 17.11.07.

Small and nice enhancement.