From 3af1d16a776c63cdcf624bcc3eba3e8738ff0ccd Mon Sep 17 00:00:00 2001 From: =?utf8?q?Sven=20Sch=C3=B6ling?= Date: Thu, 2 Sep 2010 11:28:29 +0200 Subject: [PATCH] Kommissionenrest in SL::DB::Part entfernt. --- SL/DB/Part.pm | 31 ------------------------------- 1 file changed, 31 deletions(-) diff --git a/SL/DB/Part.pm b/SL/DB/Part.pm index 6ea2be9b1..8c82e8a44 100644 --- a/SL/DB/Part.pm +++ b/SL/DB/Part.pm @@ -63,37 +63,6 @@ sub get_ordered_qty { return $result{ $self->id }; } -sub get_uncommissioned_qty { - my $self = shift; - my %params = @_; - - confess "Missing part id" unless $self->id; - - my $query = < 0)), - 0) - - - COALESCE((SELECT SUM(i.qty) AS qty - FROM inventory i - LEFT JOIN warehouse wh ON (i.warehouse_id = wh.id) - WHERE (i.parts_id = ?) - AND COALESCE(wh.commission)), - 0) - AS qty -SQL - - my $result = selectfirst_hashref_query($::form, $self->dbh, $query, $self->id, $self->id); - return $result ? $result->{qty} : 0; -} - sub available_units { shift->unit_obj->convertible_units; } -- 2.20.1