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

(-)file_not_specified_in_diff (-1 lines)
Line  Link Here
C4::Acq::ModOrderItem routine
C4::Acq::ModOrderItem routine
Line 2 Link Here
2
--
3
C4/Acquisition.pm       | 33 +--------------------------------
91
C4/Acquisition.pm       | 33 +--------------------------------
4
cataloguing/moveitem.pl |  2 +-
92
cataloguing/moveitem.pl |  2 +-
5
2 files changed, 2 insertions(+), 33 deletions(-)
93
2 files changed, 2 insertions(+), 33 deletions(-)
(-)a/C4/Acquisition.pm (-32 / +1 lines)
Lines 59-65 BEGIN { Link Here
59
        &ModReceiveOrder &CancelReceipt
59
        &ModReceiveOrder &CancelReceipt
60
        &GetCancelledOrders
60
        &GetCancelledOrders
61
        &GetLastOrderNotReceivedFromSubscriptionid &GetLastOrderReceivedFromSubscriptionid
61
        &GetLastOrderNotReceivedFromSubscriptionid &GetLastOrderReceivedFromSubscriptionid
62
        &NewOrderItem &ModOrderItem &ModItemOrder
62
        &NewOrderItem &ModItemOrder
63
63
64
        &GetParcels &GetParcel
64
        &GetParcels &GetParcel
65
        &GetContracts &GetContract
65
        &GetContracts &GetContract
Lines 1225-1261 sub ModOrder { Link Here
1225
1225
1226
#------------------------------------------------------------#
1226
#------------------------------------------------------------#
1227
1227
1228
=head3 ModOrderItem
1229
1230
  &ModOrderItem(\%hashref);
1231
1232
Modifies the itemnumber in the aqorders_items table. The input hash needs three entities:
1233
1234
=over
1235
1236
=item - itemnumber: the old itemnumber
1237
=item - ordernumber: the order this item is attached to
1238
=item - newitemnumber: the new itemnumber we want to attach the line to
1239
1240
=back
1241
1242
=cut
1243
1244
sub ModOrderItem {
1245
    my $orderiteminfo = shift;
1246
    if (! $orderiteminfo->{'ordernumber'} || ! $orderiteminfo->{'itemnumber'} || ! $orderiteminfo->{'newitemnumber'}){
1247
        die "Ordernumber, itemnumber and newitemnumber is required";
1248
    }
1249
1250
    my $dbh = C4::Context->dbh;
1251
1252
    my $query = "UPDATE aqorders_items set itemnumber=? where itemnumber=? and ordernumber=?";
1253
    my @params = ($orderiteminfo->{'newitemnumber'}, $orderiteminfo->{'itemnumber'}, $orderiteminfo->{'ordernumber'});
1254
    my $sth = $dbh->prepare($query);
1255
    $sth->execute(@params);
1256
    return 0;
1257
}
1258
1259
=head3 ModItemOrder
1228
=head3 ModItemOrder
1260
1229
1261
    ModItemOrder($itemnumber, $ordernumber);
1230
    ModItemOrder($itemnumber, $ordernumber);
(-)a/cataloguing/moveitem.pl (-2 / +1 lines)
Lines 30-36 use C4::Context; Link Here
30
use C4::Koha;
30
use C4::Koha;
31
use C4::Branch;
31
use C4::Branch;
32
use C4::ClassSource;
32
use C4::ClassSource;
33
use C4::Acquisition qw/GetOrderFromItemnumber ModOrder GetOrder ModOrderItem/;
33
use C4::Acquisition qw/GetOrderFromItemnumber ModOrder GetOrder/;
34
34
35
use Date::Calc qw(Today);
35
use Date::Calc qw(Today);
36
36
37
- 

Return to bug 10504