X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=inline;f=bin%2Fmozilla%2Fam.pl;h=368a627161bddaa0d5491dfa512db952e2dd7b74;hb=4aa816112a8b9f2d2959c92cfaa2f2954bdeceb2;hp=5dfb72f00050e05016fb242d485de8afb1e6bb5f;hpb=dbbf892309056494e9243df8b7599096ef9e42c5;p=kivitendo-erp.git
diff --git a/bin/mozilla/am.pl b/bin/mozilla/am.pl
index 5dfb72f00..368a62716 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;
@@ -504,7 +502,7 @@ sub list_account {
push(@ { $form->{AJAX} }, $pjx);
- $form->{stylesheets} = "list_accounts.css";
+ $form->use_stylesheet("list_accounts.css");
$form->{title} = $locale->text('Chart of Accounts');
$form->header;
@@ -620,242 +618,6 @@ sub delete_account {
$main::lxdebug->leave_sub();
}
-sub add_department {
- $main::lxdebug->enter_sub();
-
- my $form = $main::form;
-
- $main::auth->assert('config');
-
- $form->{title} = "Add";
- $form->{role} = "P";
-
- $form->{callback} = "am.pl?action=add_department" unless $form->{callback};
-
- &department_header;
- &form_footer;
-
- $main::lxdebug->leave_sub();
-}
-
-sub edit_department {
- $main::lxdebug->enter_sub();
-
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- $main::auth->assert('config');
-
- $form->{title} = "Edit";
-
- AM->get_department(\%myconfig, \%$form);
-
- &department_header;
- &form_footer;
-
- $main::lxdebug->leave_sub();
-}
-
-sub list_department {
- $main::lxdebug->enter_sub();
-
- my $form = $main::form;
- my %myconfig = %main::myconfig;
- my $locale = $main::locale;
-
- $main::auth->assert('config');
-
- AM->departments(\%myconfig, \%$form);
-
- $form->{callback} = "am.pl?action=list_department";
-
- my $callback = $form->escape($form->{callback});
-
- $form->{title} = $locale->text('Departments');
-
- my @column_index = qw(description cost profit);
- my %column_header;
- $column_header{description} =
- qq|
|
- . $locale->text('Description')
- . qq| | |;
- $column_header{cost} =
- qq||
- . $locale->text('Cost Center')
- . qq| | |;
- $column_header{profit} =
- qq||
- . $locale->text('Profit Center')
- . qq| | |;
-
- $form->header;
-
- print qq|
-
-
-
-
- $form->{title} |
-
-
-
-
-
-
-|;
-
- map { print "$column_header{$_}\n" } @column_index;
-
- print qq|
-
-|;
-
- my ($i, %column_data);
- foreach my $ref (@{ $form->{ALL} }) {
-
- $i++;
- $i %= 2;
-
- print qq|
-
-|;
-
- my $costcenter = ($ref->{role} eq "C") ? "X" : "";
- my $profitcenter = ($ref->{role} eq "P") ? "X" : "";
-
- $column_data{description} =
- qq|$ref->{description} | |;
- $column_data{cost} = qq|$costcenter | |;
- $column_data{profit} = qq|$profitcenter | |;
-
- map { print "$column_data{$_}\n" } @column_index;
-
- print qq|
-
-|;
- }
-
- print qq|
-
- |
-
-
-
|
-
-
-
-
-
-
-
-