Bugzilla – Attachment 37832 Details for
Bug 11603
Gather print notices: add csv and ods export
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] Bug 11603: If a letter code is given, filenames should contain it
SIGNED-OFF-Bug-11603-If-a-letter-code-is-given-fil.patch (text/plain), 1.89 KB, created by
Frédéric Demians
on 2015-04-14 18:40:35 UTC
(
hide
)
Description:
[SIGNED-OFF] Bug 11603: If a letter code is given, filenames should contain it
Filename:
MIME Type:
Creator:
Frédéric Demians
Created:
2015-04-14 18:40:35 UTC
Size:
1.89 KB
patch
obsolete
>From eae1a55e9c5fced6bafbedc300ac7aa81e386220 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Wed, 26 Feb 2014 13:35:42 +0100 >Subject: [PATCH] [SIGNED-OFF] Bug 11603: If a letter code is given, filenames > should contain it > >If you choose to generate print notices for a specific letter code, the >generated files should be distinct. > >The use case is: you want to process print notice for letter codes: >overdue1, overdue2 and overdue3. > >The cronjobs will be: > >perl misc/cronjobs/gather_print_notices.pl >/tmp --letter_code=overdue1 --csv --ods --html --delimiter=";" > >perl misc/cronjobs/gather_print_notices.pl >/tmp --letter_code=overdue2 --csv --ods --html --delimiter=";" > >perl misc/cronjobs/gather_print_notices.pl >/tmp --letter_code=overdue3 --csv --ods --html --delimiter=";" > >without this patch, the 2 first files will be erased. > >Signed-off-by: Frederic Demians <f.demians@tamil.fr> >--- > misc/cronjobs/gather_print_notices.pl | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > >diff --git a/misc/cronjobs/gather_print_notices.pl b/misc/cronjobs/gather_print_notices.pl >index 883ca30..890c8ce 100755 >--- a/misc/cronjobs/gather_print_notices.pl >+++ b/misc/cronjobs/gather_print_notices.pl >@@ -130,10 +130,10 @@ sub print_notices { > } > > while ( my ( $branchcode, $branch_messages ) = each %$messages_by_branch ) { >+ my $letter_code = @letter_codes == 1 ? $letter_codes[0] : 'hold'; > my $filename = $split >- ? 'holdnotices-' . $today->output('iso') . "-$branchcode.$format" >- : 'holdnotices-' . $today->output('iso') . ".$format"; >- >+ ? "notices_$letter_code-" . $today->output('iso') . "-$branchcode.$format" >+ : "notices_$letter_code-" . $today->output('iso') . ".$format"; > my $filepath = File::Spec->catdir( $output_directory, $filename ); > if ( $format eq 'html' ) { > generate_html({ >-- >2.3.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 11603
:
25021
|
25022
|
25023
|
25024
|
25640
|
25642
|
30980
|
30981
|
30982
|
30983
|
37799
|
37812
|
37813
|
37814
|
37815
|
37816
|
37817
|
37829
|
37830
|
37831
|
37832
|
37833
|
37834
|
37837
|
38381
|
38385
|
38386
|
38387
|
38388
|
38389
|
38390
|
38391
|
38392
|
38403
|
38411
|
38412
|
38413
|
38414
|
38415
|
38416
|
38417
|
38418
|
38419
|
39033
|
39034
|
39035
|
39036
|
39037
|
39038
|
39039
|
39040
|
39041