Revision aff32344
Von Moritz Bunkus vor fast 11 Jahren hinzugefügt
SL/OE.pm | ||
---|---|---|
46 | 46 |
use SL::DB::Tax; |
47 | 47 |
use SL::DBUtils; |
48 | 48 |
use SL::IC; |
49 |
use SL::TransNumber; |
|
49 | 50 |
|
50 | 51 |
use strict; |
51 | 52 |
|
... | ... | |
314 | 315 |
|
315 | 316 |
my $ml = ($form->{type} eq 'sales_order') ? 1 : -1; |
316 | 317 |
|
318 |
my $number_field = $form->{type} =~ m{order} ? 'ordnumber' : 'quonumber'; |
|
319 |
my $trans_number = SL::TransNumber->new(type => $form->{type}, dbh => $dbh, number => $form->{$number_field}, id => $form->{id}); |
|
320 |
$form->{$number_field} ||= $trans_number->create_unique; |
|
321 |
|
|
317 | 322 |
if ($form->{id}) { |
318 | 323 |
$query = qq|DELETE FROM custom_variables |
319 | 324 |
WHERE (config_id IN (SELECT id FROM custom_variable_configs WHERE module = 'IC')) |
Auch abrufbar als: Unified diff
OE.pm: SL::TransNumber anstelle von Form->update_defaults für Nummernkreise nutzen