projects
/
kivitendo-erp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Kunden/Lieferanten-Suche: Erfassen-Button überarbeitet
[kivitendo-erp.git]
/
bin
/
mozilla
/
am.pl
diff --git
a/bin/mozilla/am.pl
b/bin/mozilla/am.pl
index
8a48760
..
e12c1ea
100644
(file)
--- a/
bin/mozilla/am.pl
+++ b/
bin/mozilla/am.pl
@@
-43,6
+43,8
@@
use SL::USTVA;
use SL::Iconv;
use SL::TODO;
use SL::DB::Printer;
use SL::Iconv;
use SL::TODO;
use SL::DB::Printer;
+use SL::DB::Tax;
+use SL::DB::Language;
use CGI;
require "bin/mozilla/common.pl";
use CGI;
require "bin/mozilla/common.pl";
@@
-1415,6
+1417,7
@@
sub add_tax {
my $parameters_ref = {
# ChartTypeIsAccount => $ChartTypeIsAccount,
my $parameters_ref = {
# ChartTypeIsAccount => $ChartTypeIsAccount,
+ LANGUAGES => SL::DB::Manager::Language->get_all_sorted,
};
# Ausgabe des Templates
};
# Ausgabe des Templates
@@
-1450,6
+1453,8
@@
sub edit_tax {
$form->header();
my $parameters_ref = {
$form->header();
my $parameters_ref = {
+ LANGUAGES => SL::DB::Manager::Language->get_all_sorted,
+ TAX => SL::DB::Manager::Tax->find_by(id => $form->{id}),
};
# Ausgabe des Templates
};
# Ausgabe des Templates
@@
-1528,6
+1533,9
@@
sub save_tax {
$form->error($locale->text('Tax Percent is a number between 0 and 100'));
}
$form->error($locale->text('Tax Percent is a number between 0 and 100'));
}
+ my @translation_keys = grep { $_ =~ '^translation_\d+' } keys %$form;
+ $form->{translations} = { map { $_ =~ '^translation_(\d+)'; $1 => $form->{$_} } @translation_keys };
+
AM->save_tax(\%myconfig, \%$form);
$form->redirect($locale->text('Tax saved!'));
AM->save_tax(\%myconfig, \%$form);
$form->redirect($locale->text('Tax saved!'));