Revision 6d3c1977
Von Sven Schöling vor etwa 10 Jahren hinzugefügt
SL/IR.pm | ||
---|---|---|
382 | 382 |
qq|INSERT INTO invoice (id, trans_id, parts_id, description, longdescription, qty, base_qty, |
383 | 383 |
sellprice, fxsellprice, discount, allocated, unit, deliverydate, |
384 | 384 |
project_id, serialnumber, price_factor_id, price_factor, marge_price_factor) |
385 |
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, (SELECT factor FROM price_factors WHERE id = ?), ?)|; |
|
385 |
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, (SELECT factor FROM price_factors WHERE id = ?), ?, ?)|;
|
|
386 | 386 |
@values = ($invoice_id, conv_i($form->{id}), conv_i($form->{"id_$i"}), |
387 | 387 |
$form->{"description_$i"}, $restricter->process($form->{"longdescription_$i"}), $form->{"qty_$i"} * -1, |
388 | 388 |
$baseqty * -1, $form->{"sellprice_$i"}, $fxsellprice, $form->{"discount_$i"}, $allocated, |
389 | 389 |
$form->{"unit_$i"}, conv_date($form->{deliverydate}), |
390 | 390 |
conv_i($form->{"project_id_$i"}), $form->{"serialnumber_$i"}, |
391 |
conv_i($form->{"price_factor_id_$i"}), conv_i($form->{"price_factor_id_$i"}), conv_i($form->{"marge_price_factor_$i"})); |
|
391 |
conv_i($form->{"price_factor_id_$i"}), conv_i($form->{"price_factor_id_$i"}), conv_i($form->{"marge_price_factor_$i"}), |
|
392 |
conv_i($form->{"active_price_source_$i"}), |
|
393 |
); |
|
392 | 394 |
do_query($form, $dbh, $query, @values); |
393 | 395 |
|
394 | 396 |
CVar->save_custom_variables(module => 'IC', |
... | ... | |
976 | 978 |
|
977 | 979 |
i.id AS invoice_id, |
978 | 980 |
i.description, i.longdescription, i.qty, i.fxsellprice AS sellprice, i.parts_id AS id, i.unit, i.deliverydate, i.project_id, i.serialnumber, |
979 |
i.price_factor_id, i.price_factor, i.marge_price_factor, i.discount, |
|
981 |
i.price_factor_id, i.price_factor, i.marge_price_factor, i.discount, i.active_price_source,
|
|
980 | 982 |
p.partnumber, p.inventory_accno_id AS part_inventory_accno_id, pr.projectnumber, pg.partsgroup |
981 | 983 |
|
982 | 984 |
FROM invoice i |
SL/IS.pm | ||
---|---|---|
761 | 761 |
sellprice, fxsellprice, discount, allocated, assemblyitem, |
762 | 762 |
unit, deliverydate, project_id, serialnumber, pricegroup_id, |
763 | 763 |
ordnumber, donumber, transdate, cusordnumber, base_qty, subtotal, |
764 |
marge_percent, marge_total, lastcost, |
|
764 |
marge_percent, marge_total, lastcost, active_price_source,
|
|
765 | 765 |
price_factor_id, price_factor, marge_price_factor) |
766 |
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, |
|
766 |
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
|
|
767 | 767 |
(SELECT factor FROM price_factors WHERE id = ?), ?)|; |
768 | 768 |
|
769 | 769 |
@values = ($invoice_id, conv_i($form->{id}), conv_i($form->{"id_$i"}), |
... | ... | |
776 | 776 |
$form->{"cusordnumber_$i"}, $baseqty, $form->{"subtotal_$i"} ? 't' : 'f', |
777 | 777 |
$form->{"marge_percent_$i"}, $form->{"marge_absolut_$i"}, |
778 | 778 |
$form->{"lastcost_$i"}, |
779 |
$form->{"active_price_source_$i"}, |
|
779 | 780 |
conv_i($form->{"price_factor_id_$i"}), conv_i($form->{"price_factor_id_$i"}), |
780 | 781 |
conv_i($form->{"marge_price_factor_$i"})); |
781 | 782 |
do_query($form, $dbh, $query, @values); |
... | ... | |
1677 | 1678 |
i.id AS invoice_id, |
1678 | 1679 |
i.description, i.longdescription, i.qty, i.fxsellprice AS sellprice, i.discount, i.parts_id AS id, i.unit, i.deliverydate AS reqdate, |
1679 | 1680 |
i.project_id, i.serialnumber, i.id AS invoice_pos, i.pricegroup_id, i.ordnumber, i.donumber, i.transdate, i.cusordnumber, i.subtotal, i.lastcost, |
1680 |
i.price_factor_id, i.price_factor, i.marge_price_factor, |
|
1681 |
i.price_factor_id, i.price_factor, i.marge_price_factor, i.active_price_source,
|
|
1681 | 1682 |
p.partnumber, p.assembly, p.notes AS partnotes, p.inventory_accno_id AS part_inventory_accno_id, p.formel, p.listprice, |
1682 | 1683 |
pr.projectnumber, pg.partsgroup, prg.pricegroup |
1683 | 1684 |
|
Auch abrufbar als: Unified diff
PriceSource: bei Rechnungen mitspeichern