From: Sven Schöling Date: Wed, 9 Sep 2009 10:54:44 +0000 (+0200) Subject: Lagerbestandanzeige in OE Masken X-Git-Tag: release-2.6.1beta1~288 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=cc3a0a3304ae358dd42ed24578823336dccda187;p=kivitendo-erp.git Lagerbestandanzeige in OE Masken --- diff --git a/SL/IC.pm b/SL/IC.pm index e3879a448..d78ad30b0 100644 --- a/SL/IC.pm +++ b/SL/IC.pm @@ -1561,7 +1561,7 @@ sub get_basic_part_info { my $dbh = $form->get_standard_dbh($myconfig); - my $query = qq|SELECT id, partnumber, description, unit FROM parts WHERE id IN (| . join(', ', ('?') x scalar(@ids)) . qq|)|; + my $query = qq|SELECT * FROM parts WHERE id IN (| . join(', ', ('?') x scalar(@ids)) . qq|)|; my $info = selectall_hashref_query($form, $dbh, $query, map { conv_i($_) } @ids); diff --git a/bin/mozilla/io.pl b/bin/mozilla/io.pl index 25427f71d..f8d73005a 100644 --- a/bin/mozilla/io.pl +++ b/bin/mozilla/io.pl @@ -337,6 +337,19 @@ sub display_row { if $form->{"id_$i"} && ($form->{type} =~ /^sales_/ || $form->{type} =~ /invoice/) && !$is_delivery_order; # / marge calculations ending +# calculate onhand + if ($form->{"id_$i"}) { + my $part = IC->get_basic_part_info(id => $form->{"id_$i"}); + my $onhand_color = 'color="#ff0000"' if $part->{onhand} < $part->{rop}; + push @ROW2, { value => sprintf "%s %s %s", + $locale->text('On Hand'), + $onhand_color, + $form->format_amount(\%myconfig, $part->{onhand}, 2), + $part->{unit} + }; + } +# / calculate onhand + my @hidden_vars; if ($is_delivery_order) { diff --git a/locale/de/dn b/locale/de/dn index c109b67d4..a4896c7c8 100644 --- a/locale/de/dn +++ b/locale/de/dn @@ -167,6 +167,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'OpenDocument/OASIS' => 'OpenDocument/OASIS', 'Order Date missing!' => 'Auftragsdatum fehlt!', 'Order Number missing!' => 'Auftragsnummer fehlt!', diff --git a/locale/de/do b/locale/de/do index 8e6d41d2d..b036f6cc1 100644 --- a/locale/de/do +++ b/locale/de/do @@ -172,6 +172,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'Open' => 'Offen', 'OpenDocument/OASIS' => 'OpenDocument/OASIS', 'Order' => 'Auftrag', diff --git a/locale/de/io b/locale/de/io index f10010567..a3529f420 100644 --- a/locale/de/io +++ b/locale/de/io @@ -144,6 +144,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'OpenDocument/OASIS' => 'OpenDocument/OASIS', 'Order Date missing!' => 'Auftragsdatum fehlt!', 'Order Number missing!' => 'Auftragsnummer fehlt!', diff --git a/locale/de/ir b/locale/de/ir index 7b37bc79f..07797d627 100644 --- a/locale/de/ir +++ b/locale/de/ir @@ -183,6 +183,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'OpenDocument/OASIS' => 'OpenDocument/OASIS', 'Order Date' => 'Auftragsdatum', 'Order Date missing!' => 'Auftragsdatum fehlt!', diff --git a/locale/de/is b/locale/de/is index 398c95b3a..ff1936e00 100644 --- a/locale/de/is +++ b/locale/de/is @@ -200,6 +200,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'OpenDocument/OASIS' => 'OpenDocument/OASIS', 'Order' => 'Auftrag', 'Order Date' => 'Auftragsdatum', diff --git a/locale/de/login b/locale/de/login index 1a66e0027..06d2385fb 100644 --- a/locale/de/login +++ b/locale/de/login @@ -219,6 +219,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'Only due follow-ups' => 'Nur fällige Wiedervorlagen', 'Open' => 'Offen', 'OpenDocument/OASIS' => 'OpenDocument/OASIS', diff --git a/locale/de/oe b/locale/de/oe index 1043f4846..93c36e714 100644 --- a/locale/de/oe +++ b/locale/de/oe @@ -200,6 +200,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'Open' => 'Offen', 'OpenDocument/OASIS' => 'OpenDocument/OASIS', 'Order' => 'Auftrag', diff --git a/locale/de/todo b/locale/de/todo index 5009eb7a5..1090cb95e 100644 --- a/locale/de/todo +++ b/locale/de/todo @@ -216,6 +216,7 @@ $self->{texts} = { 'Number missing in Row' => 'Nummer fehlt in Zeile', 'Oct' => 'Okt', 'October' => 'Oktober', + 'On Hand' => 'Auf Lager', 'Only due follow-ups' => 'Nur fällige Wiedervorlagen', 'Open' => 'Offen', 'OpenDocument/OASIS' => 'OpenDocument/OASIS',