Bugzilla – Attachment 117255 Details for
Bug 14233
Add logging support to notices and slips management
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14233: (follow-up) Fix for delete entire notice
Bug-14233-follow-up-Fix-for-delete-entire-notice.patch (text/plain), 1.64 KB, created by
Martin Renvoize (ashimema)
on 2021-02-24 13:01:58 UTC
(
hide
)
Description:
Bug 14233: (follow-up) Fix for delete entire notice
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2021-02-24 13:01:58 UTC
Size:
1.64 KB
patch
obsolete
>From 7c55b23be309cd9ce85902fd8ba50f359bce2217 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Thu, 11 Feb 2021 15:23:41 +0000 >Subject: [PATCH] Bug 14233: (follow-up) Fix for delete entire notice > >This fixes the overall notice delete option. >--- > tools/letter.pl | 20 +++++++++++--------- > 1 file changed, 11 insertions(+), 9 deletions(-) > >diff --git a/tools/letter.pl b/tools/letter.pl >index 4321f9ee81..1641f55252 100755 >--- a/tools/letter.pl >+++ b/tools/letter.pl >@@ -363,20 +363,22 @@ sub delete_confirm { > } > > sub delete_confirmed { >- my ($branchcode, $module, $code, $mtt, $lang) = @_; >- my $letter = Koha::Notice::Templates->find( >+ my ( $branchcode, $module, $code, $mtt, $lang ) = @_; >+ my $letters = Koha::Notice::Templates->search( > { >- branchcode => $branchcode || '', >- module => $module, >- code => $code, >- message_transport_type => $mtt, >- lang => $lang, >+ branchcode => $branchcode || '', >+ module => $module, >+ code => $code, >+ ( $mtt ? ( message_transport_type => $mtt ) : () ), >+ ( $lang ? ( lang => $lang ) : () ), > } > ); >- if ( $letter ) { >- logaction('NOTICES', 'DELETE', $letter->id, $letter->content, 'Intranet'); >+ while ( my $letter = $letters->next ) { >+ logaction( 'NOTICES', 'DELETE', $letter->id, $letter->content, >+ 'Intranet' ); > $letter->delete; > } >+ > # setup default display for screen > default_display($branchcode); > return; >-- >2.20.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 14233
:
116649
|
116650
|
116651
|
116660
|
116661
|
116662
|
116668
|
116671
|
116672
|
116673
|
116674
|
116713
|
116760
|
116761
|
117251
|
117252
|
117253
|
117254
|
117255
|
117256
|
117257
|
117258
|
117259
|
117294
|
117295
|
117296
|
117297
|
117298
|
117299
|
117300
|
117301
|
117302
|
117303
|
117304
|
117311
|
117312
|
117313
|
117314
|
117315
|
117316
|
117317
|
117318
|
117319
|
117320
|
117321
|
117345
|
118132
|
118133
|
118134
|
118135
|
118136
|
118137
|
118138
|
118139
|
118140
|
118141
|
118142
|
118143
|
118155
|
118156
|
118157
|
118158
|
118159
|
118160
|
118161
|
118162
|
118163
|
118164
|
118165
|
118166
|
118167
|
118323
|
119291
|
119292
|
119293
|
119294
|
119312
|
119313
|
119314
|
119315
|
119359
|
119360
|
119361
|
119362
|
119510