X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fam.pl;h=111e14e949cef19524f552c26c0d316ebf21429f;hb=07ccbf8dde5208f1615447aece57a76dc049d8d0;hp=19bb23ab298235be50fd11d32f55927fd081865c;hpb=508801bbaf7b9c5e144bf7ab9763a342ab80f176;p=kivitendo-erp.git
diff --git a/bin/mozilla/am.pl b/bin/mozilla/am.pl
index 19bb23ab2..111e14e94 100644
--- a/bin/mozilla/am.pl
+++ b/bin/mozilla/am.pl
@@ -46,8 +46,6 @@ use SL::Printer;
use CGI::Ajax;
use CGI;
-use Data::Dumper;
-
require "bin/mozilla/common.pl";
use strict;
@@ -349,11 +347,13 @@ sub account_header {
}
my $ChartTypeIsAccount = ($form->{charttype} eq "A") ? "1":"";
+ my $AccountIsPosted = ($form->{orphaned} ) ? "":"1";
$form->header();
my $parameters_ref = {
ChartTypeIsAccount => $ChartTypeIsAccount,
+ AccountIsPosted => $AccountIsPosted,
select_category => $select_category,
select_charttype => $select_charttype,
select_bwa => $select_bwa,
@@ -1392,17 +1392,18 @@ sub buchungsgruppe_header {
}
my $linkaccounts;
- if (!$::lx_office_conf{system}->{eur}) {
+ if ( $::instance_conf->get_inventory_system eq 'perpetual' ) { # was !$::lx_office_conf{system}->{eur}) {
$linkaccounts = qq|
| . $locale->text('Inventory') . qq| |
|
|;
- } else {
+ } elsif ( $::instance_conf->get_inventory_system eq 'periodic' ) {
+ # don't allow choice of inventory accno and don't show that line
$linkaccounts = qq|
{inventory_accno_id}>|;
- }
+ };
$linkaccounts .= qq|
@@ -1550,6 +1551,11 @@ sub edit_defaults {
map { $form->{"defaults_${_}"} = $form->{defaults}->{$_} } keys %{ $form->{defaults} };
+ # default language
+ my $all_languages = SL::DB::Manager::Language->get_all;
+
+# EÃR = cash, Bilanzierung = accrual
+
foreach my $key (keys %{ $form->{IC} }) {
foreach my $accno (sort keys %{ $form->{IC}->{$key} }) {
my $array = "ACCNOS_" . uc($key);
@@ -1567,7 +1573,8 @@ sub edit_defaults {
$form->{title} = $locale->text('Ranges of numbers and default accounts');
$form->header();
- print $form->parse_html_template('am/edit_defaults');
+ print $form->parse_html_template('am/edit_defaults',
+ { ALL_LANGUAGES => $all_languages, });
$main::lxdebug->leave_sub();
}
@@ -1655,14 +1662,7 @@ sub config {
{ 'name' => $locale->text('Queue'), 'value' => 'queue', 'selected' => $selected{queue}, },
];
- $form->{PRINTERS} = [];
- foreach my $printer (SL::Printer->all_printers(%::myconfig)) {
- push @{ $form->{PRINTERS} }, {
- 'name' => $printer->{printer_description},
- 'value' => $printer->{id},
- 'selected' => $printer->{id} == $myconfig{default_printer_id},
- };
- }
+ $form->{PRINTERS} = [ SL::Printer->all_printers(%::myconfig) ];
my %countrycodes = User->country_codes;