Bug 38070 - Regression in print notices
Summary: Regression in print notices
Status: Pushed to stable
Alias: None
Product: Koha
Classification: Unclassified
Component: Staff interface (show other bugs)
Version: Main
Hardware: All All
: P5 - low critical
Assignee: Martin Renvoize (ashimema)
QA Contact: Katrin Fischer
URL:
Keywords:
Depends on: 35402
Blocks:
  Show dependency treegraph
 
Reported: 2024-10-03 09:45 UTC by Martin Renvoize (ashimema)
Modified: 2025-02-20 20:46 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
This fixes a regression from the Boostrap 5 upgrade for print notices. Each notice is now on its own page, instead of running one after the other without a page break (when running gather_print_notices.pl with HTML file output). (This is related to the OPAC and staff interface Bootstrap 5 upgrade in Koha 24.11.)
Version(s) released in:
25.05.00,24.11.02
Circulation function:


Attachments
Bug 38070: Revert class change so notices print one per page (1.47 KB, patch)
2024-10-03 14:49 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review
Bug 38070: Revert class change so notices print one per page (1.53 KB, patch)
2024-11-25 16:30 UTC, Andrew Fuerste-Henry
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Renvoize (ashimema) 2024-10-03 09:45:29 UTC
I think we've got a regression in the print notices since bootstrap 5.

I noticed whilst working on another bug, that we replaced 'dialog message' with 'alert alert-info' classes in batch/print-notices.tt

However, we didn't update the additional CSS rules above that add `page-break-after: always` onto the 'message' class.

As such, I believe we'll no longe print one notice per page.
Comment 1 Martin Renvoize (ashimema) 2024-10-03 10:48:24 UTC
Side question..

The template here and the circ/printslips.tt template achieve the same result using different methods.

This one adds `page-break-after: always` to the containing div of the notice whilst printslips.tt adds an empty div after each slip div and adds `break-after: page` to that.

Any thoughts on which method we should use consistently?
Comment 2 Martin Renvoize (ashimema) 2024-10-03 14:49:13 UTC
Created attachment 172361 [details] [review]
Bug 38070: Revert class change so notices print one per page

This patch reverses the bootstrap 5 find and replace for the 'message'
class.

In this file the message class didn't refer to the bootstrap themeing
but rather is used for applying `page-break-after: always` to these
elements.

Test plan
1) Line up some print notices
2) Run gather_print_notices.pl with html file output
3) Open the output file
4) Print the page to invoke the page break css
5) Note that with the patch each notice is on it's own page, without the
   patch all the notices run one after the other on the same page.
Comment 3 Andrew Fuerste-Henry 2024-11-25 16:30:41 UTC
Created attachment 174981 [details] [review]
Bug 38070: Revert class change so notices print one per page

This patch reverses the bootstrap 5 find and replace for the 'message'
class.

In this file the message class didn't refer to the bootstrap themeing
but rather is used for applying `page-break-after: always` to these
elements.

Test plan
1) Line up some print notices
2) Run gather_print_notices.pl with html file output
3) Open the output file
4) Print the page to invoke the page break css
5) Note that with the patch each notice is on it's own page, without the
   patch all the notices run one after the other on the same page.

Signed-off-by: Andrew Fuerste Henry <andrew@bywatersolutions.com>
Comment 4 Katrin Fischer 2024-12-23 08:38:02 UTC
Pushed for 25.05!

Well done everyone, thank you!
Comment 5 Paul Derscheid 2025-02-03 19:09:04 UTC
Nice work everyone!

Pushed to 24.11.x for 24.11.01
Comment 6 Alex Buckley 2025-02-20 20:46:39 UTC
not backporting to 24.05.x unless requested - dependency not in 24.05