We propose allowing for staff to select multiple article requests on the screen and have Koha generate them and print in one transaction through the browser.
Created attachment 121608 [details] [review] Bug 27949: Allow multiple article requests print slip This bug allows for batch printing of multiple article requests slips To test: 1. apply this patch 2. restart_all 3. enable ArticleRequests preference 4. create multiple article requests 5. go to circ/article-requests.pl in staff interface 6. print a single slip from a row CHECK => it works as expected 7. select all rows and print slip from general actions menu (above the table) SUCCESS => all article requests slips are printed 8. select multiple rows (not all) and print slip from general actions menu (above the table) SUCCESS => only selected article requests slips are printed
I was on the edge of testing this until someone deciced to add a second perllib and my setup no longer works, aarggg
What if I would like to have these notices on a separate page? I would be inclined to look for a solution with NoticeCSS and a page-break-after. Should this development respect NoticeCSS ? Please have a look at: Koha/Patron/Discharge.pm, sub generate_as_pdf misc/cronjobs/gather_print_notices.pl, sub generate_html Both are using: koha-tmpl/intranet-tmpl/prog/en/modules/batch/print-notices.tt
Hi Marcel, sorry for the delay. For what I've seen, printslip.tt uses SlipCSS stylesheet (if defined) where you may say, for example hr { display: none; page-break-after: always; }
(In reply to Agustín Moyano from comment #4) > Hi Marcel, sorry for the delay. For what I've seen, printslip.tt uses > SlipCSS stylesheet (if defined) where you may say, for example > > hr { > display: none; > page-break-after: always; > } Did you test this yourself? I already did some testing with page-break-after but couldnt get it to work. I now inserted the exact lines above in a stylesheet for SlipCSS but it does not work either.
The issue raised on comment3 (tomorrow exactly three months ago) is imo legitimate, but has not been answered sufficiently. Changing status to emphasize the need for feedback in all appreciation.
(In reply to Marcel de Rooy from comment #5) > (In reply to Agustín Moyano from comment #4) > > Hi Marcel, sorry for the delay. For what I've seen, printslip.tt uses > > SlipCSS stylesheet (if defined) where you may say, for example > > > > hr { > > display: none; > > page-break-after: always; > > } > > Did you test this yourself? > > I already did some testing with page-break-after but couldnt get it to work. > I now inserted the exact lines above in a stylesheet for SlipCSS but it does > not work either. Hi Marcel, I did not test it, but my point was that printslip.tt includes a css, just as print-notices.tt where you can define page breaking conditions. Let me play around a bit, and I'll post a working example
Hi Marcel, the following code worked for me hr { page-break-after: always; border: 0px solid black !important; } First times did not work, but I believe it was browser's cache or memcached Could you try again, please?
(In reply to Agustín Moyano from comment #8) > Hi Marcel, the following code worked for me > > hr { > page-break-after: always; > border: 0px solid black !important; > } > > First times did not work, but I believe it was browser's cache or memcached > > Could you try again, please? It works for me now. Not sure what changed. Anyway, thanks!
Created attachment 125183 [details] [review] Bug 27949: Allow multiple article requests print slip This bug allows for batch printing of multiple article requests slips To test: 1. apply this patch 2. restart_all 3. enable ArticleRequests preference 4. create multiple article requests 5. go to circ/article-requests.pl in staff interface 6. print a single slip from a row CHECK => it works as expected 7. select all rows and print slip from general actions menu (above the table) SUCCESS => all article requests slips are printed 8. select multiple rows (not all) and print slip from general actions menu (above the table) SUCCESS => only selected article requests slips are printed Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Adding a dependency to organize things. It doesn't apply.
Created attachment 125248 [details] [review] Bug 27949: Allow multiple article requests print slip This bug allows for batch printing of multiple article requests slips To test: 1. apply this patch 2. restart_all 3. enable ArticleRequests preference 4. create multiple article requests 5. go to circ/article-requests.pl in staff interface 6. print a single slip from a row CHECK => it works as expected 7. select all rows and print slip from general actions menu (above the table) SUCCESS => all article requests slips are printed 8. select multiple rows (not all) and print slip from general actions menu (above the table) SUCCESS => only selected article requests slips are printed Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Created attachment 125882 [details] [review] Bug 27949: Allow multiple article requests print slip This bug allows for batch printing of multiple article requests slips To test: 1. apply this patch 2. restart_all 3. enable ArticleRequests preference 4. create multiple article requests 5. go to circ/article-requests.pl in staff interface 6. print a single slip from a row CHECK => it works as expected 7. select all rows and print slip from general actions menu (above the table) SUCCESS => all article requests slips are printed 8. select multiple rows (not all) and print slip from general actions menu (above the table) SUCCESS => only selected article requests slips are printed Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Created attachment 125883 [details] [review] Bug 27949: (QA follow-up) Remove TODO Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
+ $slipContent .= "<hr/>"; + $slipContent .= $slip->{is_html}?$slip->{content}:'<pre>'.$slip->{content}.'</pre>'; This is arbitrary, not configurable, and add html code in controller. That smells. I don't have a good suggestion right now however.
Created attachment 126263 [details] [review] Bug 27949: Allow multiple article requests print slip This bug allows for batch printing of multiple article requests slips To test: 1. apply this patch 2. restart_all 3. enable ArticleRequests preference 4. create multiple article requests 5. go to circ/article-requests.pl in staff interface 6. print a single slip from a row CHECK => it works as expected 7. select all rows and print slip from general actions menu (above the table) SUCCESS => all article requests slips are printed 8. select multiple rows (not all) and print slip from general actions menu (above the table) SUCCESS => only selected article requests slips are printed Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> JD amended patch: Perltidy!
Created attachment 126264 [details] [review] Bug 27949: Allow multiple article requests print slip This bug allows for batch printing of multiple article requests slips To test: 1. apply this patch 2. restart_all 3. enable ArticleRequests preference 4. create multiple article requests 5. go to circ/article-requests.pl in staff interface 6. print a single slip from a row CHECK => it works as expected 7. select all rows and print slip from general actions menu (above the table) SUCCESS => all article requests slips are printed 8. select multiple rows (not all) and print slip from general actions menu (above the table) SUCCESS => only selected article requests slips are printed Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> JD amended patch: Perltidy!
Created attachment 126265 [details] [review] Bug 27949: (QA follow-up) Remove TODO Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Pushed to master for 21.11, thanks to everybody involved!
(In reply to Jonathan Druart from comment #15) > + $slipContent .= "<hr/>"; > > + $slipContent .= > $slip->{is_html}?$slip->{content}:'<pre>'.$slip->{content}.'</pre>'; > > This is arbitrary, not configurable, and add html code in controller. That > smells. > > I don't have a good suggestion right now however. Do we open a follow-up bug report for that?
(In reply to Jonathan Druart from comment #20) > (In reply to Jonathan Druart from comment #15) > > + $slipContent .= "<hr/>"; > > > > + $slipContent .= > > $slip->{is_html}?$slip->{content}:'<pre>'.$slip->{content}.'</pre>'; > > > > This is arbitrary, not configurable, and add html code in controller. That > > smells. > > > > I don't have a good suggestion right now however. > > Do we open a follow-up bug report for that? How about the title of bug 29262 ?