&PrepareSerialsData &GetNextExpected &ModNextExpected
&GetPreviousSerialid
- &GetSuppliersWithLateIssues &getsupplierbyserialid
+ &GetSuppliersWithLateIssues
&GetDistributedTo &SetDistributedTo
&getroutinglist &delroutingmember &addroutingmember
&reorder_members
{}, CLAIMED, @$serialids );
}
-=head2 getsupplierbyserialid
-
-$result = getsupplierbyserialid($serialid)
-
-this function is used to find the supplier id given a serial id
-
-return :
-hashref containing serialid, subscriptionid, and aqbooksellerid
-
-=cut
-
-sub getsupplierbyserialid {
- my ($serialid) = @_;
- my $dbh = C4::Context->dbh;
- my $sth = $dbh->prepare(
- "SELECT serialid, serial.subscriptionid, aqbooksellerid
- FROM serial
- LEFT JOIN subscription ON serial.subscriptionid = subscription.subscriptionid
- WHERE serialid = ?
- "
- );
- $sth->execute($serialid);
- my $line = $sth->fetchrow_hashref;
- my $result = $line->{'aqbooksellerid'};
- return $result;
-}
-
=head2 check_routing
$result = &check_routing($subscriptionid)
use Koha::Acquisition::Booksellers;
use t::lib::Mocks;
use t::lib::TestBuilder;
-use Test::More tests => 49;
+use Test::More tests => 48;
BEGIN {
use_ok('C4::Serials');
is($late_or_missing_issues_1_2[0]->{status}, 3, 'Got the expected unchanged claim status from update claim');
};
-is(C4::Serials::getsupplierbyserialid(),undef, 'test getting supplier idea');
-
is(C4::Serials::check_routing(), undef, 'test checking route');
is(C4::Serials::addroutingmember(),undef, 'test adding route member');