Bugzilla – Attachment 118300 Details for
Bug 24295
C4::Circulation::GetTransfers should be removed, use Koha::Item->get_transfer instead
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
BUg 27896: Remove DeleteTransfer
BUg-27896-Remove-DeleteTransfer.patch (text/plain), 2.60 KB, created by
Martin Renvoize (ashimema)
on 2021-03-16 11:01:29 UTC
(
hide
)
Description:
BUg 27896: Remove DeleteTransfer
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2021-03-16 11:01:29 UTC
Size:
2.60 KB
patch
obsolete
>From 492fa6f3340446bf504576d13e08f63ebdc76de2 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Mon, 8 Mar 2021 15:30:09 +0000 >Subject: [PATCH] BUg 27896: Remove DeleteTransfer > >This patch removes the last mentions of DeleteTransfer > >Test plan >1/ Grep the codebase for DeleteTransfer >2/ It should no longer exist > >https://bugs.koha-community.org/show_bug.cgi?id=24295 >--- > C4/Circulation.pm | 19 ------------------- > t/db_dependent/Circulation/transfers.t | 7 ------- > 2 files changed, 26 deletions(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index c166341597..b7668bb191 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -120,7 +120,6 @@ BEGIN { > &GetTransfers > &GetTransfersFromTo > &updateWrongTransfer >- &DeleteTransfer > &IsBranchTransferAllowed > &CreateBranchTransferLimit > &DeleteBranchTransferLimits >@@ -3502,24 +3501,6 @@ sub GetTransfersFromTo { > return (@gettransfers); > } > >-=head2 DeleteTransfer >- >- &DeleteTransfer($itemnumber); >- >-=cut >- >-sub DeleteTransfer { >- my ($itemnumber) = @_; >- return unless $itemnumber; >- my $dbh = C4::Context->dbh; >- my $sth = $dbh->prepare( >- "DELETE FROM branchtransfers >- WHERE itemnumber=? >- AND datearrived IS NULL " >- ); >- return $sth->execute($itemnumber); >-} >- > =head2 SendCirculationAlert > > Send out a C<check-in> or C<checkout> alert using the messaging system. >diff --git a/t/db_dependent/Circulation/transfers.t b/t/db_dependent/Circulation/transfers.t >index c22992d381..19e5d86c40 100755 >--- a/t/db_dependent/Circulation/transfers.t >+++ b/t/db_dependent/Circulation/transfers.t >@@ -38,7 +38,6 @@ can_ok( > qw( > CreateBranchTransferLimit > DeleteBranchTransferLimits >- DeleteTransfer > GetTransfers > GetTransfersFromTo > ) >@@ -223,12 +222,6 @@ is( > is(C4::Circulation::DeleteBranchTransferLimits(),undef,"Without parameters DeleteBranchTransferLimit returns undef"); > is(C4::Circulation::DeleteBranchTransferLimits('B'),'0E0',"With a wrong id DeleteBranchTransferLimit returns 0E0"); > >-#Test DeleteTransfer >-is( C4::Circulation::DeleteTransfer($item_id1), >- 1, "A the item1's transfer has been deleted" ); >-is(C4::Circulation::DeleteTransfer(),undef,"Without itemid DeleteTransfer returns undef"); >-is(C4::Circulation::DeleteTransfer(-1),'0E0',"with a wrong itemid DeleteTranfer returns 0E0"); >- > #Test TransferSlip > is( C4::Circulation::TransferSlip($branchcode_1, undef, 5, $branchcode_2), > undef, "No tranferslip if invalid or undef itemnumber or barcode" ); >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 24295
:
118242
|
118243
|
118244
|
118245
|
118246
|
118247
|
118248
|
118249
|
118250
|
118287
|
118295
|
118296
|
118297
|
118298
|
118299
|
118300
|
118301
|
118302
|
118303
|
118304
|
118305
|
118306
|
118307
|
118308
|
118309
|
118310
|
119854
|
119855
|
119856
|
119857
|
119858
|
119859
|
119860
|
119861
|
119862
|
119863
|
119864
|
119866
|
119867
|
127465
|
127466
|
127467
|
127468
|
127469
|
127470
|
127471
|
127472
|
127473
|
127474
|
127475
|
127476
|
127477
|
130430
|
130431
|
130432
|
130433
|
130434
|
130435
|
130436
|
130437
|
130438
|
130439
|
130440
|
130441
|
130442
|
139546
|
139547
|
139548
|
139549
|
139550
|
139551
|
139552
|
139553
|
139554
|
139555
|
139556
|
139557
|
139558
|
139655
|
139656
|
139657
|
139658
|
139659
|
139660
|
139661
|
139662
|
139663
|
139664
|
139665
|
139666
|
139667