Lines 456-479
sub set_cancelled {
Link Here
|
456 |
|
456 |
|
457 |
# send notice to recaller to pick up item |
457 |
# send notice to recaller to pick up item |
458 |
my $letter = C4::Letters::GetPreparedLetter( |
458 |
my $letter = C4::Letters::GetPreparedLetter( |
459 |
module => 'circulation', |
459 |
module => 'circulation', |
460 |
letter_code => 'RECALL_MANUAL_CANCEL', |
460 |
letter_code => 'RECALL_MANUAL_CANCEL', |
461 |
branchcode => $self->pickup_library_id, |
461 |
branchcode => $self->pickup_library_id, |
462 |
lang => $self->patron->lang, |
462 |
lang => $self->patron->lang, |
463 |
tables => { |
463 |
tables => { |
464 |
biblio => $self->biblio_id, |
464 |
biblio => $self->biblio_id, |
465 |
borrowers => $self->patron_id, |
465 |
borrowers => $self->patron_id, |
466 |
branches => $self->pickup_library_id, |
466 |
branches => $self->pickup_library_id, |
467 |
}, |
467 |
}, |
468 |
); |
468 |
); |
469 |
|
469 |
|
470 |
my $messaging_preferences = C4::Members::Messaging::GetMessagingPreferences({ borrowernumber => $self->patron_id, message_name => 'Recall_Cancelled' }); |
470 |
my $messaging_preferences = C4::Members::Messaging::GetMessagingPreferences( |
|
|
471 |
{ borrowernumber => $self->patron_id, message_name => 'Recall_Cancelled' } ); |
471 |
while ( my ( $transport, $letter_code ) = each %{ $messaging_preferences->{transports} } ) { |
472 |
while ( my ( $transport, $letter_code ) = each %{ $messaging_preferences->{transports} } ) { |
472 |
if ( $transport eq 'email' ){ |
473 |
if ( $transport eq 'email' ) { |
473 |
C4::Message->enqueue($letter, $self->patron->unblessed, 'email'); |
474 |
C4::Message->enqueue( $letter, $self->patron, 'email' ); |
474 |
} |
475 |
} |
475 |
if ( $transport eq 'sms' ){ |
476 |
if ( $transport eq 'sms' ) { |
476 |
C4::Message->enqueue($letter, $self->patron->unblessed, 'sms'); |
477 |
C4::Message->enqueue( $letter, $self->patron, 'sms' ); |
477 |
} |
478 |
} |
478 |
} |
479 |
} |
479 |
|
480 |
|