Revision b632cee8
Von Moritz Bunkus vor fast 12 Jahren hinzugefügt
SL/OE.pm | ||
---|---|---|
419 | 419 |
|
420 | 420 |
$reqdate = ($form->{"reqdate_$i"}) ? $form->{"reqdate_$i"} : undef; |
421 | 421 |
|
422 |
# get pricegroup_id and save ist |
|
422 |
# Get pricegroup_id and save it. Unfortunately the interface |
|
423 |
# also uses ID "0" for signalling that none is selected, but "0" |
|
424 |
# must not be stored in the database. Therefore we cannot simply |
|
425 |
# use conv_i(). |
|
423 | 426 |
($null, my $pricegroup_id) = split(/--/, $form->{"sellprice_pg_$i"}); |
424 | 427 |
$pricegroup_id *= 1; |
428 |
$pricegroup_id = undef if !$pricegroup_id; |
|
425 | 429 |
|
426 | 430 |
# save detail record in orderitems table |
427 | 431 |
my $orderitems_id = $form->{"orderitems_id_$i"}; |
... | ... | |
441 | 445 |
$form->{"qty_$i"}, $baseqty, |
442 | 446 |
$fxsellprice, $form->{"discount_$i"}, |
443 | 447 |
$form->{"unit_$i"}, conv_date($reqdate), conv_i($form->{"project_id_$i"}), |
444 |
$form->{"serialnumber_$i"}, $form->{"ship_$i"}, conv_i($pricegroup_id),
|
|
448 |
$form->{"serialnumber_$i"}, $form->{"ship_$i"}, $pricegroup_id,
|
|
445 | 449 |
$form->{"ordnumber_$i"}, conv_date($form->{"transdate_$i"}), |
446 | 450 |
$form->{"cusordnumber_$i"}, $form->{"subtotal_$i"} ? 't' : 'f', |
447 | 451 |
$form->{"marge_percent_$i"}, $form->{"marge_absolut_$i"}, |
Auch abrufbar als: Unified diff
InvoiceItem, OrderItem, DeliveryOrderItem: diverse Fremdschlüssel eingeführt