Erzueugnisse mit Preisfaktoren beim laden mit auslesen.
authorSven Schöling <s.schoeling@linet-services.de>
Thu, 14 May 2009 16:24:09 +0000 (16:24 +0000)
committerSven Schöling <s.schoeling@linet-services.de>
Thu, 14 May 2009 16:24:09 +0000 (16:24 +0000)
SL/IC.pm

index 7843665..a936034 100644 (file)
--- a/SL/IC.pm
+++ b/SL/IC.pm
@@ -80,10 +80,11 @@ sub get_part {
     $query =
       qq|SELECT p.id, p.partnumber, p.description,
            p.sellprice, p.lastcost, p.weight, a.qty, a.bom, p.unit,
-           pg.partsgroup
+           pg.partsgroup, p.price_factor_id, pfac.factor AS price_factor
          FROM parts p
          JOIN assembly a ON (a.parts_id = p.id)
          LEFT JOIN partsgroup pg ON (p.partsgroup_id = pg.id)
+         LEFT JOIN price_factors pfac ON pfac.id = p.price_factor_id
          WHERE (a.id = ?)
          ORDER BY $oid{$myconfig->{dbdriver}}|;
     $sth = prepare_execute_query($form, $dbh, $query, conv_i($form->{id}));