Revision 94e11003
Von Moritz Bunkus vor mehr als 16 Jahren hinzugefügt
SL/IR.pm | ||
---|---|---|
539 | 539 |
|
540 | 540 |
Common::webdav_folder($form) if ($main::webdav); |
541 | 541 |
|
542 |
my @close_do_ids = map { $_ * 1 } grep { $_ } split m/\s+/, $form->{close_do_ids}; |
|
543 |
if (scalar @close_do_ids) { |
|
542 |
# Link this record to the records it was created from. |
|
543 |
RecordLinks->create_links('dbh' => $dbh, |
|
544 |
'mode' => 'ids', |
|
545 |
'from_table' => 'oe', |
|
546 |
'from_ids' => $form->{convert_from_oe_ids}, |
|
547 |
'to_table' => 'ap', |
|
548 |
'to_id' => $form->{id}, |
|
549 |
); |
|
550 |
delete $form->{convert_from_oe_ids}; |
|
551 |
|
|
552 |
my @convert_from_do_ids = map { $_ * 1 } grep { $_ } split m/\s+/, $form->{convert_from_do_ids}; |
|
553 |
if (scalar @convert_from_do_ids) { |
|
544 | 554 |
DO->close_orders('dbh' => $dbh, |
545 |
'ids' => \@close_do_ids); |
|
555 |
'ids' => \@convert_from_do_ids); |
|
556 |
|
|
557 |
RecordLinks->create_links('dbh' => $dbh, |
|
558 |
'mode' => 'ids', |
|
559 |
'from_table' => 'delivery_orders', |
|
560 |
'from_ids' => \@convert_from_do_ids, |
|
561 |
'to_table' => 'ap', |
|
562 |
'to_id' => $form->{id}, |
|
563 |
); |
|
546 | 564 |
} |
547 | 565 |
|
548 | 566 |
my $rc = 1; |
Auch abrufbar als: Unified diff
Beim Umwandeln von Angeboten/Preisanfragen in Aufträge die IDs in record_links speichern. Beim Umwandeln von Aufträgen und Lieferscheinen in Rechnungen die IDs in record_links speichern.