=cut
sub CloseBasket {
my ($basketno, $edi_approval) = @_;
my ($basketno) = @_;
my $dbh = C4::Context->dbh;
$dbh->do('UPDATE aqbasket SET closedate=now() WHERE basketno=?', {}, $basketno );
# Log the closure
if (C4::Context->preference("AcqLog")) {
my $action = $edi_approval ? 'APPROVE_BASKET' : 'CLOSE_BASKET';
logaction(
'ACQUISITIONS',
$action,
'CLOSE_BASKET',
$basketno
);
}
use C4::Biblio qw( AddBiblio TransformKohaToMarc GetMarcBiblio GetFrameworkCode GetMarcFromKohaField );
use Koha::Edifact::Order;
use Koha::Edifact;
use C4::Log qw(logaction);
use Log::Log4perl;
use Text::Unidecode;
use Koha::Plugins::Handler;
basketno => $b,
# Close the basket, passing a flag indicating that this action
# Close the basket
# originated from an approval
CloseBasket($b);
CloseBasket($b, 1);
# Log the approval of this basket
'APPROVE_BASKET',
$b
-