Bug 15503 - Populate the order prices
authorKyle M Hall <kyle@bywatersolutions.com>
Tue, 24 Jan 2017 16:15:35 +0000 (08:15 -0800)
committerKyle M Hall <kyle@bywatersolutions.com>
Tue, 14 Feb 2017 15:11:03 +0000 (15:11 +0000)
Signed-off-by: Benjamin Daeuber <bdaeuber@cityoffargo.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
acqui/addorderiso2709.pl

index ce57113..b0a74d1 100755 (executable)
@@ -287,6 +287,18 @@ if ($op eq ""){
 
                     # remove uncertainprice flag if we have found a price in the MARC record
                     $orderinfo{uncertainprice} = 0 if $orderinfo{listprice};
+
+                    %orderinfo = %{
+                        C4::Acquisition::populate_order_with_prices(
+                            {
+                                order        => \%orderinfo,
+                                booksellerid => $booksellerid,
+                                ordering     => 1,
+                                receiving    => 1,
+                            }
+                        )
+                    };
+
                     my $order = Koha::Acquisition::Order->new( \%orderinfo )->insert;
                 }
             }