X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fap.pl;h=22fc65cfa284951bcd1f1e50d9ecc2bae312a959;hb=637be9d46084bc19a08b91bc13ae541a6c36f9ef;hp=c6eda1b9f5bf6f9dae3577445bb0438a964cc894;hpb=d0b49f673e3e8d59324570461d3a191f25b3d24c;p=kivitendo-erp.git diff --git a/bin/mozilla/ap.pl b/bin/mozilla/ap.pl index c6eda1b9f..22fc65cfa 100644 --- a/bin/mozilla/ap.pl +++ b/bin/mozilla/ap.pl @@ -130,6 +130,9 @@ sub create_links { # build the popup menus $form->{taxincluded} = ($form->{id}) ? $form->{taxincluded} : "checked"; + # notes + $form->{notes} = $form->{intnotes} unless $form->{notes}; + # currencies @curr = split(/:/, $form->{currencies}); chomp $curr[0]; @@ -386,7 +389,9 @@ sub form_header { $vendor = ($form->{selectvendor}) - ? qq|| + ? qq|| : qq||; my @old_project_ids = (); @@ -456,12 +461,12 @@ sub form_header { # with JavaScript Calendar $button1 = qq| - {transdate}> $readonly + {transdate} onBlur=\"check_right_date_format(this)\"> $readonly text('button') . qq|> |; $button2 = qq| - {duedate}> $readonly + {duedate} onBlur=\"check_right_date_format(this)\"> $readonly text('button') . qq|> |; @@ -474,15 +479,16 @@ sub form_header { # without JavaScript Calendar $button1 = - qq|{transdate}> $readonly|; + qq|{transdate} onBlur=\"check_right_date_format(this)\"> $readonly|; $button2 = - qq|{duedate}> $readonly|; + qq|{duedate} onBlur=\"check_right_date_format(this)\"> $readonly|; } - + $form->{javascript} .= qq||; $form->header; - + $onload = qq|;setupDateFormat('|. $myconfig{dateformat} .qq|', '|. $locale->text("Falsches Datumsformat!") .qq|')|; + $onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|; print qq| - +
{script}> @@ -770,12 +776,12 @@ $jsscript |; $column_data{"paid_$i"} = - qq|{"paid_$i"}>|; + qq|{"paid_$i"} onBlur=\"check_right_number_format(this)\">|; $column_data{"AP_paid_$i"} = qq|${selectAP_paid}|; $column_data{"exchangerate_$i"} = qq|$exchangerate|; $column_data{"datepaid_$i"} = - qq|{"datepaid_$i"}> + qq|{"datepaid_$i"} onBlur=\"check_right_date_format(this)\"> |; $column_data{"source_$i"} = qq||; @@ -843,7 +849,7 @@ sub form_footer { $transdate = $form->datetonum($form->{transdate}, \%myconfig); $closedto = $form->datetonum($form->{closedto}, \%myconfig); - print qq||; if ($form->{id}) { @@ -1069,6 +1075,7 @@ sub post { if (AP->post_transaction(\%myconfig, \%$form)) { # saving the history if(!exists $form->{addition} && $form->{id} ne "") { + $form->{snumbers} = qq|invnumber_| . $form->{invnumber}; $form->{addition} = "POSTED"; $form->save_history($form->dbconnect(\%myconfig)); } @@ -1087,6 +1094,7 @@ sub post_as_new { $form->{postasnew} = 1; # saving the history if(!exists $form->{addition} && $form->{id} ne "") { + $form->{snumbers} = qq|invnumber_| . $form->{invnumber}; $form->{addition} = "POSTED AS NEW"; $form->save_history($form->dbconnect(\%myconfig)); } @@ -1151,6 +1159,7 @@ sub yes { if (AP->delete_transaction(\%myconfig, \%$form, $spool)) { # saving the history if(!exists $form->{addition}) { + $form->{snumbers} = qq|invnumber_| . $form->{invnumber}; $form->{addition} = "DELETED"; $form->save_history($form->dbconnect(\%myconfig)); } @@ -1202,12 +1211,12 @@ sub search { # with JavaScript Calendar $button1 = qq| - + text('button') . qq|> |; $button2 = qq| - + text('button') . qq|> |; @@ -1220,9 +1229,9 @@ sub search { # without JavaScript Calendar $button1 = qq| - |; + |; $button2 = qq| - |; + |; } $form->get_lists("projects" => { "key" => "ALL_PROJECTS", @@ -1237,11 +1246,12 @@ sub search { my $projectnumber = NTI($cgi->popup_menu('-name' => 'project_id', '-values' => \@values, '-labels' => \%labels)); - + $form->{javascript} .= qq||; $form->header; - + $onload = qq|;setupDateFormat('|. $myconfig{dateformat} .qq|', '|. $locale->text("Falsches Datumsformat!") .qq|')|; + $onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|; print qq| - + {script}>