Revision 7e4a1765
Von Bernd Bleßmann vor fast 2 Jahren hinzugefügt
bin/mozilla/gl.pl | ||
---|---|---|
1456 | 1456 |
my $form = $main::form; |
1457 | 1457 |
my $locale = $main::locale; |
1458 | 1458 |
|
1459 |
my $validity_token; |
|
1460 |
if (!$form->{id}) { |
|
1461 |
$validity_token = SL::DB::Manager::ValidityToken->fetch_valid_token( |
|
1462 |
scope => SL::DB::ValidityToken::SCOPE_GL_TRANSACTION_POST(), |
|
1463 |
token => $form->{form_validity_token}, |
|
1464 |
); |
|
1465 |
|
|
1466 |
$form->error($::locale->text('The form is not valid anymore.')) if !$validity_token; |
|
1467 |
} |
|
1468 |
|
|
1469 | 1459 |
if ($::myconfig{mandatory_departments} && !$form->{department_id}) { |
1470 | 1460 |
$form->error($locale->text('You have to specify a department.')); |
1471 | 1461 |
} |
... | ... | |
1475 | 1465 |
|
1476 | 1466 |
post_transaction(); |
1477 | 1467 |
|
1478 |
# If we get here, the transaction is posted. |
|
1479 |
$validity_token->delete if $validity_token; |
|
1480 |
delete $form->{form_validity_token}; |
|
1481 |
|
|
1482 | 1468 |
if ($::instance_conf->get_webdav) { |
1483 | 1469 |
SL::Webdav->new(type => 'general_ledger', |
1484 | 1470 |
number => $form->{id}, |
Auch abrufbar als: Unified diff
Gültigkeitstoken in Transaction abfragen und löschen: "alte" Controller
Lieferscheine
Einkaufsrechnung
Verkaufsrechnung
Kreditorenbuchung
Debitorenbuchung
Dialogbuchung