Bugzilla – Attachment 120310 Details for
Bug 14723
Additional delivery notes to messages
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14723: Make delivery notes translatable
0002-Bug-14723-Make-delivery-notes-translatable.patch (text/plain), 3.78 KB, created by
Emmi Takkinen
on 2021-04-29 12:02:32 UTC
(
hide
)
Description:
Bug 14723: Make delivery notes translatable
Filename:
MIME Type:
Creator:
Emmi Takkinen
Created:
2021-04-29 12:02:32 UTC
Size:
3.78 KB
patch
obsolete
>From 1e3761f473ede2f3135d12285c681ed722177af9 Mon Sep 17 00:00:00 2001 >From: Emmi Takkinen <emmi.takkinen@outlook.com> >Date: Thu, 14 May 2020 12:32:13 +0300 >Subject: [PATCH 2/3] Bug 14723: Make delivery notes translatable > >Delivery notes weren't translatable. This patch adds >them in notices.tt. If note is Mail::Sendmail error generic >'Error occured while sending email' is shown. > >Also fixes MySQLisms and adds AFTER to atomicupdate file. > >To test prove t/db_dependent/Letters.t > >Sponsored-by: Koha-Suomi Oy > >Signed-off-by: Stina Hallin <stina.hallin@ub.lu.se> >--- > C4/Letters.pm | 2 +- > ...4723_-_Additional_delivery_notes_to_messages.perl | 2 +- > .../intranet-tmpl/prog/en/modules/members/notices.tt | 12 +++++++++++- > 3 files changed, 13 insertions(+), 3 deletions(-) > >diff --git a/C4/Letters.pm b/C4/Letters.pm >index a2c63cb2e7..d9a7ea8d8b 100644 >--- a/C4/Letters.pm >+++ b/C4/Letters.pm >@@ -965,7 +965,7 @@ sub EnqueueLetter { > INSERT INTO message_queue > ( borrowernumber, subject, content, metadata, letter_code, message_transport_type, status, time_queued, to_address, from_address, reply_address, content_type, delivery_note ) > VALUES >-( ?, ?, ?, ?, ?, ?, ?, NOW(), ?, ?, ?, ?, ? ) >+( ?, ?, ?, ?, ?, ?, ?, CAST(NOW() AS DATE), ?, ?, ?, ?, ? ) > ENDSQL > > my $sth = $dbh->prepare($statement); >diff --git a/installer/data/mysql/atomicupdate/Bug-14723_-_Additional_delivery_notes_to_messages.perl b/installer/data/mysql/atomicupdate/Bug-14723_-_Additional_delivery_notes_to_messages.perl >index 5f03d8200d..3d3098c504 100644 >--- a/installer/data/mysql/atomicupdate/Bug-14723_-_Additional_delivery_notes_to_messages.perl >+++ b/installer/data/mysql/atomicupdate/Bug-14723_-_Additional_delivery_notes_to_messages.perl >@@ -1,6 +1,6 @@ > $DBversion = 'XXX'; # will be replaced by the RM > if( CheckVersion( $DBversion ) ) { >- $dbh->do("ALTER TABLE message_queue ADD delivery_note mediumtext"); >+ $dbh->do("ALTER TABLE message_queue ADD delivery_note mediumtext AFTER content_type"); > > # Always end with this (adjust the bug info) > SetVersion( $DBversion ); >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt >index f14231707a..e6db22d3c3 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt >@@ -91,7 +91,17 @@ > </td> > <td data-order="[% QUEUED_MESSAGE.updated_on | html %]">[% QUEUED_MESSAGE.updated_on | $KohaDates with_hours => 1 %]</td> > <td data-order="[% QUEUED_MESSAGE.time_queued | html %]">[% QUEUED_MESSAGE.time_queued | $KohaDates with_hours => 1 %]</td> >- <td>[% QUEUED_MESSAGE.delivery_note | html %]</td> >+ <td> >+ [% IF ( QUEUED_MESSAGE.delivery_note ) %] >+ [% IF ( QUEUED_MESSAGE.delivery_note == "Invalid borrowernumber $borrowernumber" ) %]Invalid borrowernumber [% borrowernumber | html %] >+ [% ELSIF ( QUEUED_MESSAGE.delivery_note == 'Unable to find an email address for this borrower' ) %]Unable to find an email address for this borrower >+ [% ELSIF ( QUEUED_MESSAGE.delivery_note == 'Missing SMS number' ) %]Missing SMS number >+ [% ELSIF ( QUEUED_MESSAGE.delivery_note == 'Message is duplicate' ) %]Message is duplicate >+ [% ELSIF ( QUEUED_MESSAGE.delivery_note == 'No notes from SMS driver' ) %]No notes from SMS driver >+ [% ELSE %]Error occured while sending email. >+ [% END %] >+ [% END %] >+ </td> > </tr> > [% END %] > </tbody> >-- >2.25.1 >
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 14723
:
42053
|
42074
|
42159
|
42170
|
42227
|
42228
|
42384
|
42453
|
42455
|
42466
|
42505
|
42553
|
42574
|
42668
|
42669
|
44367
|
44413
|
62080
|
62138
|
78313
|
87525
|
87531
|
105776
|
105777
|
116642
|
116643
|
118225
|
120252
|
120309
|
120310
|
120312
|
120314
|
120376
|
120487
|
120488
|
120489
|
120490
|
120491
|
120492
|
120667