X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/262e507798455abefd32b096875e03b1efe64336..c8c6d6d:/bin/mozilla/ar.pl diff --git a/bin/mozilla/ar.pl b/bin/mozilla/ar.pl index f03a74b7d..b5bd9be6c 100644 --- a/bin/mozilla/ar.pl +++ b/bin/mozilla/ar.pl @@ -1089,6 +1089,12 @@ sub post { $form->isblank("duedate", $locale->text('Due Date missing!')); $form->isblank("customer", $locale->text('Customer missing!')); + if ($myconfig{mandatory_departments} && !$form->{department}) { + $form->{saved_message} = $::locale->text('You have to specify a department.'); + update(); + exit; + } + my $closedto = $form->datetonum($form->{closedto}, \%myconfig); my $transdate = $form->datetonum($form->{transdate}, \%myconfig); $form->error($locale->text('Cannot post transaction for a closed period!')) if ($form->date_closed($form->{"transdate"}, \%myconfig));