Lines 330-340
sub SendAlerts {
Link Here
|
330 |
# FIXME: This 'default' behaviour should be moved to Koha::Email |
330 |
# FIXME: This 'default' behaviour should be moved to Koha::Email |
331 |
my $mail = Koha::Email->create( |
331 |
my $mail = Koha::Email->create( |
332 |
{ |
332 |
{ |
333 |
to => $email, |
333 |
to => $email, |
334 |
from => $library->branchemail, |
334 |
from => $library->branchemail, |
335 |
reply_to => $library->branchreplyto, |
335 |
reply_to => $library->branchreplyto, |
336 |
sender => $library->branchreturnpath, |
336 |
sender => $library->branchreturnpath, |
337 |
subject => "" . $letter->{title}, |
337 |
subject => "" . $letter->{title}, |
|
|
338 |
template_id => $letter->{id}, |
338 |
} |
339 |
} |
339 |
); |
340 |
); |
340 |
|
341 |
|
Lines 486-493
sub SendAlerts {
Link Here
|
486 |
cc => join( ',', @cc ), |
487 |
cc => join( ',', @cc ), |
487 |
( |
488 |
( |
488 |
( |
489 |
( |
489 |
C4::Context->preference("ClaimsBccCopy") |
490 |
C4::Context->preference("ClaimsBccCopy") && ( $type eq 'claimacquisition' |
490 |
&& ( $type eq 'claimacquisition' |
|
|
491 |
|| $type eq 'claimissues' ) |
491 |
|| $type eq 'claimissues' ) |
492 |
) |
492 |
) |
493 |
? ( bcc => $userenv->{emailaddress} ) |
493 |
? ( bcc => $userenv->{emailaddress} ) |
Lines 510-516
sub SendAlerts {
Link Here
|
510 |
: () |
510 |
: () |
511 |
) |
511 |
) |
512 |
), |
512 |
), |
513 |
subject => "" . $letter->{title}, |
513 |
subject => "" . $letter->{title}, |
|
|
514 |
template_id => $letter->{id}, |
514 |
} |
515 |
} |
515 |
); |
516 |
); |
516 |
|
517 |
|
Lines 1453-1459
sub _send_message_by_email {
Link Here
|
1453 |
from => $from_address, |
1454 |
from => $from_address, |
1454 |
reply_to => $message->{'reply_address'} || $branch_replyto, |
1455 |
reply_to => $message->{'reply_address'} || $branch_replyto, |
1455 |
sender => $branch_returnpath, |
1456 |
sender => $branch_returnpath, |
1456 |
subject => "" . $message->{subject} |
1457 |
subject => "" . $message->{subject}, |
|
|
1458 |
( |
1459 |
$message->{letter_id} |
1460 |
? ( template_id => $message->{letter_id} ) |
1461 |
: () |
1462 |
), |
1463 |
message_id => $message->{id} |
1457 |
}; |
1464 |
}; |
1458 |
|
1465 |
|
1459 |
if ( $message->{'content_type'} && $message->{'content_type'} eq SERIALIZED_EMAIL_CONTENT_TYPE ) { |
1466 |
if ( $message->{'content_type'} && $message->{'content_type'} eq SERIALIZED_EMAIL_CONTENT_TYPE ) { |
Lines 1464-1471
sub _send_message_by_email {
Link Here
|
1464 |
$email->create($params); |
1471 |
$email->create($params); |
1465 |
} else { |
1472 |
} else { |
1466 |
$email = Koha::Email->create($params); |
1473 |
$email = Koha::Email->create($params); |
1467 |
$email->header('X-Koha-Letter-Id', $message->{letter_id} ); |
|
|
1468 |
$email->header('X-Koha-Message-Id', $message->{id} ); |
1469 |
if ($is_html) { |
1474 |
if ($is_html) { |
1470 |
$email->html_body( _wrap_html( $content, $subject ) ); |
1475 |
$email->html_body( _wrap_html( $content, $subject ) ); |
1471 |
} else { |
1476 |
} else { |