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

(-)a/C4/Acquisition.pm (-3 / +2 lines)
Lines 224-230 close a basket (becomes unmodifiable, except for receives) Link Here
224
=cut
224
=cut
225
225
226
sub CloseBasket {
226
sub CloseBasket {
227
    my ($basketno, $edi_approval) = @_;
227
    my ($basketno) = @_;
228
    my $dbh        = C4::Context->dbh;
228
    my $dbh        = C4::Context->dbh;
229
    $dbh->do('UPDATE aqbasket SET closedate=now() WHERE basketno=?', {}, $basketno );
229
    $dbh->do('UPDATE aqbasket SET closedate=now() WHERE basketno=?', {}, $basketno );
230
230
Lines 235-244 q{UPDATE aqorders SET orderstatus = 'ordered' WHERE basketno = ? AND orderstatus Link Here
235
235
236
    # Log the closure
236
    # Log the closure
237
    if (C4::Context->preference("AcqLog")) {
237
    if (C4::Context->preference("AcqLog")) {
238
        my $action = $edi_approval ? 'APPROVE_BASKET' : 'CLOSE_BASKET';
239
        logaction(
238
        logaction(
240
            'ACQUISITIONS',
239
            'ACQUISITIONS',
241
            $action,
240
            'CLOSE_BASKET',
242
            $basketno
241
            $basketno
243
        );
242
        );
244
    }
243
    }
(-)a/Koha/EDI.pm (-4 / +11 lines)
Lines 33-38 use C4::Suggestions qw( ModSuggestion ); Link Here
33
use C4::Biblio qw( AddBiblio TransformKohaToMarc GetMarcBiblio GetFrameworkCode GetMarcFromKohaField );
33
use C4::Biblio qw( AddBiblio TransformKohaToMarc GetMarcBiblio GetFrameworkCode GetMarcFromKohaField );
34
use Koha::Edifact::Order;
34
use Koha::Edifact::Order;
35
use Koha::Edifact;
35
use Koha::Edifact;
36
use C4::Log qw(logaction);
36
use Log::Log4perl;
37
use Log::Log4perl;
37
use Text::Unidecode;
38
use Text::Unidecode;
38
use Koha::Plugins::Handler;
39
use Koha::Plugins::Handler;
Lines 592-600 sub process_quote { Link Here
592
                    basketno => $b,
593
                    basketno => $b,
593
                }
594
                }
594
            );
595
            );
595
            # Close the basket, passing a flag indicating that this action
596
            # Close the basket
596
            # originated from an approval
597
            CloseBasket($b);
597
            CloseBasket($b, 1);
598
            # Log the approval of this basket
599
            if (C4::Context->preference("AcqLog")) {
600
                logaction(
601
                    'ACQUISITIONS',
602
                    'APPROVE_BASKET',
603
                    $b
604
                );
605
            }
598
        }
606
        }
599
    }
607
    }
600
608
601
- 

Return to bug 23971