X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=bin%2Fmozilla%2Fir.pl;h=284b2fe5d4fe2f105105d107371fa457d99877b5;hb=2fda509c7dc417aad28ed072e91e8ffe2396314d;hp=466d44bd5d2a6bec30bfa96329c74f4af38c11c5;hpb=eaa48aeab931d62b1a14bba95537480758695655;p=kivitendo-erp.git
diff --git a/bin/mozilla/ir.pl b/bin/mozilla/ir.pl
index 466d44bd5..284b2fe5d 100644
--- a/bin/mozilla/ir.pl
+++ b/bin/mozilla/ir.pl
@@ -32,10 +32,13 @@
#======================================================================
use SL::IR;
+use SL::IS;
use SL::PE;
-require "$form->{path}/io.pl";
-require "$form->{path}/arap.pl";
+require "bin/mozilla/io.pl";
+require "bin/mozilla/arap.pl";
+require "bin/mozilla/common.pl";
+require "bin/mozilla/drafts.pl";
1;
@@ -44,6 +47,8 @@ require "$form->{path}/arap.pl";
sub add {
$lxdebug->enter_sub();
+ return $lxdebug->leave_sub() if (load_draft_maybe());
+
$form->{title} = $locale->text('Add Vendor Invoice');
&invoice_links;
@@ -55,7 +60,11 @@ sub add {
sub edit {
$lxdebug->enter_sub();
-
+
+ # show history button
+ $form->{javascript} = qq||;
+ #/show hhistory button
+
$form->{title} = $locale->text('Edit Vendor Invoice');
&invoice_links;
@@ -111,11 +120,6 @@ sub invoice_links {
$form->{taxzone_id} = $taxzone_id;
}
- # currencies
- @curr = split(/:/, $form->{currencies});
- chomp $curr[0];
- $form->{defaultcurrency} = $curr[0];
-
map { $form->{selectcurrency} .= "";
- } else {
- $form->{selecttaxzone} .=
- "";
- }
+ if (!$form->{"id"}) {
+ $taxzone = qq|
+
+ | . $locale->text('Steuersatz') . qq| |
+ | .
+ NTI($cgi->popup_menu('-name' => 'taxzone_id', '-default' => $form->{"taxzone_id"},
+ '-values' => \@values, '-labels' => \%labels)) . qq|
+ |
+
|;
- }
} else {
- $form->{selecttaxzone} =~ s/ selected//g;
- if ($form->{taxzone_id} ne "") {
- $form->{selecttaxzone} =~ s/value=$form->{taxzone_id}/value=$form->{taxzone_id} selected/;
- }
+ $taxzone = qq|
+
+ | . $locale->text('Steuersatz') . qq| |
+
+
+ | . H($labels{$form->{"taxzone_id"}}) . qq|
+ |
+
|;
}
- $taxzone = qq|
-
- | . $locale->text('Steuersatz') . qq| |
- |
-
-
|;
-
-
-
- $vendor =
- ($form->{selectvendor})
- ? qq|\n|
- : qq||;
-
- $contact =
- ($form->{selectcontact})
- ? qq|\n|
- : qq||;
-
$department = qq|
| . $locale->text('Department') . qq| |
-
-
+ |
+
|
| if $form->{selectdepartment};
@@ -331,12 +396,12 @@ sub form_header {
# with JavaScript Calendar
$button1 = qq|
- {invdate}> |
+ |
text('button') . qq|> |
|;
$button2 = qq|
- {duedate}> |
+ |
text('button') . qq|> |
|;
@@ -349,17 +414,25 @@ sub form_header {
# without JavaScript Calendar
$button1 =
- qq|{invdate}> | |;
+ qq| | |;
$button2 =
- qq|{duedate}> | |;
+ qq| | |;
}
$form->{"javascript"} .= qq||;
+ $form->{"javascript"} .= qq||;
- $form->header;
+ $jsscript .=
+ $form->write_trigger(\%myconfig, 2,
+ "orddate", "BL", "trigger_orddate",
+ "quodate", "BL", "trigger_quodate");
+ $form->header;
+ $onload = qq|focus()|;
+ $onload .= qq|;setupDateFormat('|. $myconfig{dateformat} .qq|', '|. $locale->text("Falsches Datumsformat!") .qq|')|;
+ $onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|;
print qq|
-
+