Bug 36122: NEW_SUGGESTION is sent for every modification to the suggestion

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 4ab5e6d29d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 866e1269b2)
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
Matthias Le Gac 2024-03-07 16:55:37 -05:00 committed by Lucas Gass
parent 185c0363ca
commit e0c08b6fd3

View file

@ -69,8 +69,7 @@ sub store {
my $emailpurchasesuggestions = C4::Context->preference("EmailPurchaseSuggestions"); my $emailpurchasesuggestions = C4::Context->preference("EmailPurchaseSuggestions");
my $result = $self->SUPER::store(); my $result = $self->SUPER::store();
if ( $emailpurchasesuggestions && $self->STATUS eq 'ASKED' ) {
if( $emailpurchasesuggestions ){
if ( if (
my $letter = C4::Letters::GetPreparedLetter( my $letter = C4::Letters::GetPreparedLetter(