Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
solves my comment 89: when you have a "mandatory" notice defined for a given library, it's not possible to delete it (and switch back to the "default" notification). isn't this a (small) bug ? was it intended ?
thanks!
sub SendAlerts {
my ( $type, $externalid, $letter_code ) = @_;
my $dbh = C4::Context->dbh;
- my $strsth;
if ( $type eq 'issue' ) {
# prepare the letter...
# prepare the letter...
# search the biblionumber
- $strsth = $type eq 'claimacquisition'
+ my $strsth = $type eq 'claimacquisition'
? qq{
SELECT aqorders.*,aqbasket.*,biblio.*,biblioitems.*,aqbooksellers.*
FROM aqorders
my $loop_data = [];
my $protected_letters = protected_letters();
foreach my $row (@{$results}) {
- $row->{protected} = $protected_letters->{ $row->{code}};
+ $row->{protected} = !$row->{branchcode} && $protected_letters->{ $row->{code} };
push @{$loop_data}, $row;
}