Revision 94e11003
Von Moritz Bunkus vor mehr als 16 Jahren hinzugefügt
SL/IS.pm | ||
---|---|---|
970 | 970 |
|
971 | 971 |
Common::webdav_folder($form) if ($main::webdav); |
972 | 972 |
|
973 |
my @close_do_ids = map { $_ * 1 } grep { $_ } split m/\s+/, $form->{close_do_ids}; |
|
974 |
|
|
975 |
if (scalar @close_do_ids) { |
|
973 |
# Link this record to the records it was created from. |
|
974 |
RecordLinks->create_links('dbh' => $dbh, |
|
975 |
'mode' => 'ids', |
|
976 |
'from_table' => 'oe', |
|
977 |
'from_ids' => $form->{convert_from_oe_ids}, |
|
978 |
'to_table' => 'ar', |
|
979 |
'to_id' => $form->{id}, |
|
980 |
); |
|
981 |
delete $form->{convert_from_oe_ids}; |
|
982 |
|
|
983 |
my @convert_from_do_ids = map { $_ * 1 } grep { $_ } split m/\s+/, $form->{convert_from_do_ids}; |
|
984 |
|
|
985 |
if (scalar @convert_from_do_ids) { |
|
976 | 986 |
DO->close_orders('dbh' => $dbh, |
977 |
'ids' => \@close_do_ids); |
|
987 |
'ids' => \@convert_from_do_ids); |
|
988 |
|
|
989 |
RecordLinks->create_links('dbh' => $dbh, |
|
990 |
'mode' => 'ids', |
|
991 |
'from_table' => 'delivery_orders', |
|
992 |
'from_ids' => \@convert_from_do_ids, |
|
993 |
'to_table' => 'ar', |
|
994 |
'to_id' => $form->{id}, |
|
995 |
); |
|
978 | 996 |
} |
979 | 997 |
|
980 | 998 |
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.