View | Details | Raw Unified | Return to bug 30300
Collapse All | Expand All

(-)a/Koha/Patron.pm (+1 lines)
Lines 2641-2646 sub queue_notice { Link Here
2641
        } );
2641
        } );
2642
        @message_transports = ( keys %{ $messaging_prefs->{transports} } );
2642
        @message_transports = ( keys %{ $messaging_prefs->{transports} } );
2643
        $letter_code = $messaging_prefs->{transports}->{$message_transports[0]} unless $letter_code;
2643
        $letter_code = $messaging_prefs->{transports}->{$message_transports[0]} unless $letter_code;
2644
        return if ($params->{message_name} eq 'Patron_Expiry' && !$messaging_prefs)
2644
    } else {
2645
    } else {
2645
        @message_transports = @{$params->{message_transports}};
2646
        @message_transports = @{$params->{message_transports}};
2646
    }
2647
    }
(-)a/misc/cronjobs/membership_expiry.pl (-14 / +1 lines)
Lines 262-286 while ( my $expiring_patron = $upcoming_mem_expires->next ) { Link Here
262
        next;
262
        next;
263
    }
263
    }
264
264
265
    my $messaging_prefs = C4::Members::Messaging::GetMessagingPreferences(
266
        {
267
            borrowernumber => $expiring_patron->borrowernumber,
268
            message_name   => "Patron_Expiry",
269
        }
270
    );
271
    my @message_transports = ( keys %{ $messaging_prefs->{transports} } );
272
    my $letter_code = $messaging_prefs->{letter_code};
273
274
    # Skip this patron if they don't want a notification email for card expiry
275
    next if !$messaging_prefs;
276
277
    my $which_notice;
265
    my $which_notice;
278
    if ($renew) {
266
    if ($renew) {
279
        $expiring_patron->renew_account;
267
        $expiring_patron->renew_account;
280
        $which_notice = $letter_renew;
268
        $which_notice = $letter_renew;
281
        $count_renewed++;
269
        $count_renewed++;
282
    } else {
270
    } else {
283
        $which_notice = $letter_code || $letter_expiry;
271
        $which_notice = $letter_expiry;
284
    }
272
    }
285
273
286
    my $from_address  = $expiring_patron->library->from_email_address;
274
    my $from_address  = $expiring_patron->library->from_email_address;
287
- 

Return to bug 30300