Revision b9f16639
Von Werner Hahn vor etwa 1 Jahr hinzugefügt
SL/Model/Record.pm | ||
---|---|---|
61 | 61 |
# fehler: exception |
62 | 62 |
} |
63 | 63 |
|
64 |
sub _save_history { |
|
65 |
my ($record, $addition, %history) = @_; |
|
66 |
|
|
67 |
my $number_type = $record->type =~ m{order} ? 'ordnumber' : 'quonumber'; |
|
68 |
my $snumbers = $number_type . '_' . $record->$number_type; |
|
69 |
|
|
70 |
SL::DB::History->new( |
|
71 |
trans_id => $record->id, |
|
72 |
employee_id => SL::DB::Manager::Employee->current->id, |
|
73 |
what_done => $record->type, |
|
74 |
snumbers => $snumbers, |
|
75 |
addition => $addition, |
|
76 |
)->save; |
|
77 |
} |
|
64 | 78 |
sub save { |
65 | 79 |
my ($class, $record, %params) = @_; |
66 | 80 |
|
Auch abrufbar als: Unified diff
Model::Record history als private Funktion