Typos beim entfernen von setupPoints/setupDateFormat
[kivitendo-erp.git] / bin / mozilla / ap.pl
index f961ead..2bf8017 100644 (file)
@@ -409,10 +409,8 @@ sub form_header {
                          '-default' => $form->{"globalproject_id"} ));
 
   $form->header;
-  my $onload = qq|;setupDateFormat('|. $myconfig{dateformat} .qq|', '|. $locale->text("Falsches Datumsformat!") .qq|')|;
-  $onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|;
   print qq|
-<body onLoad="$onload">
+<body>
 
 <form method=post action=$form->{script}>
 
@@ -1164,8 +1162,6 @@ sub delete {
   delete $form->{header};
 
   print qq|
-<body>
-
 <form method=post action=$form->{script}>
 |;
 
@@ -1185,9 +1181,6 @@ sub delete {
 <input name=action class=submit type=submit value="|
     . $locale->text('Yes') . qq|">
 </form>
-
-</body>
-</html>
 |;
 
   $main::lxdebug->leave_sub();
@@ -1445,6 +1438,9 @@ sub storno {
     $form->error($locale->text("Transaction has already been cancelled!"));
   }
 
+  $form->error($locale->text('Cannot post storno for a closed period!'))
+    if ( $form->date_closed($form->{transdate}, \%myconfig));
+
   AP->storno($form, \%myconfig, $form->{id});
 
   # saving the history