Revision d6beac43
Von Moritz Bunkus vor etwa 9 Jahren hinzugefügt
bin/mozilla/ar.pl | ||
---|---|---|
140 | 140 |
$main::lxdebug->leave_sub(); |
141 | 141 |
} |
142 | 142 |
|
143 |
sub _retrieve_invoice_object { |
|
144 |
return undef if !$::form->{id}; |
|
145 |
return $::form->{invoice_obj} if $::form->{invoice_obj} && $::form->{invoice_obj}->id == $::form->{id}; |
|
146 |
return SL::DB::Invoice->new(id => $::form->{id})->load; |
|
147 |
} |
|
148 |
|
|
143 | 149 |
sub create_links { |
144 | 150 |
$main::lxdebug->enter_sub(); |
145 | 151 |
|
... | ... | |
150 | 156 |
my %myconfig = %main::myconfig; |
151 | 157 |
|
152 | 158 |
$form->create_links("AR", \%myconfig, "customer"); |
153 |
$form->{invoice_obj} = $form->{id} ? SL::DB::Invoice->new(id => $form->{id})->load : undef;
|
|
159 |
$form->{invoice_obj} = _retrieve_invoice_object();
|
|
154 | 160 |
|
155 | 161 |
my %saved; |
156 | 162 |
if (!$params{dont_save}) { |
... | ... | |
218 | 224 |
my $locale = $main::locale; |
219 | 225 |
my $cgi = $::request->{cgi}; |
220 | 226 |
|
227 |
$form->{invoice_obj} = _retrieve_invoice_object(); |
|
228 |
|
|
221 | 229 |
my ($title, $readonly, $exchangerate, $rows); |
222 | 230 |
my ($notes, $department, $customer, $employee, $amount, $project); |
223 | 231 |
my ($ARselected); |
Auch abrufbar als: Unified diff
Debitorenbuchungen: In Kopf anzeigen, in welchen SEPA-Exporten der Beleg enthalten ist