}
sub add_stylesheet {
- $::form->use_stylesheet('lx-office-erp/background_jobs.css');
+ $::request->{layout}->use_stylesheet('lx-office-erp/background_jobs.css');
}
1;
} else {
$::form->{title} = $locals{title} if $locals{title};
- $::form->header;
+ $::form->header(no_menu => $options->{no_menu});
}
}
sub action_header {
my ($self) = @_;
- delete $::form->{stylesheet};
$::form->use_stylesheet('frame_header/header.css');
- $self->render('menu/header',
+ $self->render('menu/header', { partial => 1, no_output => 1 },
now => DateTime->now_local,
is_fastcgi => scalar($::dispatcher->interface_type =~ /fastcgi/i),
is_links => scalar($ENV{HTTP_USER_AGENT} =~ /links/i));
--- /dev/null
+package SL::Controller::Layout;
+
+use strict;
+use parent qw(SL::Controller::Base);
+
+use JSON ();
+
+sub action_empty {
+ my ($self) = @_;
+
+ if ($::form->{format} eq 'json') {
+ my $layout = {
+ pre_content => $::request->{layout}->pre_content,
+ start_content => $::request->{layout}->start_content,
+ end_content => $::request->{layout}->end_content,
+ post_content => $::request->{layout}->post_content,
+ javascripts => [ $::request->{layout}->javascripts ],
+ javascripts_inline => [ $::request->{layout}->javascripts_inline ],
+ stylesheets => [ $::request->{layout}->stylesheets ],
+ stylesheets_inline => [ $::request->{layout}->stylesheets_inline ],
+ };
+
+ $self->render(\ JSON::to_json($layout), { type => 'js', raw => 1 });
+ }
+}
+
+1;
use SL::Dispatcher::AuthHandler::User;
use SL::User;
+__PACKAGE__->run_before('set_layout');
#
# actions
#
return if $self->_redirect_to_main_script_if_already_logged_in;
# Otherwise show the login form.
- $self->render('login_screen/user_login');
+ $self->render('login_screen/user_login', { no_menu => 1 }, error => error_state($::form->{error}));
}
sub action_logout {
$::auth->destroy_session;
$::auth->create_or_refresh_session;
- $self->render('login_screen/user_login', error => $::locale->text('You are logged out!'));
+ $self->render('login_screen/user_login', { no_menu => 1 }, error => $::locale->text('You are logged out!'));
}
sub action_login {
$::form->{login} = $::myconfig{login};
$::locale = Locale->new($::myconfig{countrycode}) if $::myconfig{countrycode};
my $user = User->new(login => $::myconfig{login});
+ $::request->{layout} = SL::Layout::Dispatcher->new(style => $user->{menustyle});
# if we get an error back, bale out
my $result = $user->login($::form);
# Other login errors.
if (0 > $result) {
$::auth->punish_wrong_login;
- return $self->render('login_screen/user_login', error => $::locale->text('Incorrect username or password!'));
+ return $self->render('login_screen/user_login', { no_menu => 1 }, error => $::locale->text('Incorrect username or password!'));
}
# Everything is fine.
return $self->redirect_to($::form->{callback}) if $::form->{callback};
- my %style_to_script_map = (
- v3 => 'v3',
- neu => 'new',
- v4 => 'v4',
- );
-
- my $menu_script = $style_to_script_map{$user->{menustyle}} || '';
-
- $self->redirect_to(controller => "menu${menu_script}.pl", action => 'display');
+ $self->redirect_to(controller => "login.pl", action => 'company_logo');
}
sub _redirect_to_main_script_if_already_logged_in {
return 1;
}
+sub error_state {
+ return {
+ session => $::locale->text('The session is invalid or has expired.'),
+ password => $::locale->text('Incorrect password!'),
+ }->{$_[0]};
+}
+
+sub set_layout {
+ $::request->{layout} = SL::Layout::Dispatcher->new(style => 'login');
+}
+
1;
});
}
- return $self->{report}->generate_with_headers;
+ return $self->{report}->generate_with_headers(no_layout => 1);
}
sub link_to {
use SL::Helper::DateTime;
use SL::InstanceConfiguration;
use SL::Template::Plugin::HTMLFixes;
+use SL::Layout::None;
# Trailing new line is added so that Perl will not add the line
# number 'die' was called in.
$::form->{error} = $::locale->text('The session is invalid or has expired.') if ($error_type eq 'session');
$::form->{error} = $::locale->text('Incorrect password!') if ($error_type eq 'password');
- $::form->header;
+ $::form->header(no_menu => 1);
print $::form->parse_html_template($template, \%params);
$::lxdebug->leave_sub;
$::locale = Locale->new($::lx_office_conf{system}->{language});
$::form = Form->new;
$::instance_conf = SL::InstanceConfiguration->new;
- $::request = { cgi => CGI->new({}) };
+ $::request = {
+ cgi => CGI->new({}),
+ layout => SL::Layout::None->new,
+ };
my $session_result = $::auth->restore_session;
$::auth->create_or_refresh_session;
::run($session_result);
} else {
- show_error('login_screen/user_login', 'session') if SL::Auth::SESSION_EXPIRED == $session_result;
+ if (SL::Auth::SESSION_EXPIRED == $session_result) {
+ print $::request->{cgi}->redirect('controller.pl?action=LoginScreen/user_login&error=session');
+ }
my %auth_result = $self->{auth_handler}->handle(
routing_type => $routing_type,
}
};
+ $::form->footer;
+
# cleanup
$::auth->save_session;
$::auth->expire_sessions;
-package SL::Dispatcher::AuthHandler;
+ package SL::Dispatcher::AuthHandler;
use strict;
my ($self, %param) = @_;
my $auth_level = $self->get_auth_level(%param);
+
my $handler_name = "SL::Dispatcher::AuthHandler::" . ucfirst($auth_level);
$self->{handlers} ||= {};
$self->{handlers}->{$handler_name} ||= $handler_name->new;
package SL::Dispatcher::AuthHandler::Admin;
use strict;
-
use parent qw(Rose::Object);
+use SL::Layout::Dispatcher;
+
sub handle {
%::myconfig = ();
return if $::form->{'{AUTH}admin_password'} && ($::auth->authenticate_root($::form->{'{AUTH}admin_password'}) == $::auth->OK());
return if !$::form->{'{AUTH}admin_password'} && ($::auth->authenticate_root($::auth->get_session_value('admin_password')) == $::auth->OK());
+ $::request->{layout} = SL::Layout::Dispatcher->new(style => 'admin');
+
$::auth->punish_wrong_login;
$::auth->delete_session_value('admin_password');
SL::Dispatcher::show_error('admin/adminlogin', 'password');
package SL::Dispatcher::AuthHandler::User;
use strict;
-
use parent qw(Rose::Object);
+use SL::Layout::Dispatcher;
+
sub handle {
my ($self, %param) = @_;
$self->_error(%param) unless $::myconfig{login};
$::locale = Locale->new($::myconfig{countrycode});
+ $::request->{layout} = SL::Layout::Dispatcher->new(style => $::myconfig{menustyle});
my $ok = $::form->{'{AUTH}login'} && (SL::Auth::OK() == $::auth->authenticate($::myconfig{login}, $::form->{'{AUTH}password'}));
$ok ||= !$::form->{'{AUTH}login'} && (SL::Auth::OK() == $::auth->authenticate($::myconfig{login}, undef));
my $self = shift;
$::auth->punish_wrong_login;
- SL::Dispatcher::show_error('login_screen/user_login', 'password', @_);
+ print $::request->{cgi}->redirect('controller.pl?action=LoginScreen/user_login&error=password');
}
1;
return ($module, $submodule);
}
-my @dont_save = qw(login password stylesheet action);
+my @dont_save = qw(login password action);
sub save {
$main::lxdebug->enter_sub();
use SL::DO;
use SL::IC;
use SL::IS;
+use SL::Layout::Dispatcher;
use SL::Locale;
use SL::Mailer;
use SL::Menu;
return $output;
}
-sub use_stylesheet {
- my $self = shift;
-
- $self->{stylesheet} = [ $self->{stylesheet} ] unless ref $self->{stylesheet} eq 'ARRAY';
- $self->{stylesheet} = [ grep { -f }
- map { m:^css/: ? $_ : "css/$_" }
- grep { $_ }
- (@{ $self->{stylesheet} }, @_)
- ];
-
- return @{ $self->{stylesheet} };
-}
-
-sub get_stylesheet_for_user {
- my $css_path = 'css';
- if (my $user_style = $::myconfig{stylesheet}) {
- $user_style =~ s/\.css$//; # nuke trailing .css, this is a remnand of pre 2.7.0 stylesheet handling
- if (-d "$css_path/$user_style" &&
- -f "$css_path/$user_style/main.css") {
- $css_path = "$css_path/$user_style";
- } else {
- $css_path = "$css_path/lx-office-erp";
- }
- } else {
- $css_path = "$css_path/lx-office-erp";
- }
- $::myconfig{css_path} = $css_path; # needed for menunew, FIXME: don't do this here
-
- return $css_path;
-}
-
sub header {
$::lxdebug->enter_sub;
- # extra code is currently only used by menuv3 and menuv4 to set their css.
- # it is strongly deprecated, and will be changed in a future version.
my ($self, %params) = @_;
my $db_charset = $::lx_office_conf{system}->{dbcharset} || Common::DEFAULT_CHARSET;
my @header;
$::lxdebug->leave_sub and return if !$ENV{HTTP_USER_AGENT} || $self->{header}++;
- my $css_path = $self->get_stylesheet_for_user;
+ if ($params{no_layout}) {
+ $::request->{layout} = SL::Layout::Dispatcher->new(style => 'none');
+ }
+
+ my $layout = $::request->{layout};
+
+ # standard css for all
+ # this should gradually move to the layouts that need it
+ $layout->use_stylesheet("$_.css") for qw(
+ main menu tabcontent list_accounts jquery.autocomplete
+ jquery.multiselect2side frame_header/header
+ ui-lightness/jquery-ui-1.8.12.custom
+ js/jscalendar/calendar-win2k-1
+ );
+
+ $layout->use_javascript("$_.js") for qw(
+ jquery common jscalendar/calendar jscalendar/lang/calendar-de
+ jscalendar/calendar-setup part_selection jquery-ui jquery.cookie jqModal
+ switchmenuframe
+ );
$self->{favicon} ||= "favicon.ico";
- $self->{titlebar} = "$self->{title} - $self->{titlebar}" if $self->{title};
+ $self->{titlebar} = join ' - ', grep $_, $self->{title}, $self->{login}, $::myconfig{dbname}, $self->{version} if $self->{title};
# build includes
if ($self->{refresh_url} || $self->{refresh_time}) {
push @header, "<meta http-equiv='refresh' content='$refresh_time;$refresh_url'>";
}
- push @header, map { qq|<link rel="stylesheet" href="$_" type="text/css" title="Stylesheet">| } $self->use_stylesheet;
-
- push @header, "<style type='text/css'>\@page { size:landscape; }</style>" if $self->{landscape};
- push @header, "<link rel='shortcut icon' href='$self->{favicon}' type='image/x-icon'>" if -f $self->{favicon};
- push @header, map { qq|<script type="text/javascript" src="js/$_.js"></script>| }
- qw(jquery common jscalendar/calendar jscalendar/lang/calendar-de jscalendar/calendar-setup part_selection jquery-ui jqModal switchmenuframe);
+ push @header, map { qq|<link rel="stylesheet" href="$_" type="text/css" title="Stylesheet">| } $layout->stylesheets;
+ push @header, "<style type='text/css'>\@page { size:landscape; }</style> " if $self->{landscape};
+ push @header, "<link rel='shortcut icon' href='$self->{favicon}' type='image/x-icon'>" if -f $self->{favicon};
+ push @header, map { qq|<script type="text/javascript" src="$_"></script>| } $layout->javascripts;
push @header, $self->{javascript} if $self->{javascript};
- push @header, map { qq|<link rel="stylesheet" type="text/css" href="$css_path/$_.css">| }
- qw(main menu tabcontent list_accounts jquery.autocomplete jquery.multiselect2side frame_header/header ui-lightness/jquery-ui-1.8.12.custom);
- push @header, map { qq|<link rel="stylesheet" type="text/css" href="js/jscalendar/calendar-win2k-1.css">| }
push @header, map { $_->show_javascript } @{ $self->{AJAX} || [] };
- push @header, "<script type='text/javascript'>function fokus(){ document.$self->{fokus}.focus(); }</script>" if $self->{fokus};
- push @header, sprintf "<script type='text/javascript'>top.document.title='%s';</script>",
- join ' - ', grep $_, $self->{title}, $self->{login}, $::myconfig{dbname}, $self->{version} if $self->{title};
-
- # if there is a title, we put some JavaScript in to the page, wich writes a
- # meaningful title-tag for our frameset.
- my $title_hack = '';
- if ($self->{title}) {
- $title_hack = qq|
- <script type="text/javascript">
- <!--
- // Write a meaningful title-tag for our frameset.
- top.document.title="| . $self->{"title"} . qq| - | . $self->{"login"} . qq| - | . $::myconfig{dbname} . qq| - V| . $self->{"version"} . qq|";
- //-->
- </script>|;
- }
my %doctypes = (
strict => qq|<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">|,
transitional => qq|<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">|,
frameset => qq|<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">|,
+ html5 => qq|<!DOCTYPE html>|,
);
# output
***********************************************/
</script>
- $params{extra_code}
- $title_hack
</head>
+ <body>
EOT
+ print $::request->{layout}->pre_content;
+ print $::request->{layout}->start_content;
+
+ $layout->header_done;
$::lxdebug->leave_sub;
}
+sub footer {
+ return unless $::request->{layout}->need_footer;
+
+ print $::request->{layout}->end_content;
+ print $::request->{layout}->post_content;
+
+ if (my @inline_scripts = $::request->{layout}->javascripts_inline) {
+ print "<script type='text/javascript'>@inline_scripts</script>\n";
+ }
+
+ print <<EOL
+ </body>
+</html>
+EOL
+}
+
sub ajax_response_header {
$main::lxdebug->enter_sub();
$::myconfig{numberformat} = $saved_numberformat;
}
+sub layout {
+ my ($self) = @_;
+ $::lxdebug->enter_sub;
+
+ my %style_to_script_map = (
+ v3 => 'v3',
+ neu => 'new',
+ v4 => 'v4',
+ );
+
+ my $menu_script = $style_to_script_map{$::myconfig{menustyle}} || '';
+
+ package main;
+ require "bin/mozilla/menu$menu_script.pl";
+ package Form;
+ require SL::Controller::FrameHeader;
+
+
+ my $layout = SL::Controller::FrameHeader->new->action_header . ::render();
+
+ $::lxdebug->leave_sub;
+ return $layout;
+}
+
1;
__END__
{ name => "Digest::SHA", url => "http://search.cpan.org/~mshelor/", debian => 'libdigest-sha-perl' },
{ name => "IO::Socket::SSL", url => "http://search.cpan.org/~sullr/", debian => 'libio-socket-ssl-perl' },
{ name => "Net::LDAP", url => "http://search.cpan.org/~gbarr/", debian => 'libnet-ldap-perl' },
- # Net::LDAP is core since 5.7.3
+ # Net::SMTP is core since 5.7.3
{ name => "Net::SMTP::SSL", version => '1.01', url => "http://search.cpan.org/~cwest/", debian => 'libnet-smtp-ssl-perl' },
{ name => "Net::SMTP::TLS", version => '0.12', url => "http://search.cpan.org/~awestholm/", debian => 'libnet-smtp-tls-perl' },
);
{ name => "Moose::Role", url => "http://search.cpan.org/~doy/", debian => 'libmoose-role-perl' },
{ name => "Perl::Tags", url => "http://search.cpan.org/~osfameron/", debian => 'libperl-tags-perl' },
{ name => "Test::Deep", url => "http://search.cpan.org/~rjbs/", debian => 'libtest-deep-perl' },
+ { name => "GD", version => '2.00', url => "http://search.cpan.org/~lds/", debian => 'libgd-perl' },
);
$_->{fullname} = join ' ', grep $_, @$_{qw(name version)}
--- /dev/null
+package SL::Layout::Admin;
+
+use strict;
+use parent qw(SL::Layout::Base);
+
+sub init_sub_layouts {
+ [ SL::Layout::None->new ]
+}
+
+sub start_content {
+ "<div id='admin' class='admin'>\n";
+}
+
+sub end_content {
+ "</div>\n";
+}
+
+1;
--- /dev/null
+package SL::Layout::Base;
+
+use strict;
+use parent qw(SL::Controller::Base);
+
+use List::MoreUtils qw(uniq);
+
+use Rose::Object::MakeMethods::Generic (
+ 'scalar --get_set_init' => qw(menu),
+ 'scalar' => qw(focus),
+ 'array' => [
+ 'add_stylesheets_inline' => { interface => 'add', hash_key => 'stylesheets_inline' },
+ 'add_javascripts_inline' => { interface => 'add', hash_key => 'javascripts_inline' },
+ 'sub_layouts', => { interface => 'get_set_init' },
+ 'add_sub_layouts' => { interface => 'add', hash_key => 'sub_layouts' },
+ ],
+);
+
+use SL::Menu;
+
+my %menu_cache;
+
+sub new {
+ my ($class, @slurp) = @_;
+
+ my $self = $class->SUPER::new(@slurp);
+}
+
+sub init_menu {
+ Menu->new('menu.ini');
+}
+
+##########################################
+# inheritable/overridable
+##########################################
+
+sub pre_content {
+ join '', map { $_->pre_content } $_[0]->sub_layouts;
+}
+
+sub start_content {
+ join '', map { $_->start_content } $_[0]->sub_layouts;
+}
+
+sub end_content {
+ join '', map { $_->end_content } $_[0]->sub_layouts;
+}
+
+sub post_content {
+ join '', map { $_->post_content } $_[0]->sub_layouts;
+}
+
+sub stylesheets_inline {
+ uniq ( map { $_->stylesheets_inline } $_[0]->sub_layouts ),
+ @{ $_[0]->{stylesheets_inline} || [] };
+}
+
+sub javascripts_inline {
+ uniq ( map { $_->javascripts_inline } $_[0]->sub_layouts ),
+ @{ $_[0]->{javascripts_inline} || [] };
+}
+
+sub init_sub_layouts { [] }
+
+
+#########################################
+# Interface
+########################################
+
+sub add_stylesheets {
+ &use_stylesheet;
+}
+
+sub use_stylesheet {
+ my $self = shift;
+ push @{ $self->{stylesheets} ||= [] }, @_ if @_;
+ @{ $self->{stylesheets} ||= [] };
+}
+
+sub stylesheets {
+ my ($self) = @_;
+ my $css_path = $self->get_stylesheet_for_user;
+
+ return uniq grep { $_ } map { $self->_find_stylesheet($_, $css_path) }
+ $self->use_stylesheet, map { $_->stylesheets } $self->sub_layouts;
+}
+
+sub _find_stylesheet {
+ my ($self, $stylesheet, $css_path) = @_;
+
+ return "$css_path/$stylesheet" if -f "$css_path/$stylesheet";
+ return "css/$stylesheet" if -f "css/$stylesheet";
+ return $stylesheet if -f $stylesheet;
+}
+
+sub get_stylesheet_for_user {
+ my $css_path = 'css';
+ if (my $user_style = $::myconfig{stylesheet}) {
+ $user_style =~ s/\.css$//; # nuke trailing .css, this is a remnand of pre 2.7.0 stylesheet handling
+ if (-d "$css_path/$user_style" &&
+ -f "$css_path/$user_style/main.css") {
+ $css_path = "$css_path/$user_style";
+ } else {
+ $css_path = "$css_path/lx-office-erp";
+ }
+ } else {
+ $css_path = "$css_path/lx-office-erp";
+ }
+ $::myconfig{css_path} = $css_path; # needed for menunew, FIXME: don't do this here
+
+ return $css_path;
+}
+
+sub add_javascripts {
+ &use_javascript
+}
+
+sub use_javascript {
+ my $self = shift;
+ push @{ $self->{javascripts} ||= [] }, @_ if @_;
+ @{ $self->{javascripts} ||= [] };
+}
+
+sub javascripts {
+ my ($self) = @_;
+
+ return uniq map { $self->_find_javascript($_) }
+ $self->use_javascript, map { $_->javascripts } $self->sub_layouts;
+}
+
+sub _find_javascript {
+ my ($self, $javascript) = @_;
+
+ return "js/$javascript" if -f "js/$javascript";
+ return $javascript if -f $javascript;
+}
+
+
+############################################
+# track state of form header
+############################################
+
+sub header_done {
+ $_[0]{_header_done} = 1;
+}
+
+sub need_footer {
+ $_[0]{_header_done};
+}
+
+1;
--- /dev/null
+package SL::Layout::Classic;
+
+use strict;
+use parent qw(SL::Layout::Base);
+
+use SL::Layout::Top;
+use SL::Layout::MenuLeft;
+use SL::Layout::None;
+
+sub init_sub_layouts {
+ [
+ SL::Layout::Top->new,
+ SL::Layout::MenuLeft->new,
+ SL::Layout::None->new,
+ ]
+}
+
+1;
--- /dev/null
+package SL::Layout::Css;
+
+use strict;
+
+use List::Util qw(max);
+use Exporter qw(import);
+
+our @EXPORT = qw(clock_line print_menu menuitem_v3);
+
+sub clock_line {
+ my ($Sekunden, $Minuten, $Stunden, $Monatstag, $Monat,
+ $Jahr, $Wochentag, $Jahrestag, $Sommerzeit)
+ = localtime(time);
+ $Monat += 1;
+ $Jahrestag += 1;
+ $Monat = $Monat < 10 ? $Monat = "0" . $Monat : $Monat;
+ $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
+ $Jahr += 1900;
+ my @Wochentage = ("Sonntag", "Montag", "Dienstag", "Mittwoch",
+ "Donnerstag", "Freitag", "Samstag");
+ my @Monatsnamen = ("", "Januar", "Februar", "März",
+ "April", "Mai", "Juni", "Juli",
+ "August", "September", "Oktober", "November",
+ "Dezember");
+ return
+ $Wochentage[$Wochentag] . ", der "
+ . $Monatstag . "."
+ . $Monat . "."
+ . $Jahr . " - ";
+}
+
+sub print_menu {
+ my ($self, $parent, $depth) = @_;
+
+ my $html;
+
+ die if ($depth * 1 > 5);
+
+ my @menuorder;
+ my $menu = $self->menu;
+
+ @menuorder = $menu->access_control(\%::myconfig, $parent);
+
+ $parent .= "--" if ($parent);
+
+ foreach my $item (@menuorder) {
+ substr($item, 0, length($parent)) = "";
+ next if (($item eq "") || ($item =~ /--/));
+
+ my $menu_item = $menu->{"${parent}${item}"};
+ my $menu_title = $::locale->text($item);
+ my $menu_text = $menu_title;
+
+ if ($menu_item->{"submenu"} || !defined($menu_item->{"module"}) ||
+ ($menu_item->{"module"} eq "menu.pl")) {
+
+ my $h = $self->print_menu("${parent}${item}", $depth * 1 + 1)."\n";
+ if (!$parent) {
+ $html .= qq|<ul><li><h2>${menu_text}</h2><ul>${h}</ul></li></ul>\n|;
+ } else {
+ $html .= qq|<li><div class="x">${menu_text}</div><ul>${h}</ul></li>\n|;
+ }
+ } else {
+ if ($self->{sub_class} && $depth > 1) {
+ $html .= qq|<li class='sub'>|;
+ } else {
+ $html .= qq|<li>|;
+ }
+ $html .= $self->menuitem_v3("${parent}$item", { "title" => $menu_title });
+ $html .= qq|${menu_text}</a></li>\n|;
+ }
+ }
+
+ return $html;
+}
+
+sub menuitem_v3 {
+ $main::lxdebug->enter_sub();
+
+ my ($self, $item, $other) = @_;
+ my $menuitem = $self->menu->{$item};
+
+ my $action = "section_menu";
+ my $module;
+
+ if ($menuitem->{module}) {
+ $module = $menuitem->{module};
+ }
+ if ($menuitem->{action}) {
+ $action = $menuitem->{action};
+ }
+
+ my $level = $::form->escape($item);
+
+ my $str = qq|<a href="$module?action=| . $::form->escape($action) . qq|&level=| . $::form->escape($level);
+
+ my @vars = qw(module action target href);
+
+ if ($menuitem->{href}) {
+ $str = qq|<a href=$menuitem->{href}|;
+ @vars = qw(module target href);
+ }
+
+ map { delete $menuitem->{$_} } @vars;
+
+ # add other params
+ foreach my $key (keys %{ $menuitem }) {
+ $str .= "&" . $::form->escape($key, 1) . "=";
+ my ($value, $conf) = split(/=/, $menuitem->{$key}, 2);
+ $value = $::myconfig{$value} . "/$conf" if ($conf);
+ $str .= $::form->escape($value, 1);
+ }
+
+ $str .= '"';
+
+ if ($other) {
+ foreach my $key (keys(%{$other})) {
+ $str .= qq| ${key}="| . $::form->quote($other->{$key}) . qq|"|;
+ }
+ }
+
+ $str .= ">";
+
+ $main::lxdebug->leave_sub();
+
+ return $str;
+}
+
+1;
--- /dev/null
+package SL::Layout::Dispatcher;
+
+use strict;
+
+use SL::Layout::Admin;
+use SL::Layout::Login;
+use SL::Layout::Classic;
+use SL::Layout::V3;
+use SL::Layout::V4;
+use SL::Layout::Javascript;
+
+sub new {
+ my ($class, %params) = @_;
+
+ return SL::Layout::Classic->new if $params{style} eq 'old';
+ return SL::Layout::V3->new if $params{style} eq 'v3';
+ return SL::Layout::V4->new if $params{style} eq 'v4';
+ return SL::Layout::Javascript->new if $params{style} eq 'neu';
+ return SL::Layout::Admin->new if $params{style} eq 'admin';
+ return SL::Layout::Login->new if $params{style} eq 'login';
+ return SL::Layout::None->new;
+}
+
+1;
--- /dev/null
+package SL::Layout::Javascript;
+
+use strict;
+use parent qw(SL::Layout::Base);
+
+use List::Util qw(max);
+use URI;
+
+sub init_sub_layouts {
+ [ SL::Layout::None->new ]
+}
+
+sub pre_content {
+ &display
+}
+
+sub start_content {
+ "<div id='content'>\n";
+}
+
+sub end_content {
+ "</div>\n";
+}
+
+sub stylesheets {
+ $_[0]->add_stylesheets(qw(
+ dhtmlsuite/menu-item.css
+ dhtmlsuite/menu-bar.css
+ ));
+ $_[0]->SUPER::stylesheets;
+}
+
+sub display {
+ my ($self) = @_;
+ my $form = $main::form;
+
+ my $callback = $form->unescape($form->{callback});
+ $callback = URI->new($callback)->rel($callback) if $callback;
+ $callback = "login.pl?action=company_logo" if $callback =~ /^(\.\/)?$/;
+
+ $self->render("menu/menunew", { partial => 1, no_output => 1 },
+ force_ul_width => 1,
+ date => $self->clock_line,
+ menu_items => $self->acc_menu,
+ callback => $callback,
+ );
+}
+
+sub clock_line {
+ my $form = $main::form;
+
+ my ($Sekunden, $Minuten, $Stunden, $Monatstag, $Monat,
+ $Jahr, $Wochentag, $Jahrestag, $Sommerzeit)
+ = localtime(time);
+ $Monat += 1;
+ $Jahrestag += 1;
+ $Monat = $Monat < 10 ? $Monat = "0" . $Monat : $Monat;
+ $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
+ $Jahr += 1900;
+ my @Wochentage = ("Sonntag", "Montag", "Dienstag", "Mittwoch",
+ "Donnerstag", "Freitag", "Samstag");
+ my @Monatsnamen = ("", "Januar", "Februar", "März",
+ "April", "Mai", "Juni", "Juli",
+ "August", "September", "Oktober", "November",
+ "Dezember");
+ return
+ $Wochentage[$Wochentag] . ", der "
+ . $Monatstag . "."
+ . $Monat . "."
+ . $Jahr . " - ";
+}
+
+sub acc_menu {
+ my ($self) = @_;
+
+ my $menu = $self->menu;
+
+ my $all_items = [];
+ $self->create_menu($menu, $all_items);
+
+ my $item = { 'subitems' => $all_items };
+ calculate_width($item);
+
+ return $all_items;
+}
+
+sub calculate_width {
+ my $item = shift;
+
+ $item->{max_width} = max map { length $_->{title} } @{ $item->{subitems} };
+
+ foreach my $subitem (@{ $item->{subitems} }) {
+ calculate_width($subitem) if ($subitem->{subitems});
+ }
+}
+
+sub create_menu {
+ my ($self, $menu, $all_items, $parent, $depth) = @_;
+ my $html;
+
+ my $form = $main::form;
+ my %myconfig = %main::myconfig;
+
+ die if ($depth * 1 > 5);
+
+ my @menuorder = $menu->access_control(\%myconfig, $parent);
+ $parent .= "--" if ($parent);
+
+ foreach my $name (@menuorder) {
+ substr($name, 0, length($parent), "");
+ next if (($name eq "") || ($name =~ /--/));
+
+ my $menu_item = $menu->{"${parent}${name}"};
+ my $item = { 'title' => $::locale->text($name) };
+ push @{ $all_items }, $item;
+
+ if ($menu_item->{submenu} || !defined($menu_item->{module}) || ($menu_item->{module} eq "menu.pl")) {
+ $item->{subitems} = [];
+ $item->{image} = _icon_path("$name.png");
+ $self->create_menu($menu, $item->{subitems}, "${parent}${name}", $depth * 1 + 1);
+
+ } else {
+ $item->{image} = _icon_path("${parent}${name}.png");
+ $menu->menuitem_new("${parent}${name}", $item);
+ }
+ }
+}
+
+sub _icon_path {
+ my ($label, $size) = @_;
+
+ $size ||= 16;
+
+ my $img = "image/icons/${size}x${size}/$label";
+
+ return unless -f $img;
+ return $img;
+}
+
+1;
--- /dev/null
+package SL::Layout::Login;
+
+use strict;
+use parent qw(SL::Layout::Base);
+
+sub new {
+ my ($class, @slurp) = @_;
+
+ my $self = $class->SUPER::new(@slurp);
+
+ $self->add_sub_layouts([
+ SL::Layout::None->new,
+ ]);
+
+ $self;
+}
+
+sub start_content {
+ "<div id='login' class='login'>\n";
+}
+
+sub end_content {
+ "</div>\n";
+}
+
+1;
--- /dev/null
+package SL::Layout::MenuLeft;
+
+use strict;
+use parent qw(SL::Layout::Base);
+
+use URI;
+
+use List::MoreUtils qw(apply);
+
+sub stylesheets {
+ qw(icons16.css icons24.css menu.css)
+}
+
+sub javascripts_inline {
+ my $self = shift;
+ my $sections = [ section_menu($self->menu) ];
+ $self->render('menu/menu', { partial => 1, no_output => 1 },
+ sections => $sections,
+ )
+}
+
+sub javascripts {
+ 'js/jquery.cookie.js';
+}
+
+sub pre_content {
+ "<div id='html-menu'></div>\n";
+}
+
+sub start_content {
+ "<div id='content' class='html-menu'>\n";
+}
+
+sub end_content {
+ "</div>\n";
+}
+
+sub section_menu {
+ $::lxdebug->enter_sub(2);
+ my ($menu, $level, $id_prefix) = @_;
+ my @menuorder = $menu->access_control(\%::myconfig, $level);
+ my @items;
+
+ my $id = 0;
+
+ for my $item (@menuorder) {
+ my $menuitem = $menu->{$item};
+ my $olabel = apply { s/.*--// } $item;
+ my $ml = apply { s/--.*// } $item;
+ my $icon_class = apply { y/ /-/ } $item;
+ my $spacer = "s" . (0 + $item =~ s/--/--/g);
+
+ next if $level && $item ne "$level--$olabel";
+
+ my $label = $::locale->text($olabel);
+
+ $menuitem->{module} ||= $::form->{script};
+ $menuitem->{action} ||= "section_menu";
+ $menuitem->{href} ||= "$menuitem->{module}?action=$menuitem->{action}";
+
+ # add other params
+ foreach my $key (keys %$menuitem) {
+ next if $key =~ /target|module|action|href/;
+ $menuitem->{href} .= "&" . $::form->escape($key, 1) . "=";
+ my ($value, $conf) = split(/=/, $menuitem->{$key}, 2);
+ $value = $::myconfig{$value} . "/$conf" if ($conf);
+ $menuitem->{href} .= $::form->escape($value, 1);
+ }
+
+ my $anchor = $menuitem->{href};
+
+ my @common_args = ($label, $spacer, "$id_prefix\_$id");
+
+ if (!$level) { # toplevel
+ push @items, [ @common_args, "icon24 $icon_class", 'm' ];
+ # make_image(size => 24, label => $item),
+ push @items, section_menu($menu, $item, "$id_prefix\_$id");
+ } elsif ($menuitem->{submenu}) {
+ push @items, [ @common_args, "icon16 submenu", 'sm' ];
+ #make_image(label => 'submenu'),
+ push @items, section_menu($menu, $item, "$id_prefix\_$id");
+ } elsif ($menuitem->{module}) {
+ push @items, [ @common_args, "icon16 $icon_class", 'i', $anchor ];
+ #make_image(size => 16, label => $item),
+ }
+ } continue {
+ $id++;
+ }
+
+ $::lxdebug->leave_sub(2);
+ return @items;
+}
+
+sub _calc_framesize {
+ my $is_lynx_browser = $ENV{HTTP_USER_AGENT} =~ /links/i;
+ my $is_mobile_browser = $ENV{HTTP_USER_AGENT} =~ /mobile/i;
+ my $is_mobile_style = $::form->{stylesheet} =~ /mobile/i;
+
+ return $is_mobile_browser && $is_mobile_style ? 130
+ : $is_lynx_browser ? 240
+ : 200;
+}
+
+sub _show_images {
+ # don't show images in links
+ _calc_framesize() != 240;
+}
+
+1;
+
+__END__
+
+=encoding utf-8
+
+=head1 NAME
+
+SL::Layout::MenuLeft - ex html meanu, now only left menu
+
+=head1 DOM MODEL
+
+Data will be embedded into the page as a json array of entries.
+Each entry is another array with the following fields:
+
+ 0: title
+ 1: indentation classes
+ 2: unique id
+ 3: icon classes
+ 4: role classes
+
+From each entry the following dom will be generated, with [0] being entry 0 of
+the data array:
+
+ <div id="mi[2]" class="mi [4] [1]">
+ <a class="ml">
+ <span class="mii ms">
+ <div class="[3]"></div>
+ </span>
+ <span class="mic">[0]</span>
+ </a>
+ </div>
+
+The classes are minified to keep the json somewhat in check, their meaning is as follows:
+
+=over 4
+
+=item Indentation Classes
+
+ s0: No indentation
+ s1: One level of indentation
+ s2: Two levels of indentation
+
+=item Icon Classes
+
+Each icon consists of two classes, one for the icon, and one for the size.
+The icon classes are taken from the file names, for example C<Master-Data> is
+the icon for master data, and refers to Master-Icon.png.
+
+ icon16: 16x16 icon
+ icon24: 24x24 icon
+ icon32: 32x32 icon
+
+=item Role Classes
+
+Role classes may be used to style types of links differently. Currently used:
+
+ ml: menu link, any <a> tag will have this
+ mi: menu item, the enclosing div for each entry has this
+ mii: menu item icon, the enclosing div for the icons has this
+ ms: menu spacer, the first <span> in the link will have this
+ m: menu, only top level entries have this
+ i: item, only leaf entries have this
+ sm: sub menu, eveything that is not top nor leaf has this
+ mic: menu item content, the span with the human readable description has this
+
+=back
+
+=head1 BUGS
+
+none yet
+
+=head1 AUTHOR
+
+Sven Schoeling E<lt>s.schoeling@linet-services.deE<gt>
+
+=cut
--- /dev/null
+package SL::Layout::None;
+
+use strict;
+use parent qw(SL::Layout::Base);
+
+sub javascripts_inline {
+ _setup_formats(),
+ _setup_focus(),
+}
+
+sub use_javascript {
+ 'js/common.js'
+}
+
+sub use_stylesheet {
+ 'main.css'
+}
+
+sub _setup_formats {
+ $::form->parse_html_template('layout/javascript_setup')
+}
+
+sub _setup_focus {
+ if ($::request->{layout}->focus || $::form->{fokus}) {
+ return $::form->parse_html_template('layout/focus_setup', {
+ focus => $::request->{layout}->focus,
+ fokus => $::form->{fokus},
+ })
+ } else {
+ return ();
+ }
+}
+
+1;
--- /dev/null
+package SL::Layout::Top;
+
+use strict;
+use parent qw(SL::Layout::Base);
+
+sub pre_content {
+ my ($self) = @_;
+
+ $self->SUPER::render('menu/header', { partial => 1, no_output => 1 },
+ now => DateTime->now_local,
+ is_fastcgi => scalar($::dispatcher->interface_type =~ /fastcgi/i),
+ is_links => scalar($ENV{HTTP_USER_AGENT} =~ /links/i));
+}
+
+sub stylesheets {
+ 'frame_header/header.css';
+}
+
+1;
+
+__END__
+
+=encoding utf-8
+
+=head1 NAME
+
+SL::Layout::Top - Top line in classic and v4 menu.
+
+=head1 DOM MODEL
+
+The entire top line is rendered into a div with id C<frame-header>. The following classes are used:
+
+ frame-header-element: any continuous block of entries
+ frame-header-left: the left floating part
+ frame-header-right: the right floating part
+ frame-header-center: the centered part
+
+=head1 BUGS
+
+none yet. :)
+
+=head1 AUTHOR
+
+Sven Schoeling E<lt>s.schoeling@linet-services.deE<gt>
+
+=cut
--- /dev/null
+package SL::Layout::V3;
+
+use strict;
+use parent qw(SL::Layout::Base);
+use SL::Layout::Css;
+
+use URI;
+
+sub init_sub_layouts {
+ [ SL::Layout::None->new ]
+}
+
+sub pre_content {
+ &render;
+}
+
+sub start_content {
+ "<div id='content'>\n";
+}
+
+sub end_content {
+ "</div>\n";
+}
+
+sub render {
+ my ($self) = @_;
+
+ my $callback = $::form->unescape($::form->{callback});
+ $callback = URI->new($callback)->rel($callback) if $callback;
+ $callback = "login.pl?action=company_logo" if $callback =~ /^(\.\/)?$/;
+
+ $self->SUPER::render('menu/menuv3', { no_menu => 1, no_output => 1 },
+ force_ul_width => 1,
+ date => $self->clock_line,
+ menu => $self->print_menu,
+ callback => $callback,
+ );
+}
+
+1;
--- /dev/null
+package SL::Layout::V4;
+
+use strict;
+use parent qw(SL::Layout::Base);
+use SL::Layout::Css;
+use SL::Layout::Top;
+
+use URI;
+
+sub init_sub_layouts {
+ [
+ SL::Layout::Top->new,
+ SL::Layout::None->new,
+ ]
+}
+
+sub start_content {
+ "<div id='content'>\n";
+}
+
+sub end_content {
+ "</div>\n";
+}
+
+sub pre_content {
+ my ($self) = @_;
+
+ $self->{sub_class} = 1;
+
+ my $callback = $::form->unescape($::form->{callback});
+ $callback = URI->new($callback)->rel($callback) if $callback;
+ $callback = "login.pl?action=company_logo" if $callback =~ /^(\.\/)?$/;
+
+ $self->SUPER::pre_content .
+
+ $self->SUPER::render('menu/menuv4', { no_menu => 1, no_output => 1 },
+ force_ul_width => 1,
+ date => $self->clock_line,
+ menu => $self->print_menu,
+ callback => $callback,
+ );
+}
+
+1;
return $self;
}
-sub menuitem {
- $main::lxdebug->enter_sub();
-
- my ($self, $myconfig, $form, $item) = @_;
-
- my $module = $self->{$item}{module} || $form->{script};
- my $action = $self->{$item}{action} || "section_menu";
- my $target = $self->{$item}{target} || "";
-
- my $level = $form->escape($item);
-
- my $style = 'style="vertical-align:top"';
- my $target_token = ($target)
- ? "target='$target'" : '';
-
- my $href = ($self->{$item}{href})
- ? $form->escape($self->{$item}{href})
- : "$module?action=$action&level=$level";
-
- my @vars = ($self->{$item}{href})
- ? qw(module target href)
- : qw(module action target href);
-
-# map { delete $self->{$item}{$_} } @vars;
-
- # add other params
- foreach my $key (keys %{ $self->{$item} }) {
- $href .= "&" . $form->escape($key, 1) . "=";
- my ($value, $conf) = split(/=/, $self->{$item}{$key}, 2);
- $value = $myconfig->{$value} . "/$conf" if ($conf);
- $href .= $form->escape($value, 1);
- }
-
- my $str = "<a href='$href' $target_token $style>";
-
- $main::lxdebug->leave_sub();
-
- return $str;
-}
-
-sub menuitem_js {
- my ($self, $myconfig, $form, $item) = @_;
-
- my $module = $form->{script};
- my $action = "section_menu";
-
- #if ($self->{$item}{module}) {
- $module = $self->{$item}{module};
-
- #}
- if ($self->{$item}{action}) {
- $action = $self->{$item}{action};
- }
-
- my $level = $form->escape($item);
- my $str = qq|$module?action=$action&level=$level|;
- my @vars = qw(module action target href);
-
- if ($self->{$item}{href}) {
- $str = qq|$self->{$item}{href}|;
- @vars = qw(module target href);
- }
-
- map { delete $self->{$item}{$_} } @vars;
-
- # add other params
- foreach my $key (keys %{ $self->{$item} }) {
- $str .= "&" . $form->escape($key, 1) . "=";
- my ($value, $conf) = split(/=/, $self->{$item}{$key}, 2);
- $value = $myconfig->{$value} . "/$conf" if ($conf);
- $str .= $form->escape($value, 1);
- }
-
- $str .= " ";
-
-}
-
sub menuitem_new {
$main::lxdebug->enter_sub();
$main::lxdebug->leave_sub();
}
-sub menuitem_v3 {
- $main::lxdebug->enter_sub();
-
- my ($self, $myconfig, $form, $item, $other) = @_;
-
- my $module = $form->{script};
- my $action = "section_menu";
- my $target = "";
-
- if ($self->{$item}{module}) {
- $module = $self->{$item}{module};
- }
- if ($self->{$item}{action}) {
- $action = $self->{$item}{action};
- }
- if ($self->{$item}{target}) {
- $target = $self->{$item}{target};
- }
-
- my $level = $form->escape($item);
-
- my $str = qq|<a href="$module?action=| . $form->escape($action) . qq|&level=| . $form->escape($level);
-
- my @vars = qw(module action target href);
-
- if ($self->{$item}{href}) {
- $str = qq|<a href=$self->{$item}{href}|;
- @vars = qw(module target href);
- }
-
- map { delete $self->{$item}{$_} } @vars;
-
- # add other params
- foreach my $key (keys %{ $self->{$item} }) {
- $str .= "&" . $form->escape($key, 1) . "=";
- my ($value, $conf) = split(/=/, $self->{$item}{$key}, 2);
- $value = $myconfig->{$value} . "/$conf" if ($conf);
- $str .= $form->escape($value, 1);
- }
-
- $str .= '"';
-
- if ($target) {
- $str .= qq| target="| . $form->quote($target) . qq|"|;
- }
-
- if ($other) {
- foreach my $key (keys(%{$other})) {
- $str .= qq| ${key}="| . $form->quote($other->{$key}) . qq|"|;
- }
- }
-
- $str .= ">";
-
- $main::lxdebug->leave_sub();
-
- return $str;
-}
-
-sub menuitem_XML {
- $main::lxdebug->enter_sub();
-
- my ($self, $myconfig, $form, $item, $other) = @_;
-
- my $module = $form->{script};
- my $action = "section_menu";
- my $target = "";
-
- if ($self->{$item}{module}) {
- $module = $self->{$item}{module};
- }
- if ($self->{$item}{action}) {
- $action = $self->{$item}{action};
- }
- if ($self->{$item}{target}) {
- $target = $self->{$item}{target};
- }
-
- my $level = $form->escape($item);
-
- my $str = qq| link="$module?action=| . $form->escape($action) .
- qq|&level=| . $form->escape($level);
-
- my @vars = qw(module action target href);
-
- if ($self->{$item}{href}) {
- $str = qq| link=$self->{$item}{href}|;
- @vars = qw(module target href);
- }
-
- map { delete $self->{$item}{$_} } @vars;
-
- # add other params
- foreach my $key (keys %{ $self->{$item} }) {
- $str .= "&" . $form->escape($key, 1) . "=";
- my ($value, $conf) = split(/=/, $self->{$item}{$key}, 2);
- $value = $myconfig->{$value} . "/$conf" if ($conf);
- $str .= $form->escape($value, 1);
- }
-
- $str .= '"';
-
-
-
- if ($other) {
- foreach my $key (keys(%{$other})) {
- $str .= qq| ${key}="| . $form->quote($other->{$key}) . qq|"|;
- }
- }
-
-
- $main::lxdebug->leave_sub();
-
- return $str;
-}
-
sub access_control {
$main::lxdebug->enter_sub(2);
foreach my $column (values %{ $self->{columns} }) {
$column->{visible} = $self->{options}->{std_column_visibility} unless defined $column->{visible};
}
-
+
if( $::form->{report_generator_csv_options_for_import} ) {
foreach my $key (keys %{ $self->{columns} }) {
$self->{columns}{$key}{text} = $key;
}
sub generate_with_headers {
- my $self = shift;
+ my ($self, %params) = @_;
my $format = lc $self->{options}->{output_format};
my $form = $self->{form};
if ($format eq 'html') {
my $title = $form->{title};
$form->{title} = $self->{title} if ($self->{title});
- $form->header();
+ $form->header(no_layout => $params{no_layout});
$form->{title} = $title;
print $self->generate_html_content();
my $self = shift;
my $variables = $self->prepare_html_content();
- return $self->{form}->parse_html_template($self->{options}->{html_template}, $variables);
+ my $stuff = $self->{form}->parse_html_template($self->{options}->{html_template}, $variables);
+ return $stuff;
}
sub _cm2bp {
$dbh->disconnect;
if ($update_available) {
- $form->{"stylesheet"} = "lx-office-erp.css";
$form->{"title"} = $main::locale->text("Dataset upgrade");
$form->header();
print $form->parse_html_template("dbupgrade/header");
$locale = $::locale;
$auth = $::auth;
- $form->{stylesheet} = "lx-office-erp.css";
+ $::request->{layout} = SL::Layout::Dispatcher->new(style => 'admin');
+ $::request->{layout}->use_stylesheet("lx-office-erp.css");
$form->{favicon} = "favicon.ico";
if ($form->{action}) {
my $form = $main::form;
my $locale = $main::locale;
- $form->{stylesheet} = "lx-office-erp.css";
+ $::request->{layout}->use_stylesheet("lx-office-erp.css");
$form->{title} = $locale->text("Dataset upgrade");
$form->header();
$ca->{link_edit_account} = $link_edit_account . '&id=' . E($ca->{id});
}
- $form->use_stylesheet("list_accounts.css");
+ $::request->{layout}->use_stylesheet("list_accounts.css");
$form->{title} = $locale->text('Chart of Accounts');
$form->header;
'-default' => $form->{"globalproject_id"} ));
$form->header;
- my $onload = qq|;setupDateFormat('|. $myconfig{dateformat} .qq|', '|. $locale->text("Falsches Datumsformat!") .qq|')|;
- $onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|;
print qq|
-<body onLoad="$onload">
-
<form method=post action=$form->{script}>
<input type=hidden name=id value=$form->{id}>
delete $form->{header};
print qq|
-<body>
-
<form method=post action=$form->{script}>
|;
<input name=action class=submit type=submit value="|
. $locale->text('Yes') . qq|">
</form>
-
-</body>
-</html>
|;
$main::lxdebug->leave_sub();
my ($title, $readonly, $exchangerate, $rows);
my ($notes, $department, $customer, $employee, $amount, $project);
- my ($onload);
my ($ARselected);
qq|<script type="text/javascript" src="js/show_vc_details.js"></script>| .
qq|<script type="text/javascript" src="js/follow_up.js"></script>|;
- $onload = qq|focus()|;
- $onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|;
-
# $amount = $locale->text('Amount');
# $project = $locale->text('Project');
project_labels => \%project_labels,
rows => $rows,
ARselected => $ARselected,
- onload => $onload,
title_str => $title,
follow_up_trans_info => $follow_up_trans_info,
});
print "
</form>
-
-</body>
-</html>
";
$main::lxdebug->leave_sub();
delete $form->{header};
print qq|
-<body>
-
<form method=post action=$form->{script}>
|;
<input name=action class=submit type=submit value="|
. $locale->text('Yes') . qq|">
</form>
-
-</body>
-</html>
|;
$main::lxdebug->leave_sub();
my $cgi = $::request->{cgi};
my ($customer, $department);
- my ($jsscript, $button1, $button2, $onload);
+ my ($jsscript, $button1, $button2);
# setup customer selection
$form->all_vc(\%myconfig, "customer", "AR");
my $title = $locale->text('Select from one of the names below');
print qq|
-<body>
-
<form method=post action=$form->{script}>
<table width=100%>
<input class=submit type=submit name=action value="|
. $locale->text('Continue') . qq|">
</form>
-
-</body>
-</html>
|;
$main::lxdebug->leave_sub();
$::form->{title} = $::locale->text('List Transactions') . " - " . $::locale->text('Account') . " $::form->{accno}";
- my $onload = qq|focus()|;
- $onload .= qq|;setupDateFormat('$::myconfig{dateformat}', '|. $::locale->text("Falsches Datumsformat!") .qq|')|;
- $onload .= qq|;setupPoints('$::myconfig{numberformat}', '|. $::locale->text("wrongformat") .qq|')|;
-
$::form->header;
print $::form->parse_html_template('ca/list', {
- onload => $onload,
year => DateTime->today->year,
cash => $::instance_conf->get_accounting_method eq 'cash',
});
map { $form->{$_} = $options{$_} if ($options{$_}) } qw(no_services no_assemblies assemblies click_button);
my $parts = Common->retrieve_parts(\%myconfig, $form, $order_by, $order_dir);
- my $onload;
if (0 == scalar(@{$parts})) {
$form->show_generic_information($locale->text("No part was found matching the search parameters."));
} elsif (1 == scalar(@{$parts})) {
- $onload = "part_selected('1')";
+ $::request->{layout}->add_javascripts_inline("part_selected('1')");
}
map { $parts->[$_]->{selected} = $_ ? 0 : 1; } (0..$#{$parts});
$form->{formname} ||= 'Form';
$form->{title} = $locale->text("Select a part");
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template("generic/part_selection", { "HEADER" => \@header,
- "PARTS" => $parts,
- "onload" => $onload });
+ "PARTS" => $parts, });
$main::lxdebug->leave_sub();
}
my $delivery = Common->retrieve_delivery_customer(\%myconfig, $form, $order_by, $order_dir);
map({ $delivery->[$_]->{"selected"} = $_ ? 0 : 1; } (0..$#{$delivery}));
- my $onload;
if (0 == scalar(@{$delivery})) {
$form->show_generic_information($locale->text("No Customer was found matching the search parameters."));
} elsif (1 == scalar(@{$delivery})) {
- $onload = "customer_selected('1')";
+ $::request->{layout}->add_javascripts_inline("customer_selected('1')");
}
my $callback = "$form->{script}?action=delivery_customer_selection&";
@header_sort);
$form->{"title"} = $locale->text("Select a Customer");
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template("generic/select_delivery_customer", { "HEADER" => \@header,
- "DELIVERY" => $delivery,
- "onload" => $onload });
+ "DELIVERY" => $delivery, });
$main::lxdebug->leave_sub();
}
my $vendor = Common->retrieve_vendor(\%myconfig, $form, $order_by, $order_dir);
map({ $vendor->[$_]->{"selected"} = $_ ? 0 : 1; } (0..$#{$vendor}));
- my $onload;
if (0 == scalar(@{$vendor})) {
$form->show_generic_information($locale->text("No Vendor was found matching the search parameters."));
} elsif (1 == scalar(@{$vendor})) {
- $onload = "vendor_selected('1')";
+ $::request->{layout}->add_javascripts_inline("vendor_selected('1')");
}
my $callback = "$form->{script}?action=vendor_selection&";
@header_sort);
$form->{"title"} = $locale->text("Select a Customer");
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template("generic/select_vendor", { "HEADER" => \@header,
- "VENDOR" => $vendor,
- "onload" => $onload });
+ "VENDOR" => $vendor, });
$main::lxdebug->leave_sub();
}
my ($variable_string, $formel) = split /###/,$form->{formel};
my @variable;
- my $onload; # note! this sub is mostly called over a javascript invocation, and it's unlikey that onload is set.
foreach my $item (split m/;/, $variable_string) {
next unless $item =~ m/^ \s* (\w+) \s* = \s* (\w+) \s* (\w+) \s* $/x;
$form->{formel} = $formel;
$form->{title} = $locale->text("Please enter values");
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template("generic/calculate_qty", { "HEADER" => \@header,
- "VARIABLES" => \@variable,
- "onload" => $onload });
+ "VARIABLES" => \@variable, });
$main::lxdebug->leave_sub();
}
my $locale = $main::locale;
$form->{title} = $locale->text("Enter longdescription");
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template("generic/set_longdescription");
$main::lxdebug->leave_sub();
$sort =~ s/.*\.(.*)/$1/;
$form->{title} = $locale->text("History");
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template( "common/show_history", {
"DATEN" => $form->get_history($dbh,$form->{input_name},"",$form->{order}),
"SUCCESS" => ($form->get_history($dbh,$form->{input_name}) ne "0"),
uc($sort) => 1,
- uc($sort)."BY" => $sortby
+ uc($sort)."BY" => $sortby,
} );
$dbh->disconnect();
$form->{title} = $form->{vc} eq "customer" ?
$locale->text("Customer details") : $locale->text("Vendor details");
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template("common/show_vc_details", { "is_customer" => $form->{vc} eq "customer" });
$main::lxdebug->leave_sub();
}
$referer = $script . "?action=mark_as_paid&mark_as_paid=1&id=$form->{id}" . $callback;
$form->header();
- print qq|<body>|;
print qq|<p><b>|.$locale->text('Mark as paid?').qq|</b></p>|;
print qq|<input type="button" value="|.$locale->text('yes').qq|" onclick="document.location.href='|.$referer.qq|'"> |;
print qq|<input type="button" value="|.$locale->text('no').qq|" onclick="javascript:history.back();">|;
- print qq|</body></html>|;
}
$main::lxdebug->leave_sub();
my $covs = Common->retrieve_customers_or_vendors(\%myconfig, $form, $order_by, $order_dir, $form->{"is_vendor"}, $form->{"allow_both"});
map({ $covs->[$_]->{"selected"} = $_ ? 0 : 1; } (0..$#{$covs}));
- my $onload;
if (0 == scalar(@{$covs})) {
$form->show_generic_information(sprintf($locale->text("No %s was found matching the search parameters."), $type));
} elsif (1 == scalar(@{$covs})) {
- $onload = "cov_selected('1')";
+ $::request->{layout}->add_javascripts_inline("cov_selected('1')");
}
my $callback = "$form->{script}?action=cov_selection_internal&";
$form->{"title"} = $form->{is_vendor} ? $locale->text("Select a vendor") : $locale->text("Select a customer");
$form->header();
print($form->parse_html_template("generic/cov_selection", { "HEADER" => \@header,
- "COVS" => $covs,
- "onload" => $onload }));
+ "COVS" => $covs, }));
$main::lxdebug->leave_sub();
}
# Standard Konto für Umlaufvermögen
my $accno_arap = IS->get_standard_accno_current_assets(\%myconfig, \%$form);
- # Entsprechend präventiv die Auswahlliste für Kontonummer
+ # Entsprechend präventiv die Auswahlliste für Kontonummer
# auch mit value= zusammenbauen (s.a. oben bugfix 1771)
# Wichtig: Auch das Template anpassen, damit hidden input korrekt die "
# escaped.
$form->{defaultcurrency} = $form->{currency} = $form->{oldcurrency} =
$curr[0];
- # Entsprechend präventiv die Auswahlliste für Währungen
+ # Entsprechend präventiv die Auswahlliste für Währungen
# auch mit value= zusammenbauen (s.a. oben bugfix 1771)
$form->{selectcurrency} = "";
map { $form->{selectcurrency} .= "<option value=\"$_\">$_</option>\n" } @curr;
$auth->assert('cash');
my ($vc, $arap, $exchangerate);
- my ($onload);
if ($form->{ $form->{vc} } eq "") {
map { $form->{"addr$_"} = "" } (1 .. 4);
$form->header;
$arap = lc $form->{ARAP};
- $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 $::form->parse_html_template('cp/form_header', {
is_customer => $form->{vc} eq 'customer',
is_receipt => $form->{type} eq 'receipt',
- onload => $onload,
arap => $arap,
vccontent => $vc,
});
$form->{customer_id} = $form->{AR}[0]{customer_id};
}
- # search by invoicenumber,
- if ($form->{invnumber}) {
+ # search by invoicenumber,
+ if ($form->{invnumber}) {
$form->{open} ='Y'; # only open invoices
if ($form->{ARAP} eq 'AR'){
# ar_transactions automatically searches by $form->{customer_id} or else
'no_opendocument' => 1,);
$form->header();
- $form->{onload} = "document.getElementsByName('language_id')[0].disabled =
- !document.getElementsByName('force_lang')[0].checked;";
print $form->parse_html_template("dunning/show_invoices");
$main::lxdebug->leave_sub();
$main::auth->assert('dunning_edit');
$form->{"title"} = $locale->text("Set eMail text");
- $form->header();
+ $form->header(no_layout => 1);
print($form->parse_html_template("dunning/set_email"));
$main::lxdebug->leave_sub();
$form->{jsscript} = 1;
$form->{title} = $locale->text('Dunnings');
- $form->{fokus} = "search.customer";
+ $::request->{layout}->focus('#customer');
$form->header();
- $form->{onload} = qq|focus()|
- . qq|;setupDateFormat('|. $myconfig{dateformat} .qq|', '|. $locale->text("Falsches Datumsformat!") .qq|')|
- . qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|;
-
print $form->parse_html_template("dunning/search");
$main::lxdebug->leave_sub();
$report->set_options_from_form();
- $form->{onload} = "document.getElementsByName('language_id')[0].disabled =
- !document.getElementsByName('force_lang')[0].checked;";
$report->generate_with_headers();
$main::lxdebug->leave_sub();
$form->{oldvcname} = $form->{"old$form->{vc}"};
$form->{oldvcname} =~ s/--.*//;
- $form->{onload} = "";
if ($form->{resubmit}) {
+ my $dispatch_to_popup = '';
if ($form->{format} eq "html") {
- $form->{onload} = "window.open('about:blank','Beleg'); document.do.target = 'Beleg';";
+ $dispatch_to_popup .= "window.open('about:blank','Beleg'); document.do.target = 'Beleg';";
}
# emulate click for resubmitting actions
- $form->{onload} .= "document.do.${_}.click(); " for grep { /^action_/ } keys %$form;
- $form->{onload} .= "document.do.submit();"
+ $dispatch_to_popup .= "document.do.${_}.click(); " for grep { /^action_/ } keys %$form;
+ $dispatch_to_popup .= "document.do.submit();";
+ $::request->{layout}->add_javascripts_inline("\$(function(){$dispatch_to_popup)");
}
my $follow_up_vc = $form->{ $form->{vc} eq 'customer' ? 'customer' : 'vendor' };
get_basic_bin_wh_info($stock_info);
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template('do/stock_in_form', { 'UNITS' => $units_data,
'STOCK_INFO' => $stock_info,
'PART_INFO' => $part_info, });
}
}
- $form->header();
+ $form->header(no_layout => 1);
print $form->parse_html_template('do/stock_out_form', { 'UNITS' => $units_data,
'WHCONTENTS' => $form->{delivered} ? $stock_info : \@contents,
'PART_INFO' => $part_info, });
restore_form($form->{SAVED_FORM}, 1) if ($form->{SAVED_FORM});
delete $form->{SAVED_FORM};
- $form->{SAVED_FORM} = save_form(qw(stylesheet login password));
+ $form->{SAVED_FORM} = save_form(qw(login password));
$form->{remove_draft} = 1;
$form->header();
$draft_nextsub = "add" unless ($draft_nextsub);
delete $form->{action};
- my $saved_form = save_form(qw(stylesheet login password));
+ my $saved_form = save_form(qw(login password));
$form->header();
print($form->parse_html_template("drafts/load",
$form->{draft_description} = $description;
$form->{remove_draft} = 'checked';
}
- # Ich vergesse bei Rechnungsentwürfe das Rechnungsdatum zu ändern. Dadurch entstehen
+ # Ich vergesse bei Rechnungsentwürfe das Rechnungsdatum zu ändern. Dadurch entstehen
# ungültige Belege. Vielleicht geht es anderen ähnlich jan 19.2.2011
$form->{invdate} = $form->current_date(\%myconfig); # Aktuelles Rechnungsdatum ...
$form->{duedate} = $form->current_date(\%myconfig); # Aktuelles Fälligkeitsdatum ...
$form->{jsscript} = 1;
- $form->header();
+ $form->header(no_layout => $::form->{POPUP_MODE});
print $form->parse_html_template('fu/add_edit');
$main::lxdebug->leave_sub();
);
$::form->{ALL_EMPLOYEES} = SL::DB::Manager::Employee->get_all(query => [ deleted => 0 ]);
- my $onload = "focus()"
- . qq|;setupDateFormat('|. $::myconfig{dateformat} . qq|', '| . $::locale->text("Falsches Datumsformat!") . qq|')|
- . qq|;setupPoints('|. $::myconfig{numberformat} . qq|', '| . $::locale->text("wrongformat") . qq|')|;
-
$::form->header;
print $::form->parse_html_template('gl/search', {
- onload => $onload,
department_label => sub { ("$_[0]{description}--$_[0]{id}")x2 },
employee_label => sub { "$_[0]{id}--$_[0]{name}" },
});
$data .= $sh;
$row->{balance}->{data} = $data;
-
+
if ( !$form->{report_generator_csv_options_for_import} ) {
$report->add_separator();
$report->add_data($row);
$form->header;
print qq|
-<body>
-
<form method=post action=gl.pl>
|;
# $form->header;
#
# print qq|
-#<body>
# <form method=post action=ic.pl>
# <table width=100%>
# <tr>
# . $locale->text('TOP100') . qq|">
#
#</form>
-#</body>
-#</html>
#|;
# $lxdebug->leave_sub();
#} #end list()
my $colspan = $#column_index + 1;
print qq|
-<body>
-
<table width=100%>
<tr>
<th class=listtop colspan=$colspan>$form->{title}</th>
. $locale->text('choice') . qq|">
</form>
-
-</body>
-</html>
|;
$lxdebug->leave_sub();
} @{ $::form->{item_list} };
# delete action variable
- delete @{$::form}{qw(action item_list header)};
+ delete @{$::form}{qw(action item_list)};
print $::form->parse_html_template('io/select_item', { PREVIOUS_FORM => $previous_form,
MODE => $mode,
$form->header;
print qq|
-<body>
-
<form method=post action=$form->{script}>
|;
$form->error($locale->text("Invoice has already been storno'd!"));
}
- map({ my $key = $_; delete($form->{$key}) unless (grep({ $key eq $_ } qw(id login password stylesheet type))); } keys(%{ $form }));
+ map({ my $key = $_; delete($form->{$key}) unless (grep({ $key eq $_ } qw(id login password type))); } keys(%{ $form }));
invoice_links();
prepare_invoice();
$form->header;
print qq|
-<body>
-
<form method="post" action="$form->{script}">
|;
+++ /dev/null
-#=====================================================================
-# LX-Office ERP
-# Copyright (C) 2004
-# Based on SQL-Ledger Version 2.1.9
-# Web http://www.lx-office.org
-#
-######################################################################
-# SQL-Ledger Accounting
-# Copyright (c) 1998-2002
-#
-# Author: Dieter Simader
-# Email: dsimader@sql-ledger.org
-# Web: http://www.sql-ledger.org
-#
-# Contributors: Christopher Browne
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#######################################################################
-#
-# the frame layout with refractured menu
-#
-# CHANGE LOG:
-# DS. 2002-03-25 Created
-# 2004-12-14 - New Optik - Marco Welter <mawe@linux-studio.de>
-# 2010-08-19 - Icons for sub entries and single click behavior, unlike XUL-Menu
-# JS switchable HTML-menu - Sven Donath <lxo@dexo.de>
-#######################################################################
-
-use strict;
-
-use SL::Menu;
-use Data::Dumper;
-use URI;
-
-use List::MoreUtils qw(apply);
-
-my $menufile = "menu.ini";
-my $nbsp = ' ';
-my $mainlevel;
-
-# end of main
-
-sub display {
- $::lxdebug->enter_sub;
-
- my $callback = $::form->unescape($::form->{callback});
- $callback = URI->new($callback)->rel($callback) if $callback;
- $callback = "login.pl?action=company_logo" if $callback =~ /^(\.\/)?$/;
- my $framesize = _calc_framesize();
-
- $::form->header(doctype => 'frameset');
-
- print qq|
-<frameset rows="28px,*" cols="*" framespacing="0" frameborder="0">
- <frame src="controller.pl?action=FrameHeader/header" scrolling="NO">
- <frameset cols="$framesize,*" framespacing="0" frameborder="0" border="0" id="menuframe" name="menuframe">
- <frame src="$::form->{script}?action=acc_menu" name="acc_menu" scrolling="auto" noresize marginwidth="0">
- <frame src="$callback" name="main_window" scrolling="auto">
- </frameset>
- <noframes>
- You need a browser that can read frames to see this page.
- </noframes>
-</frameset>
-</HTML>
-|;
-
- $::lxdebug->leave_sub;
-}
-
-sub acc_menu {
- $::lxdebug->enter_sub;
-
- my $framesize = _calc_framesize() - 2;
- my $menu = Menu->new("menu.ini");
- $mainlevel = $::form->{level};
- $::form->{title} = $::locale->text('kivitendo');
- $::form->header;
-
- print qq|
-<body class="menu">
-
-<div align="left">\n<table width="$framesize" border="0">\n|;
-
- section_menu($menu);
-
- print qq|</table></div>
-</body>
-</html>
-|;
-
- $::lxdebug->leave_sub;
-}
-
-sub section_menu {
- $::lxdebug->enter_sub;
- my ($menu, $level) = @_;
- my @menuorder = $menu->access_control(\%::myconfig, $level);
-
- for my $item (@menuorder) {
- my $menuitem = $menu->{$item};
- my $label = apply { s/.*--// } $item;
- my $ml = apply { s/--.*// } $item;
- my $show = $ml eq $mainlevel;
- my $spacer = $nbsp x (($item =~ s/--/--/g) * 2);
- my $label_icon = $level . "--" . $label . ".png";
-
- next if $level && $item ne "$level--$label";
-
- $label = $::locale->text($label);
-
- $menuitem->{target} ||= "main_window";
-
- my $anchor = $menu->menuitem(\%::myconfig, $::form, $item, $level);
-
- if (!$level) { # toplevel
- my $ml_ = $::form->escape($ml);
- my $image = make_image(icon => $item . '.png', size => 24, label => $label, valign => 'middle');
- my $anchor = "<a href='menu.pl?action=acc_menu&level=$ml_' class='nohover' title='$label'>";
-
- print make_item(a => $anchor, img => $image, label => $label, height => 24);
- section_menu($menu, $item);
-
- } elsif ($menuitem->{submenu}) {
- my $image = make_image(submenu => 1);
- if ($mainlevel && $item =~ /^\Q$mainlevel\E/) {
- print make_item(spacer => $spacer, bold => 1, img => $image, label => $label) if $show;
- section_menu($menu, $item);
- } else {
- print make_item(spacer => $spacer, a => $anchor, img => $image, label => $label . ' ...') if $show;
- }
- } elsif ($menuitem->{module}) {
- my $image = make_image(label => $label, icon => $label_icon);
- print make_item(img => $image, a => $anchor, spacer => $spacer, label => $label) if $show;
- section_menu($menu, $item) if $show && $::form->{$item} && $::form->{level} eq $item;
- }
- }
- $::lxdebug->leave_sub;
-}
-
-sub make_item {
- my %params = @_;
- my $anchor = $params{a} || '';
- my @chunks = multiline($params{label});
- my $spacer = $params{spacer} || '';
- my $image = $params{img};
- my $height = $params{height} || 16;
- my $a_end = $anchor ? '</a>' : '';
- my $bold = $params{bold} ? '<b>' : '';
- my $b_end = $bold ? '</b>' : '';
- my $hidden_image = make_image(hidden => 1);
- return join "\n",
- "<tr><td class='hover' height='$height'>$bold$spacer$anchor$image$chunks[0]$a_end$b_end</td></tr>\n",
- map "<tr style='vertical-align:top'><td class='hover'>$bold$spacer$hidden_image$anchor$chunks[$_]$a_end$b_end</td></tr>\n",
- 1..$#chunks;
-}
-
-# multi line hack, sschoeling jul06
-# if a label is too long, try to split it at whitespaces, then join it to chunks of less
-# than 20 chars and store it in an array.
-# use this array later instead of the -ed label
-sub multiline {
- my ($label) = @_;
- my @chunks;
- my $l = 20;
- for (split / /, $label) {
- $l += length $_;
- if ($l < 20) {
- $chunks[-1] .= " $_";
- } else {
- $l = length $_;
- push @chunks, $_;
- }
- }
- return @chunks;
-}
-
-sub make_image {
- my (%params) = @_;
-
- my $label = $params{label};
- my $icon = $params{icon};
- my $hidden = $params{hidden};
- my $size = $params{size} || 16;
- my $valign = $params{valign} || 'text-top';
-
- return unless _show_images();
-
- my $icon_found = $icon && -f _icon_path($icon, $size);
-
- my $image_url = $icon_found ? _icon_path($icon, $size) : "image/unterpunkt.png";
- my $style = $hidden ? "visibility:hidden" : "vertical-align:$valign";
- my $width = $hidden ? "width='$size'" : '';
-
- my $padding = $size == 16 && $icon_found || $hidden ? $nbsp x 2
- : $size == 24 ? $nbsp
- : '';
-
- return "<img src='$image_url' border='0' style='$style' title='$label' $width>$padding";
-}
-
-sub _calc_framesize {
- my $is_lynx_browser = $ENV{HTTP_USER_AGENT} =~ /links/i;
- my $is_mobile_browser = $ENV{HTTP_USER_AGENT} =~ /mobile/i;
- my $is_mobile_style = $::form->{stylesheet} =~ /mobile/i;
-
- return $is_mobile_browser && $is_mobile_style ? 130
- : $is_lynx_browser ? 240
- : 200;
-}
-
-sub _show_images {
- # don't show images in links
- _calc_framesize() != 240;
-}
-
-sub _icon_path {
- my ($label, $size) = @_;
-
- $size ||= 16;
-
- return "image/icons/${size}x${size}/$label";
-}
-
-1;
-
-__END__
+++ /dev/null
-#=====================================================================
-# LX-Office ERP
-# Copyright (C) 2004
-# Based on SQL-Ledger Version 2.1.9
-# Web http://www.lx-office.org
-#
-######################################################################
-# SQL-Ledger Accounting
-# Copyright (c) 1998-2002
-#
-# Author: Dieter Simader
-# Email: dsimader@sql-ledger.org
-# Web: http://www.sql-ledger.org
-#
-# Contributors: Christopher Browne
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#######################################################################
-#
-# thre frame layout with refractured menu
-#
-# CHANGE LOG:
-# DS. 2002-03-25 Created
-# 2004-12-14 - Holger Lindemann
-#######################################################################
-
-use utf8;
-use strict;
-
-use SL::Menu;
-use CGI::Carp qw(fatalsToBrowser);
-
-1;
-
-# end of main
-
-sub display {
-
- my $form = $main::form;
-
- $form->{callback} = $form->unescape($form->{callback});
- $form->{callback} ||= "login.pl?action=company_logo";
-
- $form->header;
-
- &clock_line;
-
- &acc_menu;
-
- print qq|
-<iframe id="win1" src="$form->{callback}" width="100%" height="93%" name="main_window" style="position: absolute; border:0px;">
-<p>Ihr Browser kann leider keine eingebetteten Frames anzeigen.
-</p>
-</iframe>
-</body>
-</html>
-
-|;
-
-}
-
-sub clock_line {
-
- my $form = $main::form;
-
- my $fensterlink="menujs.pl?action=display";
- my $fenster = "["."<a href=\"$fensterlink\" target=\"_blank\">neues Fenster</a>]";
-
- my $login = "[Nutzer "
- . $form->{login}
- . " - <a href=\"controller.pl?action=LoginScreen/logout\" target=\"_top\">"
- . $::locale->text('Logout')
- . "</a>] ";
- my ($Sekunden, $Minuten, $Stunden, $Monatstag, $Monat,
- $Jahr, $Wochentag, $Jahrestag, $Sommerzeit)
- = localtime(time);
- my $CTIME_String = localtime(time);
- $Monat += 1;
- $Jahrestag += 1;
- $Monat = $Monat < 10 ? $Monat = "0" . $Monat : $Monat;
- $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
- $Jahr += 1900;
- my @Wochentage = ("Sonntag", "Montag", "Dienstag", "Mittwoch",
- "Donnerstag", "Freitag", "Samstag");
- my @Monatsnamen = ("", "Januar", "Februar", "März",
- "April", "Mai", "Juni", "Juli",
- "August", "September", "Oktober", "November",
- "Dezember");
- my $datum =
- $Wochentage[$Wochentag] . ", der "
- . $Monatstag . "."
- . $Monat . "."
- . $Jahr . " - ";
-
- #$zeit="<div id='Uhr'>".$Stunden.":".$Minuten.":".$Sekunden."</div>";
- my $zeit = "<div id='Uhr'>" . $Stunden . ":" . $Minuten . "</div>";
- print qq|
-<script type="text/javascript">
-<!--
-function clockon() {
- var now = new Date();
- var h = now.getHours();
- var m = now.getMinutes();
- document.getElementById('clock_id').innerHTML = (h<10?'0'+h:h)+":"+(m<10?'0'+m:m);
- var timer=setTimeout("clockon()", 10000);
-}
-window.onload=clockon
-//-->
-</script>
-<table border="0" width="100%" background="image/bg_titel.gif" cellpadding="0" cellspacing="0">
- <tr>
- <td style="color:white; font-family:verdana,arial,sans-serif; font-size: 12px;"> $fenster [<a href="JavaScript:top.main_window.print()">drucken</a>]</td>
- <td align="right" style="vertical-align:middle; color:white; font-family:verdana,arial,sans-serif; font-size: 12px;" nowrap>
- $login $datum <span id='clock_id' style='position:relative'></span>
- </td>
- </tr>
-</table>
-|;
-}
-
-sub acc_menu {
-
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- my $mainlevel = $form->{level};
- $mainlevel =~ s/$mainlevel--//g;
- my $menu = Menu->new("menu.ini");
-
- $| = 1;
-
- print qq|
-<style>
-<!--
-
-.itemBorder {
- border: 1px solid black
-}
-
-.itemText {
- text-decoration: none;
- color: #000000;
- font: 12px Arial, Helvetica
-}
-
-.rootItemText {
- text-decoration: none;
- color: #ffffff;
- font: 12px Arial, Helvetica
-}
-
-.menu {
- color:#ffffff;
- background:url(image/bg_css_menu.png) repeat bottom;
- border:1px solid;
- border-color:#ccc #888 #555 #bbb;
-}
-
--->
-</style>
-
-<script type="text/javascript">
-<!--
-var isDOM = (document.getElementById ? true : false);
-var isIE4 = ((document.all && !isDOM) ? true : false);
-var isNS4 = (document.layers ? true : false);
-//var KO = (navigator.appName=="Konqueror" \|\| navigator.appName=="Opera") ;
-var KO = ((navigator.userAgent.indexOf('Opera',0) != -1) \|\| (navigator.userAgent.indexOf('Konqueror',0) != -1));
-function getRef(id) {
- if (isDOM) return document.getElementById(id);
- if (isIE4) return document.all[id];
- if (isNS4) return document.layers[id];
-}
-function getSty(id) {
- return (isNS4 ? getRef(id) : getRef(id).style);
-}
-var popTimer = 0;
-var litNow = new Array();
-function popOver(menuNum, itemNum) {
- if (KO) document.getElementById("win1").style.visibility = "hidden";
- clearTimeout(popTimer);
- hideAllBut(menuNum);
- litNow = getTree(menuNum, itemNum);
- changeCol(litNow, true);
- targetNum = menu[menuNum][itemNum].target;
- if (targetNum > 0) {
- thisX = parseInt(menu[menuNum][0].ref.left) + parseInt(menu[menuNum][itemNum].ref.left);
- thisY = parseInt(menu[menuNum][0].ref.top) + parseInt(menu[menuNum][itemNum].ref.top);
- with (menu[targetNum][0].ref) {
- left = parseInt(thisX + menu[targetNum][0].x);
- top = parseInt(thisY + menu[targetNum][0].y);
- visibility = 'visible';
- }
- }
-}
-function popOut(menuNum, itemNum) {
- if ((menuNum == 0) && !menu[menuNum][itemNum].target)
- hideAllBut(0)
- if (KO) document.getElementById("win1").style.visibility = "visible";
- else
- popTimer = setTimeout('hideAllBut(0)', 500);
-}
-function getTree(menuNum, itemNum) {
- itemArray = new Array(menu.length);
- while(1) {
- itemArray[menuNum] = itemNum;
- if (menuNum == 0) return itemArray;
- itemNum = menu[menuNum][0].parentItem;
- menuNum = menu[menuNum][0].parentMenu;
- }
-}
-function changeCol(changeArray, isOver) {
- for (menuCount = 0; menuCount < changeArray.length; menuCount++) {
- if (changeArray[menuCount]) {
- newCol = isOver ? menu[menuCount][0].overCol : menu[menuCount][0].backCol;
- with (menu[menuCount][changeArray[menuCount]].ref) {
- if (isNS4) bgColor = newCol;
- else backgroundColor = newCol;
- }
- }
- }
-}
-function hideAllBut(menuNum) {
- var keepMenus = getTree(menuNum, 1);
- for (count = 0; count < menu.length; count++)
- if (!keepMenus[count])
- menu[count][0].ref.visibility = 'hidden';
- changeCol(litNow, false);
-}
-
-function Menu(isVert, popInd, x, y, width, overCol, backCol, borderClass, textClass) {
- this.isVert = isVert;
- this.popInd = popInd
- this.x = x;
- this.y = y;
- this.width = width;
- this.overCol = overCol;
- this.backCol = backCol;
- this.borderClass = borderClass;
- this.textClass = textClass;
- this.parentMenu = null;
- this.parentItem = null;
- this.ref = null;
-}
-function Item(text, href, frame, length, spacing, target) {
- this.text = text;
- this.href = href;
- this.frame = frame;
- this.length = length;
- this.spacing = spacing;
- this.target = target;
- this.ref = null;
-}
-function go(link,frame) {
- tmp=eval("top."+frame);
- tmp.location=link;
- //top.main_window.location=link;
-}
-function writeMenus() {
- if (!isDOM && !isIE4 && !isNS4) return;
- for (currMenu = 0; currMenu < menu.length; currMenu++) with (menu[currMenu][0]) {
- var str = '', itemX = 0, itemY = 0;
- for (currItem = 1; currItem < menu[currMenu].length; currItem++) with (menu[currMenu][currItem]) {
- var itemID = 'menu' + currMenu + 'item' + currItem;
- var w = (isVert ? width : length);
- var h = (isVert ? length : width);
- if (isDOM \|\| isIE4) {
- str += '<div id="' + itemID + '" style="position: absolute; left: ' + itemX + '; top: ' + itemY + '; width: ' + w + '; height: ' + h + '; visibility: inherit; ';
- if (backCol) str += 'background: ' + backCol + '; ';
- str += '" ';
- }
- if (isNS4) {
- str += '<layer id="' + itemID + '" left="' + itemX + '" top="' + itemY + '" width="' + w + '" height="' + h + '" visibility="inherit" ';
- if (backCol) str += 'bgcolor="' + backCol + '" ';
- }
- if (borderClass) str += 'class="' + borderClass + '" "';
- str += 'onMouseOver="popOver(' + currMenu + ',' + currItem + ')" onMouseOut="popOut(' + currMenu + ',' + currItem + ')">';
- str += '<table width="' + (w - 8) + '" border="0" cellspacing="0" cellpadding="' + (!isNS4 && borderClass ? 3 : 0) + '">';
- str +='<tr><td class="' + textClass + '" style="cursor:pointer;" align="left" height="' + (h - 7) + '" onClick=\\'go("' + href + '","' + frame + '")\\'>' + text + '</a></td>';
- if (target > 0) {
- menu[target][0].parentMenu = currMenu;
- menu[target][0].parentItem = currItem;
- if (popInd) str += '<td class="' + textClass + '" align="right">' + popInd + '</td>';
- }
- str += '</tr></table>' + (isNS4 ? '</layer>' : '</div>');
- if (isVert) itemY += length + spacing;
- else itemX += length + spacing;
- }
- if (isDOM) {
- var newDiv = document.createElement('div');
- document.getElementsByTagName('body').item(0).appendChild(newDiv);
- newDiv.innerHTML = str;
- ref = newDiv.style;
- ref.position = 'absolute';
- ref.visibility = 'hidden';
- }
- if (isIE4) {
- document.body.insertAdjacentHTML('beforeEnd', '<div id="menu' + currMenu + 'div" ' + 'style="position: absolute; visibility: hidden">' + str + '</div>');
- ref = getSty('menu' + currMenu + 'div');
- }
- if (isNS4) {
- ref = new Layer(0);
- ref.document.write(str);
- ref.document.close();
- }
- for (currItem = 1; currItem < menu[currMenu].length; currItem++) {
- itemName = 'menu' + currMenu + 'item' + currItem;
- if (isDOM \|\| isIE4) menu[currMenu][currItem].ref = getSty(itemName);
- if (isNS4) menu[currMenu][currItem].ref = ref.document[itemName];
- }
- }
- with(menu[0][0]) {
- ref.left = x;
- ref.top = y;
- ref.visibility = 'visible';
- }
-}
-var menu = new Array();
-var defOver = '#cccccc';
-var defBack = '#dddddd';
-var defLength = 22;
-menu[0] = new Array();
-menu[0][0] = new Menu(false, '', 5, 18, 19, '#cccccc', '', '', 'rootItemText');
-
-|;
-
- §ion_menu($menu);
-
- print qq|
-var popOldWidth = window.innerWidth;
-nsResizeHandler = new Function('if (popOldWidth != window.innerWidth) location.reload()');
-if (isNS4) document.captureEvents(Event.CLICK);
-document.onclick = clickHandle;
-function clickHandle(evt) {
- if (isNS4) document.routeEvent(evt);
- hideAllBut(0);
- if (KO) document.getElementById("win1").style.visibility = "visible";
-}
-function moveRoot() {
- with(menu[0][0].ref) left = ((parseInt(left) < 100) ? 100 : 5);
-}
-// End -->
-</script>
-
-<BODY scrolling="no" topmargin="0" leftmargin="0" marginwidth="0" marginheight="0" style="margin: 0" onLoad="writeMenus(); clockon();" onResize="if (isNS4) nsResizeHandler()">
-
-
-<table class="menu" width="100%" border="0" cellpadding="0" cellspacing="0">
-<tr><td height="21"><font size="1"> </font></td></tr></table>
-
-
-|;
-
- print qq|
-
-|;
-
-}
-
-sub section_menu {
- my ($menu, $level) = @_;
-
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- # build tiered menus
- my @menuorder = $menu->access_control(\%myconfig, $level);
- my $main = 0;
-
- #$pm=0;
- my $shlp=0;
- my (%mlz, $sm, $z, $pm, $mm);
- while (@menuorder) {
- my $item = shift @menuorder;
- my $label = $item;
- my $ml = $item;
- $label =~ s/$level--//g;
- $ml =~ s/--.*//;
- $label = $::locale->text($label);
- $label =~ s/ / /g;
- $menu->{$item}{target} = "main_window" unless $menu->{$item}{target};
-
- if ($menu->{$item}{submenu}) {
- $menu->{$item}{$item} = !$form->{$item};
-
- # Untermen
- if ($mlz{"s$ml"} > 1) {
- $z++;
- $sm = 1;
- } else {
- $z = $sm;
- $mlz{"s$ml"}++;
- }
- print
- qq|menu[$mlz{$ml}][$z] = new Item('$label', '#', '', defLength, 0, |
- . ++$pm
- . qq|);\n|;
- $sm = 1;
- print qq|menu[$pm] = new Array();\n|;
- print
- qq|menu[$pm][0] = new Menu(true, '', 85, 0, 180, defOver, defBack, 'itemBorder', 'itemText');\n|;
- map { shift @menuorder } grep /^$item/, @menuorder;
- §ion_menu($menu, $item);
- map { shift @menuorder } grep /^$item/, @menuorder;
- } else {
- if ($menu->{$item}{module}) {
-
- #Untermenüpunkte
- my $target = $menu->{$item}{target};
- my $uri = $menu->menuitem_js(\%myconfig, \%$form, $item, $level);
-
- print
- qq|menu[$pm][$sm] = new Item('$label', '$uri', '$target', defLength, 0, 0);\n|;
- $sm++;
- } else { # Hauptmenu
- my $ml_ = $form->escape($ml);
- $mm++;
- $pm++;
- %mlz = ($ml, $pm, "s$ml", 1);
- $shlp = $sm;
- $sm = 1;
- my $breit = 15 + length($label) * 6;
- print
- qq|menu[0][$mm] = new Item(' $label', '#', '', $breit, 10, $pm); \n|;
- print qq|menu[$pm] = new Array();\n|;
- print
- qq|menu[$pm][0] = new Menu(true, '>', 0, 20, 180, defOver, defBack, 'itemBorder', 'itemText');\n|;
-
- §ion_menu($menu, $item);
-
- #print qq|<br>\n|;
- }
- }
- }
-}
+++ /dev/null
-#=====================================================================
-# LX-Office ERP
-# Copyright (C) 2004
-# Based on SQL-Ledger Version 2.1.9
-# Web http://www.lx-office.org
-#
-######################################################################
-# SQL-Ledger Accounting
-# Copyright (c) 1998-2002
-#
-# Author: Dieter Simader
-# Email: dsimader@sql-ledger.org
-# Web: http://www.sql-ledger.org
-#
-# Contributors: Christopher Browne
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#######################################################################
-#
-# thre frame layout with refractured menu
-#
-#######################################################################
-
-use English qw(-no_match_vars);
-use List::Util qw(max);
-use URI;
-
-use SL::Menu;
-
-use strict;
-
-1;
-
-# end of main
-
-sub display {
- my $form = $main::form;
-
- $form->header();
-
-# $form->{force_ul_width} = $ENV{HTTP_USER_AGENT} =~ m/MSIE\s+6\./;
-# $form->{force_ul_width} = $ENV{HTTP_USER_AGENT} !~ m/Opera/;
- $form->{force_ul_width} = 1;
- $form->{date} = clock_line();
- $form->{menu_items} = acc_menu();
- my $callback = $form->unescape($form->{callback});
- $callback = URI->new($callback)->rel($callback) if $callback;
- $callback = "login.pl?action=company_logo" if $callback =~ /^(\.\/)?$/;
- $form->{callback} = $callback;
-
- print $form->parse_html_template("menu/menunew");
-}
-
-sub clock_line {
- my $form = $main::form;
-
- my ($Sekunden, $Minuten, $Stunden, $Monatstag, $Monat,
- $Jahr, $Wochentag, $Jahrestag, $Sommerzeit)
- = localtime(time);
- $Monat += 1;
- $Jahrestag += 1;
- $Monat = $Monat < 10 ? $Monat = "0" . $Monat : $Monat;
- $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
- $Jahr += 1900;
- my @Wochentage = ("Sonntag", "Montag", "Dienstag", "Mittwoch",
- "Donnerstag", "Freitag", "Samstag");
- my @Monatsnamen = ("", "Januar", "Februar", "März",
- "April", "Mai", "Juni", "Juli",
- "August", "September", "Oktober", "November",
- "Dezember");
- return
- $Wochentage[$Wochentag] . ", der "
- . $Monatstag . "."
- . $Monat . "."
- . $Jahr . " - ";
-}
-
-sub acc_menu {
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- my $mainlevel = $form->{level};
- $mainlevel =~ s/\Q$mainlevel\E--//g;
- my $menu = Menu->new('menu.ini');
-
- $English::AUTOFLUSH = 1;
-
- my $all_items = [];
- create_menu($menu, $all_items);
-
- my $item = { 'subitems' => $all_items };
- calculate_width($item);
-
- return $all_items;
-}
-
-sub calculate_width {
- my $item = shift;
-
- $item->{max_width} = max map { length $_->{title} } @{ $item->{subitems} };
-
- foreach my $subitem (@{ $item->{subitems} }) {
- calculate_width($subitem) if ($subitem->{subitems});
- }
-}
-
-sub create_menu {
- my ($menu, $all_items, $parent, $depth) = @_;
- my $html;
-
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- die if ($depth * 1 > 5);
-
- my @menuorder = $menu->access_control(\%myconfig, $parent);
- $parent .= "--" if ($parent);
-
- foreach my $name (@menuorder) {
- substr($name, 0, length($parent), "");
- next if (($name eq "") || ($name =~ /--/));
-
- my $menu_item = $menu->{"${parent}${name}"};
- my $item = { 'title' => $::locale->text($name) };
- push @{ $all_items }, $item;
-
- if ($menu_item->{submenu} || !defined($menu_item->{module}) || ($menu_item->{module} eq "menu.pl")) {
- $item->{subitems} = [];
- $item->{image} = _icon_path("$name.png");
- create_menu($menu, $item->{subitems}, "${parent}${name}", $depth * 1 + 1);
-
- } else {
- $item->{image} = _icon_path("${parent}${name}.png");
- $menu->menuitem_new("${parent}${name}", $item);
- }
- }
-}
-
-sub _icon_path {
- my ($label, $size) = @_;
-
- $size ||= 16;
-
- my $img = "image/icons/${size}x${size}/$label";
-
- return unless -f $img;
- return $img;
-}
-
+++ /dev/null
-#=====================================================================
-# LX-Office ERP
-# Copyright (C) 2004
-# Based on SQL-Ledger Version 2.1.9
-# Web http://www.lx-office.org
-#
-######################################################################
-# SQL-Ledger Accounting
-# Copyright (c) 1998-2002
-#
-# Author: Dieter Simader
-# Email: dsimader@sql-ledger.org
-# Web: http://www.sql-ledger.org
-#
-# Contributors: Christopher Browne
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#######################################################################
-#
-# thre frame layout with refractured menu
-#
-#######################################################################
-
-use SL::Menu;
-use URI;
-
-use strict;
-
-1;
-
-# end of main
-
-sub display {
- my $form = $main::form;
-
- $form->header(extra_code => qq|<link rel="stylesheet" href="css/menuv3.css?id=" type="text/css">|);
-
- $form->{date} = clock_line();
- $form->{menu} = acc_menu();
- my $callback = $form->unescape($form->{callback});
- $callback = URI->new($callback)->rel($callback) if $callback;
- $callback = "login.pl?action=company_logo" if $callback =~ /^(\.\/)?$/;
- $form->{callback} = $callback;
-
- print $form->parse_html_template("menu/menuv3");
-
-}
-
-sub clock_line {
- my ($Sekunden, $Minuten, $Stunden, $Monatstag, $Monat,
- $Jahr, $Wochentag, $Jahrestag, $Sommerzeit)
- = localtime(time);
- $Monat += 1;
- $Jahrestag += 1;
- $Monat = $Monat < 10 ? $Monat = "0" . $Monat : $Monat;
- $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
- $Jahr += 1900;
- my @Wochentage = ("Sonntag", "Montag", "Dienstag", "Mittwoch",
- "Donnerstag", "Freitag", "Samstag");
- my @Monatsnamen = ("", "Januar", "Februar", "März",
- "April", "Mai", "Juni", "Juli",
- "August", "September", "Oktober", "November",
- "Dezember");
- return
- $Wochentage[$Wochentag] . ", der "
- . $Monatstag . "."
- . $Monat . "."
- . $Jahr . " - ";
-}
-
-sub acc_menu {
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- my $mainlevel = $form->{level};
- $mainlevel =~ s/\Q$mainlevel\E--//g;
- my $menu = Menu->new("menu.ini");
-
- $| = 1;
-
- return print_menu($menu);
-}
-
-sub print_menu {
- my ($menu, $parent, $depth) = @_;
-
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- my $html;
-
- die if ($depth * 1 > 5);
-
- my @menuorder;
-
- @menuorder = $menu->access_control(\%myconfig, $parent);
-
- $parent .= "--" if ($parent);
-
- foreach my $item (@menuorder) {
- substr($item, 0, length($parent)) = "";
- next if (($item eq "") || ($item =~ /--/));
-
- my $menu_item = $menu->{"${parent}${item}"};
- my $menu_title = $::locale->text($item);
- my $menu_text = $menu_title;
-
- my $target = "main_window";
- $target = $menu_item->{"target"} if ($menu_item->{"target"});
-
- if ($menu_item->{"submenu"} || !defined($menu_item->{"module"}) ||
- ($menu_item->{"module"} eq "menu.pl")) {
-
- my $h = print_menu($menu, "${parent}${item}", $depth * 1 + 1)."\n";
- if (!$parent) {
- $html .= qq|<ul><li><h2>${menu_text}</h2><ul>${h}</ul></li></ul>\n|;
- } else {
- $html .= qq|<li><div class="x">${menu_text}</div><ul>${h}</ul></li>\n|;
- }
- } else {
- $html .= qq|<li>|;
- $html .= $menu->menuitem_v3(\%myconfig, $form, "${parent}$item",
- { "title" => $menu_title,
- "target" => $target });
- $html .= qq|${menu_text}</a></li>\n|;
- }
- }
-
- return $html;
-}
+++ /dev/null
-#=====================================================================
-# LX-Office ERP
-# Copyright (C) 2004
-# Based on SQL-Ledger Version 2.1.9
-# Web http://www.lx-office.org
-#
-######################################################################
-# SQL-Ledger Accounting
-# Copyright (c) 1998-2002
-#
-# Author: Dieter Simader
-# Email: dsimader@sql-ledger.org
-# Web: http://www.sql-ledger.org
-#
-# Contributors: Christopher Browne
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#######################################################################
-#
-# thre frame layout with refractured menu
-#
-#######################################################################
-
-use SL::Menu;
-use URI;
-
-use strict;
-
-1;
-
-# end of main
-
-sub display {
- my $form = $main::form;
-
- $form->header(extra_code => qq|<link rel="stylesheet" href="css/menuv4.css?id=" type="text/css">|);
-
- $form->{date} = clock_line();
- $form->{menu} = acc_menu();
- my $callback = $form->unescape($form->{callback});
- $callback = URI->new($callback)->rel($callback) if $callback;
- $callback = "login.pl?action=company_logo" if $callback =~ /^(\.\/)?$/;
- $form->{callback} = $callback;
-
- print $form->parse_html_template("menu/menuv4");
-
-}
-
-sub clock_line {
- my $form = $main::form;
-
- my ($Sekunden, $Minuten, $Stunden, $Monatstag, $Monat,
- $Jahr, $Wochentag, $Jahrestag, $Sommerzeit)
- = localtime(time);
- $Monat += 1;
- $Jahrestag += 1;
- $Monat = $Monat < 10 ? $Monat = "0" . $Monat : $Monat;
- $Monatstag = $Monatstag < 10 ? $Monatstag = "0" . $Monatstag : $Monatstag;
- $Jahr += 1900;
- my @Wochentage = ("Sonntag", "Montag", "Dienstag", "Mittwoch",
- "Donnerstag", "Freitag", "Samstag");
- my @Monatsnamen = ("", "Januar", "Februar", "März",
- "April", "Mai", "Juni", "Juli",
- "August", "September", "Oktober", "November",
- "Dezember");
- return
- $Wochentage[$Wochentag] . ", der "
- . $Monatstag . "."
- . $Monat . "."
- . $Jahr . " - ";
-}
-
-sub acc_menu {
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- my $mainlevel = $form->{level};
- $mainlevel =~ s/\Q$mainlevel\E--//g;
- my $menu = Menu->new("menu.ini");
-
- $| = 1;
-
- return print_menu($menu);
-}
-
-sub print_menu {
- my ($menu, $parent, $depth) = @_;
-
- my $form = $main::form;
- my %myconfig = %main::myconfig;
-
- my $html;
-
- die if ($depth * 1 > 5);
-
- my @menuorder;
-
- @menuorder = $menu->access_control(\%myconfig, $parent);
-
- $parent .= "--" if ($parent);
-
- foreach my $item (@menuorder) {
- substr($item, 0, length($parent)) = "";
- next if (($item eq "") || ($item =~ /--/));
-
- my $menu_item = $menu->{"${parent}${item}"};
- my $menu_title = $::locale->text($item);
- my $menu_text = $menu_title;
-
- my $target = "main_window";
- $target = $menu_item->{"target"} if ($menu_item->{"target"});
-
- if ($menu_item->{"submenu"} || !defined($menu_item->{"module"}) ||
- ($menu_item->{"module"} eq "menu.pl")) {
-
- my $h = print_menu($menu, "${parent}${item}", $depth * 1 + 1)."\n";
- if (!$parent) {
- $html .= qq|<ul><li><h2> ${menu_text} </h2><ul>${h}</ul></li></ul>\n|;
- } else {
- $html .= qq|<li><div class="x">${menu_text}</div><ul>${h}</ul></li>\n|;
- }
- } else {
- if ($depth>1) {
- $html .= qq|<li class='sub'>|;
- } else {
- $html .= qq|<li>|;
- }
- $html .= $menu->menuitem_v3(\%myconfig, $form, "${parent}$item",
- { "title" => $menu_title,
- "target" => $target });
- $html .= qq|${menu_text}</a></li>\n|;
- }
- }
-
- return $html;
-}
}
}
- my $onload = "";
+ my $dispatch_to_popup = '';
if ($form->{resubmit} && ($form->{format} eq "html")) {
- $onload = "window.open('about:blank','Beleg'); document.oe.target = 'Beleg';";
- $onload .= "document.do.submit();";
+ $dispatch_to_popup = "window.open('about:blank','Beleg'); document.oe.target = 'Beleg';";
+ $dispatch_to_popup .= "document.do.submit();";
} elsif ($form->{resubmit}) {
# emulate click for resubmitting actions
- $onload = "document.oe.${_}.click(); " for grep { /^action_/ } keys %$form;
- $onload .= "document.oe.submit();";
+ $dispatch_to_popup = "document.oe.${_}.click(); " for grep { /^action_/ } keys %$form;
+ $dispatch_to_popup .= "document.oe.submit();";
} elsif ($creditwarning) {
- $onload = "alert('$credittext')";
+ $::request->{layout}->add_javascripts_inline("alert('$credittext')");
}
- $TMPL_VAR{onload} = $onload;
+ $::request->{layout}->add_javascripts_inline("\$(function(){$dispatch_to_popup})");
$TMPL_VAR{dateformat} = $myconfig{dateformat};
$TMPL_VAR{numberformat} = $myconfig{numberformat};
$form->{simple_save} = 1;
if(!$form->{print_and_save}) {
- delete @{$form}{ary_diff([keys %{ $form }], [qw(login stylesheet id script type cursor_fokus)])};
+ delete @{$form}{ary_diff([keys %{ $form }], [qw(login id script type cursor_fokus)])};
edit();
::end_of_request();
}
$form->header;
print qq|
-<body>
-
<form method=post action=$form->{script}>
|;
. $locale->text('Continue') . qq|">
</form>
-
-</body>
-</html>
|;
$main::lxdebug->leave_sub();
$::form->{AR} = [ grep { $_->{link} =~ m/(?:^|:)AR(?::|$)/ } @{ $::form->{ALL_CHARTS} } ];
$::form->{title} = $::locale->text('Edit the configuration for periodic invoices');
- $::form->header();
+ $::form->header(no_layout => 1);
print $::form->parse_html_template('oe/edit_periodic_invoices_config', $config);
$::lxdebug->leave_sub();
$::form->get_lists("projects" => { "key" => "ALL_PROJECTS", "all" => 1 });
- my $onload = qq|focus()|;
-
my $is_projects = $::form->{report} eq "projects";
my $is_income_statement = $::form->{report} eq "income_statement";
my $is_bwa = $::form->{report} eq "bwa";
vc => $vc,
label => $label,
year => DateTime->today->year,
- onload => $onload,
nextsub => $nextsub,
accrual => $::instance_conf->get_accounting_method ne 'cash',
cash => $::instance_conf->get_accounting_method eq 'cash',
$form->header();
-# print qq|
-# <body>
-# |;
-
my $elsterland = '';
my $elster_amt = '';
my $elsterFFFF = '';
$form->{jsscript} = 1;
# $form->{fokus} = "partnumber";
-# $form->{onload} .= "focus();";
$form->{title} = $locale->text("Report about warehouse contents");
$form->header();
--- /dev/null
+.icon16 { background: url(../image/maps/icons16.png) 16px 0px no-repeat; padding: 0; width: 16px; height: 16px; }
+.icon16.AP--Add-Purchase-Order { background-position: -0px 0px; }
+.icon16.AP--Add-RFQ { background-position: -16px 0px; }
+.icon16.AP { background-position: -32px 0px; }
+.icon16.AP--Reports { background-position: -48px 0px; }
+.icon16.AP--Reports--Purchase-Orders { background-position: -64px 0px; }
+.icon16.AP--Reports--RFQs { background-position: -80px 0px; }
+.icon16.AR--Add-Credit-Note { background-position: -96px 0px; }
+.icon16.AR--Add-Delivery-Order { background-position: -112px 0px; }
+.icon16.AR--Add-Dunning { background-position: -128px 0px; }
+.icon16.AR--Add-Quotation { background-position: -144px 0px; }
+.icon16.AR--Add-Sales-Invoice { background-position: -160px 0px; }
+.icon16.AR--Add-Sales-Order { background-position: -176px 0px; }
+.icon16.AR { background-position: -192px 0px; }
+.icon16.AR--Reports--Delivery-Orders { background-position: -208px 0px; }
+.icon16.AR--Reports--Dunnings { background-position: -224px 0px; }
+.icon16.AR--Reports--Invoices { background-position: -240px 0px; }
+.icon16.AR--Reports { background-position: -256px 0px; }
+.icon16.AR--Reports--Quotations { background-position: -272px 0px; }
+.icon16.AR--Reports--Sales-Orders { background-position: -288px 0px; }
+.icon16.Batch-Printing--Packing-Lists { background-position: -304px 0px; }
+.icon16.Batch-Printing { background-position: -320px 0px; }
+.icon16.Batch-Printing--Purchase-Orders { background-position: -336px 0px; }
+.icon16.Batch-Printing--Quotations { background-position: -352px 0px; }
+.icon16.Batch-Printing--Receipts { background-position: -368px 0px; }
+.icon16.Batch-Printing--RFQs { background-position: -384px 0px; }
+.icon16.Batch-Printing--Sales-Invoices { background-position: -400px 0px; }
+.icon16.Batch-Printing--Sales-Orders { background-position: -416px 0px; }
+.icon16.Cash--Payment { background-position: -432px 0px; }
+.icon16.Cash { background-position: -448px 0px; }
+.icon16.Cash--Receipt { background-position: -464px 0px; }
+.icon16.Cash--Reconciliation { background-position: -480px 0px; }
+.icon16.Cash--Reports--Payments { background-position: -496px 0px; }
+.icon16.Cash--Reports { background-position: -512px 0px; }
+.icon16.Cash--Reports--Receipts { background-position: -528px 0px; }
+.icon16.CRM--Admin--Benutzer { background-position: -544px 0px; }
+.icon16.CRM--Admin--Dokumentvorlage { background-position: -560px 0px; }
+.icon16.CRM--Admin--Etiketten { background-position: -576px 0px; }
+.icon16.CRM--Admin--Gruppen { background-position: -592px 0px; }
+.icon16.CRM--Admin--Mitteilungen { background-position: -608px 0px; }
+.icon16.CRM--Admin { background-position: -624px 0px; }
+.icon16.CRM--Admin--Status { background-position: -640px 0px; }
+.icon16.CRM--Auftragschance { background-position: -656px 0px; }
+.icon16.CRM--eMail { background-position: -672px 0px; }
+.icon16.CRM--Hilfe { background-position: -688px 0px; }
+.icon16.CRM--Kunden { background-position: -704px 0px; }
+.icon16.CRM--Lieferant { background-position: -720px 0px; }
+.icon16.CRM--Notizen { background-position: -736px 0px; }
+.icon16.CRM--Personen { background-position: -752px 0px; }
+.icon16.CRM { background-position: -768px 0px; }
+.icon16.CRM--Schnellsuche { background-position: -784px 0px; }
+.icon16.CRM--Service { background-position: -800px 0px; }
+.icon16.CRM--Termine { background-position: -816px 0px; }
+.icon16.CRM--Wiedervorlage { background-position: -832px 0px; }
+.icon16.CRM--Wissens-DB { background-position: -848px 0px; }
+.icon16.General-Ledger--Add-AP-Transaction { background-position: -864px 0px; }
+.icon16.General-Ledger--Add-AR-Transaction { background-position: -880px 0px; }
+.icon16.General-Ledger--Add-Transaction { background-position: -896px 0px; }
+.icon16.General-Ledger--DATEV---Export-Assistent { background-position: -912px 0px; }
+.icon16.General-Ledger { background-position: -928px 0px; }
+.icon16.General-Ledger--Reports--AP-Aging { background-position: -944px 0px; }
+.icon16.General-Ledger--Reports--AR-Aging { background-position: -960px 0px; }
+.icon16.General-Ledger--Reports--Journal { background-position: -976px 0px; }
+.icon16.General-Ledger--Reports { background-position: -992px 0px; }
+.icon16.Master-Data--Add-Assembly { background-position: -1008px 0px; }
+.icon16.Master-Data--Add-Customer { background-position: -1024px 0px; }
+.icon16.Master-Data--Add-License { background-position: -1040px 0px; }
+.icon16.Master-Data--Add-Part { background-position: -1056px 0px; }
+.icon16.Master-Data--Add-Project { background-position: -1072px 0px; }
+.icon16.Master-Data--Add-Service { background-position: -1088px 0px; }
+.icon16.Master-Data--Add-Vendor { background-position: -1104px 0px; }
+.icon16.Master-Data { background-position: -1120px 0px; }
+.icon16.Master-Data--Reports--Assemblies { background-position: -1136px 0px; }
+.icon16.Master-Data--Reports--Customers { background-position: -1152px 0px; }
+.icon16.Master-Data--Reports--Licenses { background-position: -1168px 0px; }
+.icon16.Master-Data--Reports--Parts { background-position: -1184px 0px; }
+.icon16.Master-Data--Reports { background-position: -1200px 0px; }
+.icon16.Master-Data--Reports--Projects { background-position: -1216px 0px; }
+.icon16.Master-Data--Reports--Projecttransactions { background-position: -1232px 0px; }
+.icon16.Master-Data--Reports--Services { background-position: -1248px 0px; }
+.icon16.Master-Data--Reports--Vendors { background-position: -1264px 0px; }
+.icon16.Master-Data--Update-Prices { background-position: -1280px 0px; }
+.icon16.MDI-Text-Editor-16x16 { background-position: -1296px 0px; }
+.icon16.Neues-Fenster { background-position: -1312px 0px; }
+.icon16.Program--Logout { background-position: -1328px 0px; }
+.icon16.Program { background-position: -1344px 0px; }
+.icon16.Program--Preferences { background-position: -1360px 0px; }
+.icon16.Program--Version { background-position: -1376px 0px; }
+.icon16.Reports--Balance-Sheet { background-position: -1392px 0px; }
+.icon16.Reports--Chart-of-Accounts { background-position: -1408px 0px; }
+.icon16.Reports--Income-Statement { background-position: -1424px 0px; }
+.icon16.Reports { background-position: -1440px 0px; }
+.icon16.Reports--UStVa { background-position: -1456px 0px; }
+.icon16.System { background-position: -1472px 0px; }
+.icon16.Warehouse { background-position: -1488px 0px; }
+.icon16.Warehouse--Produce-Assembly { background-position: -1504px 0px; }
--- /dev/null
+.icon24 { background: url(../image/maps/icons24.png) 24px 0px no-repeat; padding: 0; width: 24px; height: 24px; }
+.icon24.AP--Add-Purchase-Order { background-position: -0px 0px; }
+.icon24.AP--Add-RFQ { background-position: -24px 0px; }
+.icon24.AP { background-position: -48px 0px; }
+.icon24.AP--Reports { background-position: -72px 0px; }
+.icon24.AP--Reports--Purchase-Orders { background-position: -96px 0px; }
+.icon24.AP--Reports--RFQs { background-position: -120px 0px; }
+.icon24.AR--Add-Dunning { background-position: -144px 0px; }
+.icon24.AR--Add-Quotation { background-position: -168px 0px; }
+.icon24.AR--Add-Sales-Invoice { background-position: -192px 0px; }
+.icon24.AR--Add-Sales-Order { background-position: -216px 0px; }
+.icon24.AR { background-position: -240px 0px; }
+.icon24.AR--Reports--Dunnings { background-position: -264px 0px; }
+.icon24.AR--Reports--Invoices { background-position: -288px 0px; }
+.icon24.AR--Reports { background-position: -312px 0px; }
+.icon24.AR--Reports--Quotations { background-position: -336px 0px; }
+.icon24.AR--Reports--Sales-Orders { background-position: -360px 0px; }
+.icon24.Batch-Printing--Packing-Lists { background-position: -384px 0px; }
+.icon24.Batch-Printing { background-position: -408px 0px; }
+.icon24.Batch-Printing--Purchase-Orders { background-position: -432px 0px; }
+.icon24.Batch-Printing--Quotations { background-position: -456px 0px; }
+.icon24.Batch-Printing--Receipts { background-position: -480px 0px; }
+.icon24.Batch-Printing--RFQs { background-position: -504px 0px; }
+.icon24.Batch-Printing--Sales-Invoices { background-position: -528px 0px; }
+.icon24.Batch-Printing--Sales-Orders { background-position: -552px 0px; }
+.icon24.Cash--Payment { background-position: -576px 0px; }
+.icon24.Cash { background-position: -600px 0px; }
+.icon24.Cash--Receipt { background-position: -624px 0px; }
+.icon24.Cash--Reconciliation { background-position: -648px 0px; }
+.icon24.Cash--Reports--Payments { background-position: -672px 0px; }
+.icon24.Cash--Reports { background-position: -696px 0px; }
+.icon24.Cash--Reports--Receipts { background-position: -720px 0px; }
+.icon24.CRM--Admin--Benutzer { background-position: -744px 0px; }
+.icon24.CRM--Admin--Dokumentvorlage { background-position: -768px 0px; }
+.icon24.CRM--Admin--Etiketten { background-position: -792px 0px; }
+.icon24.CRM--Admin--Gruppen { background-position: -816px 0px; }
+.icon24.CRM--Admin--Mitteilungen { background-position: -840px 0px; }
+.icon24.CRM--Admin { background-position: -864px 0px; }
+.icon24.CRM--Admin--Status { background-position: -888px 0px; }
+.icon24.CRM--Auftragschance { background-position: -912px 0px; }
+.icon24.CRM--eMail { background-position: -936px 0px; }
+.icon24.CRM--Hilfe { background-position: -960px 0px; }
+.icon24.CRM--Kunden { background-position: -984px 0px; }
+.icon24.CRM--Lieferant { background-position: -1008px 0px; }
+.icon24.CRM--Notizen { background-position: -1032px 0px; }
+.icon24.CRM--Personen { background-position: -1056px 0px; }
+.icon24.CRM { background-position: -1080px 0px; }
+.icon24.CRM--Schnellsuche { background-position: -1104px 0px; }
+.icon24.CRM--Service { background-position: -1128px 0px; }
+.icon24.CRM--Termine { background-position: -1152px 0px; }
+.icon24.CRM--Wiedervorlage { background-position: -1176px 0px; }
+.icon24.CRM--Wissens-DB { background-position: -1200px 0px; }
+.icon24.General-Ledger--Add-AP-Transaction { background-position: -1224px 0px; }
+.icon24.General-Ledger--Add-AR-Transaction { background-position: -1248px 0px; }
+.icon24.General-Ledger--Add-Transaction { background-position: -1272px 0px; }
+.icon24.General-Ledger--DATEV---Export-Assistent { background-position: -1296px 0px; }
+.icon24.General-Ledger { background-position: -1320px 0px; }
+.icon24.General-Ledger--Reports--AP-Aging { background-position: -1344px 0px; }
+.icon24.General-Ledger--Reports--AR-Aging { background-position: -1368px 0px; }
+.icon24.General-Ledger--Reports--Journal { background-position: -1392px 0px; }
+.icon24.General-Ledger--Reports { background-position: -1416px 0px; }
+.icon24.leftarrow_24 { background-position: -1440px 0px; }
+.icon24.Master-Data--Add-Assembly { background-position: -1464px 0px; }
+.icon24.Master-Data--Add-Customer { background-position: -1488px 0px; }
+.icon24.Master-Data--Add-License { background-position: -1512px 0px; }
+.icon24.Master-Data--Add-Part { background-position: -1536px 0px; }
+.icon24.Master-Data--Add-Project { background-position: -1560px 0px; }
+.icon24.Master-Data--Add-Service { background-position: -1584px 0px; }
+.icon24.Master-Data--Add-Vendor { background-position: -1608px 0px; }
+.icon24.Master-Data { background-position: -1632px 0px; }
+.icon24.Master-Data--Reports--Assemblies { background-position: -1656px 0px; }
+.icon24.Master-Data--Reports--Customers { background-position: -1680px 0px; }
+.icon24.Master-Data--Reports--Licenses { background-position: -1704px 0px; }
+.icon24.Master-Data--Reports--Parts { background-position: -1728px 0px; }
+.icon24.Master-Data--Reports { background-position: -1752px 0px; }
+.icon24.Master-Data--Reports--Projects { background-position: -1776px 0px; }
+.icon24.Master-Data--Reports--Projecttransactions { background-position: -1800px 0px; }
+.icon24.Master-Data--Reports--Services { background-position: -1824px 0px; }
+.icon24.Master-Data--Reports--Vendors { background-position: -1848px 0px; }
+.icon24.Neues-Fenster { background-position: -1872px 0px; }
+.icon24.Productivity { background-position: -1896px 0px; }
+.icon24.Program--Logout { background-position: -1920px 0px; }
+.icon24.Program { background-position: -1944px 0px; }
+.icon24.Program--Preferences { background-position: -1968px 0px; }
+.icon24.Program--Version { background-position: -1992px 0px; }
+.icon24.Reports--Balance-Sheet { background-position: -2016px 0px; }
+.icon24.Reports--Chart-of-Accounts { background-position: -2040px 0px; }
+.icon24.Reports--Income-Statement { background-position: -2064px 0px; }
+.icon24.Reports { background-position: -2088px 0px; }
+.icon24.Reports--UStVa { background-position: -2112px 0px; }
+.icon24.rightarrow_24 { background-position: -2136px 0px; }
+.icon24.System { background-position: -2160px 0px; }
+.icon24.Warehouse { background-position: -2184px 0px; }
--- /dev/null
+.icon32 { background: url(../image/maps/icons32.png) 32px 0px no-repeat; padding: 0; width: 32px; height: 32px; }
+.icon32.AP--Add-Purchase-Order { background-position: -0px 0px; }
+.icon32.AP--Add-RFQ { background-position: -32px 0px; }
+.icon32.AP { background-position: -64px 0px; }
+.icon32.AP--Reports { background-position: -96px 0px; }
+.icon32.AP--Reports--Purchase-Orders { background-position: -128px 0px; }
+.icon32.AP--Reports--RFQs { background-position: -160px 0px; }
+.icon32.AR--Add-Dunning { background-position: -192px 0px; }
+.icon32.AR--Add-Quotation { background-position: -224px 0px; }
+.icon32.AR--Add-Sales-Invoice { background-position: -256px 0px; }
+.icon32.AR--Add-Sales-Order { background-position: -288px 0px; }
+.icon32.AR { background-position: -320px 0px; }
+.icon32.AR--Reports--Dunnings { background-position: -352px 0px; }
+.icon32.AR--Reports--Invoices { background-position: -384px 0px; }
+.icon32.AR--Reports { background-position: -416px 0px; }
+.icon32.AR--Reports--Quotations { background-position: -448px 0px; }
+.icon32.AR--Reports--Sales-Orders { background-position: -480px 0px; }
+.icon32.Batch-Printing--Packing-Lists { background-position: -512px 0px; }
+.icon32.Batch-Printing { background-position: -544px 0px; }
+.icon32.Batch-Printing--Purchase-Orders { background-position: -576px 0px; }
+.icon32.Batch-Printing--Quotations { background-position: -608px 0px; }
+.icon32.Batch-Printing--Receipts { background-position: -640px 0px; }
+.icon32.Batch-Printing--RFQs { background-position: -672px 0px; }
+.icon32.Batch-Printing--Sales-Invoices { background-position: -704px 0px; }
+.icon32.Batch-Printing--Sales-Orders { background-position: -736px 0px; }
+.icon32.Cash--Payment { background-position: -768px 0px; }
+.icon32.Cash { background-position: -800px 0px; }
+.icon32.Cash--Receipt { background-position: -832px 0px; }
+.icon32.Cash--Reconciliation { background-position: -864px 0px; }
+.icon32.Cash--Reports--Payments { background-position: -896px 0px; }
+.icon32.Cash--Reports { background-position: -928px 0px; }
+.icon32.Cash--Reports--Receipts { background-position: -960px 0px; }
+.icon32.CRM--Admin--Benutzer { background-position: -992px 0px; }
+.icon32.CRM--Admin--Dokumentvorlage { background-position: -1024px 0px; }
+.icon32.CRM--Admin--Etiketten { background-position: -1056px 0px; }
+.icon32.CRM--Admin--Gruppen { background-position: -1088px 0px; }
+.icon32.CRM--Admin--Mitteilungen { background-position: -1120px 0px; }
+.icon32.CRM--Admin { background-position: -1152px 0px; }
+.icon32.CRM--Admin--Status { background-position: -1184px 0px; }
+.icon32.CRM--Auftragschance { background-position: -1216px 0px; }
+.icon32.CRM--eMail { background-position: -1248px 0px; }
+.icon32.CRM--Hilfe { background-position: -1280px 0px; }
+.icon32.CRM--Kunden { background-position: -1312px 0px; }
+.icon32.CRM--Lieferant { background-position: -1344px 0px; }
+.icon32.CRM--Notizen { background-position: -1376px 0px; }
+.icon32.CRM--Personen { background-position: -1408px 0px; }
+.icon32.CRM { background-position: -1440px 0px; }
+.icon32.CRM--Schnellsuche { background-position: -1472px 0px; }
+.icon32.CRM--Service { background-position: -1504px 0px; }
+.icon32.CRM--Termine { background-position: -1536px 0px; }
+.icon32.CRM--Wiedervorlage { background-position: -1568px 0px; }
+.icon32.CRM--Wissens-DB { background-position: -1600px 0px; }
+.icon32.General-Ledger--Add-AP-Transaction { background-position: -1632px 0px; }
+.icon32.General-Ledger--Add-AR-Transaction { background-position: -1664px 0px; }
+.icon32.General-Ledger--Add-Transaction { background-position: -1696px 0px; }
+.icon32.General-Ledger--DATEV---Export-Assistent { background-position: -1728px 0px; }
+.icon32.General-Ledger { background-position: -1760px 0px; }
+.icon32.General-Ledger--Reports--AP-Aging { background-position: -1792px 0px; }
+.icon32.General-Ledger--Reports--AR-Aging { background-position: -1824px 0px; }
+.icon32.General-Ledger--Reports--Journal { background-position: -1856px 0px; }
+.icon32.General-Ledger--Reports { background-position: -1888px 0px; }
+.icon32.Master-Data--Add-Assembly { background-position: -1920px 0px; }
+.icon32.Master-Data--Add-Customer { background-position: -1952px 0px; }
+.icon32.Master-Data--Add-License { background-position: -1984px 0px; }
+.icon32.Master-Data--Add-Part { background-position: -2016px 0px; }
+.icon32.Master-Data--Add-Project { background-position: -2048px 0px; }
+.icon32.Master-Data--Add-Service { background-position: -2080px 0px; }
+.icon32.Master-Data--Add-Vendor { background-position: -2112px 0px; }
+.icon32.Master-Data { background-position: -2144px 0px; }
+.icon32.Master-Data--Reports--Assemblies { background-position: -2176px 0px; }
+.icon32.Master-Data--Reports--Customers { background-position: -2208px 0px; }
+.icon32.Master-Data--Reports--Licenses { background-position: -2240px 0px; }
+.icon32.Master-Data--Reports--Parts { background-position: -2272px 0px; }
+.icon32.Master-Data--Reports { background-position: -2304px 0px; }
+.icon32.Master-Data--Reports--Projects { background-position: -2336px 0px; }
+.icon32.Master-Data--Reports--Projecttransactions { background-position: -2368px 0px; }
+.icon32.Master-Data--Reports--Services { background-position: -2400px 0px; }
+.icon32.Master-Data--Reports--Vendors { background-position: -2432px 0px; }
+.icon32.Neues-Fenster { background-position: -2464px 0px; }
+.icon32.Program--Logout { background-position: -2496px 0px; }
+.icon32.Program { background-position: -2528px 0px; }
+.icon32.Program--Preferences { background-position: -2560px 0px; }
+.icon32.Program--Version { background-position: -2592px 0px; }
+.icon32.Reports--Balance-Sheet { background-position: -2624px 0px; }
+.icon32.Reports--Chart-of-Accounts { background-position: -2656px 0px; }
+.icon32.Reports--Income-Statement { background-position: -2688px 0px; }
+.icon32.Reports { background-position: -2720px 0px; }
+.icon32.Reports--UStVa { background-position: -2752px 0px; }
+.icon32.System { background-position: -2784px 0px; }
+.icon32.Warehouse--Produce-Assembly { background-position: -2816px 0px; }
th.login {
text-align: right;
}
-body.admin {
+div.admin {
background-color: #FFFFE0;
+ padding: 8px;
color: #000000;
}
body.menu {
position: relativ: left: 10px;
}
/* End of non-anchor hover selectors */
+
+/* html menu */
+/* types of lines: m sm i (menu submenu item)
+ each line is a mi (menuitem) and has one mii (menu-item-icon) whcih is ms (menu-spacer)
+ and one mic (menu-item-chunk)
+ indenting is done with the levels s0, s1, s2 */
+#content.html-menu, #html-menu {
+ transition: margin-left 0.2s, width 0.2s;
+ -moz-transition: margin-left 0.2s, width 0.2s;
+ -webkit-transition: margin-left 0.2s, width 0.2s;
+ -o-transition: margin-left 0.2s, width 0.2s;
+}
+#content.html-menu { margin-left: 190px; }
+#content.html-menu.folded { margin-left: 40px }
+#html-menu.folded:hover + #content.html-menu.folded { margin-left: 190px }
+#html-menu { float:left; width: 183px; font-size: 8pt; margin-top: 10px; overflow:hidden; }
+#html-menu.folded { width: 32px; }
+#html-menu.folded:hover { width: 183px; }
+#html-menu div.mi { margin-top: 4px; margin-bottom: 3px; white-space: nowrap; clear:both; position:relative; }
+#html-menu div.sm { font-weight: bold }
+#html-menu img { vertical-align: top; border: 0; }
+#html-menu a { vertical-align: top }
+#html-menu .i span.ms { float: left; width: 24px; margin-bottom: 4px; }
+#html-menu .m span.ms { float: left; width: 32px }
+#html-menu .sm span.ms { float: left; width: 24px; background: url(../../image/unterpunkt.png); }
+#html-menu div.m { height: 24px }
+#html-menu div.m span.mic { color:black; position: relative; top: 4px }
+#html-menu div.m:hover,
+#html-menu div.i:hover { color:blue; background-color: #d1d1d1; cursor: pointer; }
+#html-menu span.mic { white-space: normal; display: inline-block; vertical-align: top; line-height: 1.2; }
+#html-menu a.ml span.mic { width: 145px } /* fix deep indents */
+#html-menu div.s0 { padding-left: 2px }
+#html-menu div.s1 { padding-left: 8px }
+#html-menu div.s2 { padding-left: 16px }
+
+body { margin: 0 }
-.frame-header-element a:link,
-.frame-header-element a:visited,
-.frame-header-element a:hover,
-.frame-header-element a:active {
+#frame-header .frame-header-element a:link,
+#frame-header .frame-header-element a:visited,
+#frame-header .frame-header-element a:hover,
+#frame-header .frame-header-element a:active {
color: white;
background: none;
text-decoration: underline;
}
-body.frame-header {
- background: url('../../../image/fade.png') repeat-x;
-}
-
-div.frame-header {
+#frame-header {
background: url('../../../image/bg_titel.gif') repeat-x;
text-align: center;
-}
-
-.frame-header {
margin: 0;
padding: 0;
color: white;
overflow: hidden;
width: 100%;
border-spacing: 0;
+ font-size: 12px;
}
-.frame-header-left {
+#frame-header .frame-header-left {
float: left;
}
-.frame-header-right {
+#frame-header .frame-header-right {
float: right;
}
-.frame-header-left,
-.frame-header-center,
-.frame-header-right {
+#frame-header .frame-header-left,
+#frame-header .frame-header-center,
+#frame-header .frame-header-right {
border-spacing: 0;
color: white;
padding: 0;
background-color: lemonchiffon;
text-decoration: none;
}
+a, div {
+ transition: background-color 0.2s;
+ -moz-transition: background-color 0.2s;
+ -webkit-transition: background-color 0.2s;
+}
+
+input, textarea, select {
+ border: 1px;
+ border-color: darkgray lightgray lightgray;
+ border-style: solid;
+ padding: 1px;
+ background-color: white;
+}
+
+select {
+ padding: 0px;
+}
input:focus, textarea:focus, select:focus {
- background-color: yellow;
+ background-color: whitesmoke;
+ border: 1px;
+ border-color: gray lightgray lightgray;
+ border-style: solid;
+}
+
+input:hover, textarea:hover, select:hover {
+ border-color: dimgray darkgray darkgray;
+}
+
+input[type="button"],
+input[type="submit"],
+button,
+input[type="button"]:focus,
+input[type="submit"]:focus,
+button:focus {
+ border: 1px;
+ border-color: darkgray;
+ border-style: solid;
+ padding: 0px 4px;
+ -webkit-border-radius: 2px;
+ -moz-border-radius: 2px;
+ border-radius: 2px;
+ background-color: whitesmoke;
+}
+
+button:hover,
+input[type="button"]:hover,
+input[type="submit"]:hover {
+ border: 1px;
+ background-color: lightgray;
+ border-color: gray;
+ border-style: solid;
+ -webkit-border-radius: 2px;
+ -moz-border-radius: 2px;
+ border-radius: 2px;
+}
+
+html {
+ height: 100%;
}
body {
background-color: white;
background-image: url("../../image/fade.png"); background-repeat:repeat-x;
color: black;
+ height: 100%;
}
td {
.login {
font-family: Verdana, Arial, Helvetica, sans-serif;
}
-body.login {
+div.login {
+ min-height: 100%;
+ height: auto !important;
+ height: 100%;
background: #b8d1f3;
color: #A0A0A0;
}
text-align: right;
}
-body.admin {
- background-color:#ffffff;
+div.admin {
color: black;
+ margin: 8px;
}
.message_error_login {
border-style:none;
border-width:thin;
}
+
+
/* End of non-anchor hover selectors */
-
+/* html menu */
+/* types of lines: m sm i (menu submenu item)
+ each line is a mi (menuitem) and has one mii (menu-item-icon) whcih is ms (menu-spacer)
+ and one mic (menu-item-chunk)
+ indenting is done with the levels s0, s1, s2 */
+#content.html-menu, #html-menu {
+ transition: margin-left 0.2s, width 0.2s;
+ -moz-transition: margin-left 0.2s, width 0.2s;
+ -webkit-transition: margin-left 0.2s, width 0.2s;
+ -o-transition: margin-left 0.2s, width 0.2s;
+}
+#content.html-menu { margin-left: 190px; }
+#content.html-menu.folded { margin-left: 40px }
+#html-menu.folded:hover + #content.html-menu.folded { margin-left: 190px }
+#html-menu { float:left; width: 183px; font-size: 8pt; margin-top: 10px; overflow:hidden; }
+#html-menu.folded { width: 32px; }
+#html-menu.folded:hover { width: 183px; }
+#html-menu div.mi { margin-top: 4px; margin-bottom: 3px; white-space: nowrap; clear:both; position:relative; }
+#html-menu div.sm { font-weight: bold }
+#html-menu img { vertical-align: top; border: 0; }
+#html-menu a { vertical-align: top }
+#html-menu .i span.ms { float: left; width: 24px; margin-bottom: 4px; }
+#html-menu .m span.ms { float: left; width: 32px }
+#html-menu .sm span.ms { float: left; width: 24px; background: url(../../image/unterpunkt.png); }
+#html-menu div.m { height: 24px }
+#html-menu div.m span.mic { color:blue; position: relative; top: 4px }
+#html-menu div.m:hover,
+#html-menu div.i:hover { color:blue; background-color: lemonchiffon; cursor: pointer; }
+#html-menu span.mic { white-space: normal; display: inline-block; vertical-align: top; line-height: 1.2; }
+#html-menu a.ml span.mic { width: 145px } /* fix deep indents */
+#html-menu div.s0 { padding-left: 2px }
+#html-menu div.s1 { padding-left: 8px }
+#html-menu div.s2 { padding-left: 16px }
+
+body { margin: 0 }
+<!DOCTYPE html>
<html>
<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="refresh" content="0;URL=controller.pl?action=LoginScreen/user_login">
</head>
<body>
--- /dev/null
+function load_layout(baseURL){
+ $.ajax({
+ url: baseURL + 'controller.pl?action=Layout/empty&format=json',
+ method: 'GET',
+ dataType: 'json',
+ success: function (data) {
+ if (data["stylesheets"]) {
+ $.each(data["stylesheets"], function(i, e){
+ $('head').append('<link rel="stylesheet" href="' + baseURL + e + '" type="text/css" title="Stylesheet">');
+ });
+ }
+ if (data["stylesheets_inline"] && data["stylesheets_inline"].size) {
+ var style = "<style type='text/css'>";
+ $.each(data["stylesheets_inline"], function(i, e){
+ style += e;
+ });
+ style += '</style>';
+ $('head').append(style);
+ }
+ if (data["start_content"]) {
+ $('body').wrapInner(data["start_content"]);
+ }
+ if (data["pre_content"]) {
+ $('body').prepend(data["pre_content"]);
+ }
+ if (data["post_content"]) {
+ $('body').append(data["post_content"]);
+ }
+ if (data["javascripts"]) {
+ $.each(data["javascripts"], function(i, e){
+ $('head').append('<script type="text/javascript" src="' + baseURL + e + '">');
+ });
+ }
+ if (data["javascripts_inline"]) {
+ var script = "<script type='text/javascript'>";
+ $.each(data["javascripts_inline"], function(i, e){
+ script += e;
+ });
+ script += '</script>';
+ $('head').append(script);
+ }
+ }
+ });
+}
getTopPos : function(inputObj)\r
{ \r
var returnValue = inputObj.offsetTop;\r
+ if (returnValue > 700) returnValue = 0;\r
while((inputObj = inputObj.offsetParent) != null){\r
if(inputObj.tagName!='HTML'){\r
returnValue += (inputObj.offsetTop - inputObj.scrollTop);\r
var cssPrefix; // Css prefix for the menu items.\r
var modelItemRef; // Reference to menuModelItem\r
\r
- this.layoutCSS = 'menu-item.css';\r
+// this.layoutCSS = 'menu-item.css';\r
this.cssPrefix = 'DHTMLSuite_';\r
\r
if(!standardObjectsCreated)DHTMLSuite.createStandardObjects(); \r
*/\r
createItem : function(menuModelItemObj)\r
{\r
- DHTMLSuite.commonObj.loadCSS(this.layoutCSS); // Load css\r
+// DHTMLSuite.commonObj.loadCSS(this.layoutCSS); // Load css\r
\r
DHTMLSuite.variableStorage.arrayOfDhtmlSuiteObjects[this.objectIndex] = this;\r
\r
var globalObjectIndex; // Global index of this object - used to refer to the object of this class outside\r
this.cssPrefix = 'DHTMLSuite_';\r
this.menuItemLayoutCss = false; // false = use default for the menuItem class.\r
- this.layoutCSS = 'menu-bar.css';\r
+// this.layoutCSS = 'menu-bar.css';\r
this.menuBarBackgroundImage = 'menu_strip_bg.jpg';\r
this.menuItem_objects = new Array();\r
DHTMLSuite.variableStorage.menuBar_highlightedItems = new Array();\r
init : function()\r
{\r
\r
- DHTMLSuite.commonObj.loadCSS(this.layoutCSS); \r
+// DHTMLSuite.commonObj.loadCSS(this.layoutCSS); \r
this.__createDivs(); // Create general divs\r
this.__createMenuItems(); // Create menu items\r
this.__setBasicEvents(); // Set basic events.\r
$('div.DHTMLSuite_menuBar_top').click(function(e) {\r
if ($(e.target).attr('class') == 'DHTMLSuite_menuBar_top') { menu.hideSubMenus(); menu.unsetMenuBarState() }\r
});\r
- $('#win1').load(function(){\r
- $('#win1').contents().mousedown(function(){\r
- menu.hideSubMenus();\r
- menu.menuBarState = false;\r
- });\r
- })\r
+ $('#content').mousedown(function(){\r
+ menu.hideSubMenus();\r
+ menu.menuBarState = false;\r
+ });\r
}\r
}\r
\r
--- /dev/null
+/*jshint eqnull:true */
+/*!
+* jQuery Cookie Plugin v1.2
+* https://github.com/carhartl/jquery-cookie
+*
+* Copyright 2011, Klaus Hartl
+* Dual licensed under the MIT or GPL Version 2 licenses.
+* http://www.opensource.org/licenses/mit-license.php
+* http://www.opensource.org/licenses/GPL-2.0
+*/
+(function ($, document, undefined) {
+
+var pluses = /\+/g;
+
+function raw(s) {
+ return s;
+}
+
+function decoded(s) {
+ return decodeURIComponent(s.replace(pluses, ' '));
+}
+
+var config = $.cookie = function (key, value, options) {
+ // write
+ if (value !== undefined) {
+ options = $.extend({}, config.defaults, options);
+
+ if (value === null) {
+ options.expires = -1;
+ }
+
+ if (typeof options.expires === 'number') {
+ var days = options.expires, t = options.expires = new Date();
+ t.setDate(t.getDate() + days);
+ }
+
+ value = config.json ? JSON.stringify(value) : String(value);
+
+ return (document.cookie = [
+ encodeURIComponent(key), '=', config.raw ? value : encodeURIComponent(value),
+ options.expires ? '; expires=' + options.expires.toUTCString() : '', // use expires attribute, max-age is not supported by IE
+ options.path ? '; path=' + options.path : '',
+ options.domain ? '; domain=' + options.domain : '',
+ options.secure ? '; secure' : ''
+ ].join(''));
+ }
+
+ // read
+ var decode = config.raw ? raw : decoded;
+ var cookies = document.cookie.split('; ');
+ for (var i = 0, parts; (parts = cookies[i] && cookies[i].split('=')); i++) {
+ if (decode(parts.shift()) === key) {
+ var cookie = decode(parts.join('='));
+ return config.json ? JSON.parse(cookie) : cookie;
+ }
+ }
+
+ return null;
+};
+
+config.defaults = {};
+
+$.removeCookie = function (key, options) {
+ if ($.cookie(key) !== null) {
+ $.cookie(key, null, options);
+ return true;
+ }
+ return false;
+};
+
+})(jQuery, document);
var vSwitch_Menu = 1;
-var FrameSize = (parent.document.getElementById('menuframe').cols);
-
-function Switch_Menu()
-{
- if (vSwitch_Menu)
- {
- vSwitch_Menu=false;
- parent.document.getElementById('menuframe').setAttribute('cols','30,*');
- }
- else
- {
- vSwitch_Menu=true;
- parent.document.getElementById('menuframe').setAttribute('cols',FrameSize);
- }
- return;
+function Switch_Menu() {
+ vSwitch_Menu=!vSwitch_Menu;
+ SetMenuFolded(vSwitch_Menu);
}
+function SetMenuFolded(on) {
+ if (on) {
+ $('#html-menu').removeClass('folded');
+ $('#content').removeClass('folded');
+ } else {
+ $('#html-menu').addClass('folded');
+ $('#content').addClass('folded');
+ }
+}
+$(function(){
+ SetMenuFolded(vSwitch_Menu);
+})
+++ /dev/null
-am.pl
\ No newline at end of file
+++ /dev/null
-am.pl
\ No newline at end of file
+++ /dev/null
-am.pl
\ No newline at end of file
+++ /dev/null
-am.pl
\ No newline at end of file
+++ /dev/null
-am.pl
\ No newline at end of file
--- /dev/null
+#!/usr/bin/perl
+
+use strict;
+use GD;
+use Getopt::Long;
+use File::Basename;
+
+
+my $css_file = 'generated.css';
+my $image_file = 'generated.png';
+my $class_for_map = 'icon';
+
+GetOptions(
+ 'css-out=s' => \$css_file,
+ 'image-out=s' => \$image_file,
+ 'icon-class=s' => \$class_for_map,
+);
+
+my @files = @ARGV;
+my @gd_images;
+
+GD::Image->trueColor(1);
+
+# read files
+
+for my $filename (@files) {
+ my $image = GD::Image->newFromPng($filename);
+ if (!defined $image) {
+ warn "warning: could not load image '$filename'. skpping...";
+ next;
+ }
+ push @gd_images, {
+ gd => $image,
+ filename => $filename,
+ };
+}
+
+# make target layout
+# for simplification thi will check if all the images have the same dimensions
+# and croak if not
+my $first_height = $gd_images[0]->{gd}->height;
+my $first_width = $gd_images[0]->{gd}->width;
+
+use Data::Dumper;
+
+for my $img (@gd_images) {
+ die 'heights are not equal' if $first_height != $img->{gd}->height;
+ die 'widths are not equal' if $first_width != $img->{gd}->width;
+}
+
+# all equal? nice.
+# we'll be lazy and just put them all together left-to-right
+my $new_height = $first_height;
+my $new_width = $first_width * @gd_images;
+
+my $new_image = GD::Image->new($new_width, $new_height, 1);
+# now copy them all together, and keep a referende to;
+
+$new_image->saveAlpha(1);
+$new_image->alphaBlending(0);
+
+my $h_offset = 0;
+for (@gd_images) {
+ $_->{h_offset} = $h_offset;
+ $_->{v_offset} = 0;
+ $new_image->copy($_->{gd}, $_->{h_offset}, $_->{v_offset}, 0, 0, $_->{gd}->width, $_->{gd}->height);
+} continue {
+ $h_offset += $_->{gd}->width;
+}
+
+# now write that png...
+{
+ open my $file, '>:raw', $image_file or die "can't write to $image_file";
+ print $file $new_image->png;
+}
+
+# make css file
+{
+ open my $file, ">", $css_file or die "can't write too $css_file";
+ print $file ".$class_for_map { background: url(../$image_file) ${first_width}px 0px no-repeat; padding: 0; width: ${first_width}px; height: ${first_height}px; }\n";
+
+ for (@gd_images) {
+ my $name = fileparse($_->{filename}, ".png");
+ $name =~ s/ /-/g;
+ print $file ".$class_for_map.$name { background-position: -$_->{h_offset}px 0px; }\n";
+ }
+}
+
+1;
+
+__END__
+
+=encoding utf-8
+
+=head1 NAME
+
+image_maps - generates image maps for css sprites from images in a directory
+
+=head1 SYNOPSIS
+
+ scripts/image_maps.pl \
+ --out-css=css/icons_16.css \
+ --out-image= image/maps/icons_16.png \
+ image/icons/16x16/*
+
+=head1 DESCRIPTION
+
+=head1 OPTIONS
+
+=head1 BUGS
+
+None yet. :)
+
+=head1 AUTHOR
+
+Sven Schoeling E<lt>s.schoeling@linet-services.deE<gt>
+
+=cut
+
+
--- /dev/null
+scripts/image_maps.pl --icon-class=icon16 --css-out=css/icons16.css --image-out=image/maps/icons16.png image/icons/16x16/*.png
+scripts/image_maps.pl --icon-class=icon24 --css-out=css/icons24.css --image-out=image/maps/icons24.png image/icons/24x24/*.png
+scripts/image_maps.pl --icon-class=icon32 --css-out=css/icons32.css --image-out=image/maps/icons32.png image/icons/32x32/*.png
[%- USE T8 %]
[% USE HTML %]
[%- USE L %]
-<body>
<h1>[% title %]</h1>
<p>
<input type="hidden" name="action" value="analyze">
</form>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %][% USE LxERP %]
-<body>
<p><div class="listtop">[% title %]</div></p>
<hr>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %][% USE LxERP %]
-<body>
<p><div class="listtop">[% title %]</div></p>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %][% USE LxERP %]
-<body>
<p><div class="listtop">[% title %]</div></p>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %][% USE LxERP %]
-<body>
<p><div class="listtop">[% title %]</div></p>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %][% USE LxERP %]
-<body>
<p><div class="listtop">[% title %]</div></p>
-->
</script>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
[% USE LxERP %]
-<body>
<h1>[% title %]</h1>
<p>
<input type="submit" value="[% 'Re-run analysis' | $T8 %]">
</form>
</p>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
[% USE LxERP %]
-<body>
<h1>[% title %]</h1>
<p>
<input type="button" onclick="history.back()" value="[% 'No' | $T8 %]">
</form>
</p>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
-<body>
<p><div class="listtop">[% title %]</div></p>
</form>
</p>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
-<body>
<p><div class="listtop">[% title %]</div></p>
</form>
</p>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
-<body>
<p><div class="listtop">[% title %]</div></p>
</form>
</p>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
[% USE LxERP%]
-<body class="admin" onload="document.getElementById('rpw').focus()">
+ <script type='text/javascript'>
+ $(function(){ document.getElementsById('rpw').focus();});
+ </script>
<div align="center">
<a href="http://www.kivitendo.org"><img src="image/kivitendo.png" border="0"></a>
</div>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="admin" onload="set_subject(); document.getElementsByName('to')[0].focus(); ">
-
+[%- USE HTML %]
<script type="text/javascript">
<!--
- function set_subject() {
+ $(function(){
+ document.getElementsByName('to')[0].focus();
+ set_subject();
+ });
+
+ function set_subject () {
var subject_template = "[% 'Backup of dataset' | $T8 %]";
var subject = document.Form.subject.value;
[% END %]
-</body>
-</html>
[%- USE T8 %]
[%- USE LxERP %]
-[% USE HTML %]<body class="admin">
-
+[%- USE HTML %]
<h2>[% title %]</h2>
<p>[% LxERP.t8('The dataset backup has been sent via email to #1.', to) | html %]</p>
<input type="hidden" name="nextsub" value="list_users">
<input type="submit" name="action" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="admin">
-
+[%- USE HTML %]
<h2>[% title %]</h2>
<form method="post" action="admin.pl">
-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="admin">
-
+[%- USE HTML %]
<h2>[% title %]</h2>
<form method="post" action="admin.pl">
<p>[% 'Leave host and port field empty unless you want to make a remote connection.' | $T8 %]</p>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE LxERP %]
-<body class="admin">
-
<h2>[% title %]</h2>
<form method="post" action="admin.pl">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE LxERP %]
-[% USE HTML %]<body class="admin">
-
+[%- USE HTML %]
<h2>[% title %]</h2>
<form method="post" action="admin.pl">
<p><input type="submit" class="submit" name="action" value="[% 'Continue' | $T8 %]"></p>
</form>
-</body>
-</html>
<input type="submit" name="action" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="admin">
-
+[%- USE HTML %]
<h2>[% title %]</h2>
<p><a href="admin.pl?action=pg_database_administration">[% 'Back' | $T8 %]</a></p>
<form method="post" action="admin.pl">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% 'Delete group' | $T8 %]: [% name %]</div>
<p class="message_hint">[ [% name %] ] - [% 'Do you really want to delete this group?' | $T8 %]</p>
<input type="submit" class="submit" name="action" value="[% 'Delete' | $T8 %]">
</form>
- </body>
-</html>
[% USE T8 %][% USE HTML %][% USE L %][% USE LxERP -%]
-<body>
[% L.stylesheet_tag('jquery.multiselect2side') %]
[% L.javascript_tag('jquery.selectboxes', 'jquery.multiselect2side') %]
</form>
[% L.multiselect2side('user_ids_', labelsx => LxERP.t8('All users'), labeldx => LxERP.t8('Users in this group')) %]
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %][% USE LxERP %]<body>
+[%- USE HTML %][%- USE LxERP %]
<div class="listtop">[% 'Edit group membership' | $T8 %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% 'Edit groups' | $T8 %]</div>
[% IF message %]
</form>
-</body>
-</html>
+ <hr size="2" noshade>
[%- USE T8 %]
[%- USE HTML %]
[%- USE L %]
-<body class="admin">
-
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript">
-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="admin" onload="">
-
+[%- USE HTML %]
<h1>[% title %]</h1>
<form method="post" action="admin.pl">
<hr size="3" noshade>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="admin" onload="document.getElementsByName('dbname')[0].focus(); ">
+[%- USE HTML %]
+ <script type='text/javascript'>
+ $(function(){ document.getElementsByName('dbname')[0].focus();});
+ </script>
<h2>[% title %]</h2>
</form>
-</body>
-</html>
<input type="hidden" name="nextsub" value="list_users">
<input type="submit" name="action" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-<body class="admin">
-
<h2>[% title %]</h2>
<p>[%- 'The restoration process has started. Here\'s the output of the "pg_restore" command:' | $T8 %]</p>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
</p>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="admin">
-
+[%- USE HTML %]
<h2>[% title %]</h2>
<p><a href="admin.pl?action=pg_database_administration">[% 'Back' | $T8 %]</a></p>
[% IF ALL_UPDATED %]
[% END %]
-</body>
-</html>
[%- USE T8 %]
[%- USE LxERP %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-<body>
<form method=post>
</form>
-</body>
-</html>
[%- USE T8 %]
-<body>
<form method='post'>
<h1 class=listtop>[% title %]</h1>
<input type="submit" name='get_login_form' value="[% 'Back' | $T8 %]">
<input type="submit" name="add_printer" value ="[% 'Add' | $T8 %]">
</form>
-</body>
-</html>
[%- USE LxERP %]
[%- USE T8 %]
[%- USE L %]
-<body>
<h1>[% title | html %]</h1>
</form>
-</body>
-</html>
[%- USE L %]
[%- USE LxERP %]
[%- USE T8 %]
-<body>
<h1>[% title | html %]</h1>
[%- USE L %]
[%- USE LxERP %]
[%- USE T8 %]
-<body>
<h1>[% title | html %]</h1>
</form>
- </body>
- </html>
[%- USE T8 %]
[%- USE LxERP %]
-[% USE HTML %][% USE L %]<body onLoad="fokus()">
-
+[%- USE HTML %][%- USE L %]
<p>
<div class="listtop">[% title %]</div>
</p>
-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
<input type="submit" class="submit" name="action" value="[% 'Delete' | $T8 %]">
</form>
-</body>
</form>
</script>
<script type="text/javascript">
-window.onload = function() {
+$(function() {
setupDependencies('EditAccount'); //name of form(s). Seperate each with a comma (ie: 'weboptions', 'myotherform' )
- };
+});
</script>
-<body>
<form method="post" name="EditAccount" action="am.pl">
<input type="hidden" name="id" value="[% HTML.escape(id) %]">
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
[% IF MESSAGE %]<p>[% MESSAGE %]</p>[% END %]
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<form method="post" action="am.pl">
<input type="hidden" name="id" value="[% HTML.escape(id) %]">
<input type="hidden" name="type" value="tax">
[% END %]
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<h1>[% title %]</h1>
</form>
-</body>
-</html>
<script type="text/javascript" src="js/jquery-ui.js"></script>
-<body>
[% IF saved_message %]
<p>[% saved_message %]</p>
[% L.sortable_element('#unit_list tbody', url => 'controller.pl?action=Unit/reorder', with => 'unit_id') %]
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body [% IF onload %]onload="[% onload %]"[% END %]>
-
+[%- USE HTML %]
[% IF saved_message %]
<p>[% saved_message %]</p>
[% END %]
[% END %]
-</body>
-</html>
</form>
-</body>
-</html>
[%- USE HTML %]
[%- USE LxERP %]
[%- USE T8 %]
-<body>
<form method=post action=am.pl>
[%- USE L %]
[%- USE LxERP %]
[%- USE T8 %]
-<body>
<h1>[% title | html %]</h1>
</form>
- </body>
- </html>
[%- USE HTML %]
[%- USE T8 %]
-<body>
<form method=post action=am.pl>
[%- USE HTML %]
[%- USE LxERP %]
[%- USE L %]
-<body>
<table width=100%>
<tr>
</form>
- </body>
- </html>
[%- USE T8 %]
[%- USE HTML %]
-<body>
<h1>[% title %]</h1>
<table width="100%">
</table>
-</body>
<script type='text/javascript'>
function account_details(id) {
$.ajax({
</script>
-</html>
<script type="text/javascript" src="js/jquery-ui.js"></script>
-<body>
[% IF MESSAGE %]<p>[% MESSAGE %]</p>[% END %]
[% L.sortable_element('#price_factor_list tbody', url => 'controller.pl?action=PriceFactor/reorder', with => 'price_factor_id') %]
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop">[% title %]</div>
</form>
</p>
-</body>
-</html>
<script type="text/javascript" src="js/jquery-ui.js"></script>
-<body>
[% IF saved_message %]<p>[% saved_message %]</p>[% END %]
[% L.sortable_element('#warehouse_list tbody', url => 'controller.pl?action=Warehouse/reorder', with => 'warehouse_id') %]
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="document.Form.name.focus();">
+[%- USE HTML %]
+ <script type='text/javascript'>
+ $(function(){document.Form.name.focus();});
+ </script>
<style type="text/css">
.small {
</form>
-</body>
-</html>
<script type="text/javascript" src="js/jquery-ui.js"></script>
-<body>
[% IF MESSAGE %]<p>[% MESSAGE %]</p>[% END %]
[% L.sortable_element('#cvarcfg_list tbody', url => 'controller.pl?action=CustomVariableConfig/reorder', with => 'cvarcfg_id') %]
-</body>
-</html>
</form>
-</body>
-</html>
</script>
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-<body>
<form method=post name="search" action=[% script %]>
<br>
<input class=submit type=submit name=action value="[% 'Continue' | $T8 %]">
</form>
- </body>
- <script type="text/javascript">
- <!--
- $(document).ready(function(){
- focus();
- setupDateFormat('[% dateformat | html %]','[% 'Falsches Datumsformat!' | $T8 %]');
- setupPoints('[% numberformat | html %]','[% 'wrongformat' | $T8 %]');
- })
- //-->
- </script>
-</html>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE LxERP %]
-<body onLoad="[% onload %]">
-
<form method=post name="arledger" action="[% script %]">
[% L.hidden_tag('id', id) %]
[%- USE T8 %]
[%- USE L %]
-<body>
<form method=post name="search" action=[% script %]>
<!--
$(document).ready(function(){
$('customer').focus();
- setupDateFormat('[% dateformat | html %]','[% 'Falsches Datumsformat!' | $T8 %]');
- setupPoints('[% numberformat | html %]','[% 'wrongformat' | $T8 %]');
})
//-->
</script>
- </body>
-</html>
[%- USE T8 %]
[%- USE L %]
[%- USE LxERP %]
-<body>
<h1>[% 'Select from one of the projects below' | $T8 %]</h1>
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<h1>[% FORM.title %]</h1>
<a href="[% SELF.url_for(action => 'list') %]">[%- LxERP.t8('Abort') %]</a>
</p>
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<h1>[% FORM.title %]</h1>
[%- INCLUDE 'common/flash.html' %]
<a href="[% SELF.url_for(controller => 'TaskServer', action => 'show') %]">[%- LxERP.t8('Task server control') %]</a>
</p>
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<h1>[% FORM.title %]</h1>
[%- INCLUDE 'common/flash.html' %]
<a href="[% SELF.url_for(controller => 'TaskServer', action => 'show') %]">[%- LxERP.t8('Task server control') %]</a>
</p>
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<h1>[% FORM.title %]</h1>
<p>
<a href="[% back_to %]">[%- LxERP.t8('Back') %]</a>
</p>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
-<body>
[%- IF params.error %]
<p><div class="message_error">[% params.error %]</div></p>
</p>
</form>
-</body>
-</html>
[%- USE url %]
[%- SET list_spool__callback = href _ '&sort=' _ sort %]
[% L.javascript_tag('jquery.checkall') %]
-<body>
<h1>[% title | html %]</h1>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE LxERP %]
[%- USE HTML %]
-<body>
<form method=post action=bp.pl>
<h1>[% 'Print' | $T8 %] [% label.$type.title %]</h1>[% L.hidden_tag('title', LxERP.t8('Print') _ ' ' _ label.$type.title) %]
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<form method="post" action="controller.pl">
<div class="listtop">[% FORM.title %]</div>
<a href="[% SELF.url_for(action => 'list') %]">[%- LxERP.t8('Abort') %]</a>
</p>
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<div class="listtop">[% FORM.title %]</div>
[%- INCLUDE 'common/flash.html' %]
<a href="[% SELF.url_for(action => 'new') %]">[%- LxERP.t8('Create new business') %]</a>
</p>
</form>
-</body>
-</html>
[% USE T8 %]
[% USE HTML %]
[% USE LxERP %]
-
-<body onLoad="[% onload %]">
-
<form method=post action="[% script %]">
[% L.hidden_tag('accno', accno) %]
<br>[% L.submit_tag('action', LxERP.t8('List Transactions')) %]
</form>
-</body>
-</html>
//-->
</script>
-</body>
-</html>
<hr>
[% END %]
-<body>
<div width="100%" class="listtop">
[% IF is_customer %][% 'Customer details' | $T8 %][% ELSE %][% 'Vendor details' | $T8 %][% END %] "[% HTML.escape(name) %]"
[% END %]
-</body>
-</html>
<input class=submit type=submit name=action value="[% 'Post' | $T8 %]">
</form>
-</body>
-</html>
[%- USE HTML %]
[%- USE T8 %]
[%- USE LxERP %]
-<body onload=[% onload %]>
-
<form method=post action=cp.pl>
[% L.hidden_tag('defaultcurrency', defaultcurrency) %]
[%- USE LxERP %]
[%- USE L %]
[%- USE T8 %]
-<body>
<div class="listtop">[% FORM.title %]</div>
});
-->
</script>
-</body>
-</html>
-->
</script>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %][% USE LxERP %]
[% USE L %]
-<body>
<h1>[% title %]</h1>
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %]<body onload="fokus()">
-
+[%- USE HTML %]
<form method="post" action="ct.pl" name="Form">
<input type="hidden" name="db" value="[% HTML.escape(db) %]">
<input type="submit" class="submit" name="action" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE HTML %]
[%- USE T8 %]
-<body onload="fokus()">
-
<form method="post" action="ct.pl" name="Form">
<input type="hidden" name="db" value="[% db | html %]">
<input type="submit" class="submit" name="action" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-<body>
<form method=post action='[% script %]'>
<input type=submit class=submit name=action value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
<html>
-<body>
Export in Bearbeitung<br>
<br>
%]
[% END %]
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-<body>
<form method=post action="[% script %]">
<input type=submit class=submit name=action value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-<body>
<form method=post action="[% script %]">
<table width=100%>
<input type=submit class=submit name=action value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
<p><input type="submit" value="[% 'Continue' | $T8 %]"></p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<table width="100%">
<tr>
[% USE HTML %][% USE T8 %][% USE L %][% USE LxERP %]
[% SET is_used = SELF.department.is_used %]
-<body>
<form method="post" action="controller.pl">
<div class="listtop">[% FORM.title %]</div>
<a href="[% SELF.url_for(action => 'list') %]">[%- 'Abort' | $T8 %]</a>
</p>
</form>
-</body>
-</html>
[% USE HTML %][% USE T8 %][% USE L %][% USE LxERP %]
-<body>
<div class="listtop">[% FORM.title %]</div>
[%- INCLUDE 'common/flash.html' %]
<a href="[% SELF.url_for(action => 'new') %]">[%- 'Create new department' | $T8 %]</a>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %][% USE LxERP %]<body>
+[%- USE HTML %][%- USE LxERP %]
<div class="listtop">[% 'Delete delivery order' | $T8 %]</div>
<input name="action" class="submit" type="submit" value="[% 'No' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %][% USE LxERP %]<!-- <body> -->
-<!-- <form> -->
-<!-- <p> -->
-<!-- <table> -->
-
+[% USE HTML %][% USE LxERP %]
[%- IF delivered %]
[%- SET RO = ' readonly' %]
[%- END %]
}
}
</script>
-</body>
-</html>
[%- USE HTML %]
[%- USE LxERP %]
[%- USE L %]
-<body onload="on_load()">
-
<script type="text/javascript" src="js/show_form_details.js"></script>
<script type="text/javascript" src="js/show_history.js"></script>
<script type="text/javascript" src="js/show_vc_details.js"></script>
<script type="text/javascript" src="js/stock_in_out.js"></script>
<script type="text/javascript" src="js/follow_up.js"></script>
- <script type="text/javascript">
- <!--
- function on_load() {
- [% IF onload %][% onload %];[% END %]
- setupDateFormat('[% myconfig_dateformat %]', '[% 'Falsches Datumsformat!' | $T8 %]');
- setupPoints('[% myconfig_numberformat %]', '[% 'wrongformat' | $T8 %]');
- }
- -->
- </script>
-
<style type="text/css">
.fixed_width {
width: 250px;
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %][% USE LxERP %]<body onload="on_load();">
-
+[%- USE HTML %][%- USE LxERP %]
[%- IF vc == 'customer' %]
[%- SET is_customer = '1' %]
[%- ELSE %]
[%- END %]
<script type="text/javascript">
- <!--
- function on_load() {
- document.Form.donumber.focus();
- }
- -->
+ $(function(){ document.Form.donumber.focus(); });
</script>
<style type="text/css">
<input class="submit" type="submit" name="action" value="[% 'Continue' | $T8 %]">
</p>
</form>
-
-</body>
-</html>
[% USE HTML %]
[% USE L %]
[% L.javascript_tag('jquery') %]
-<body onload="on_load();">
-
<script type="text/javascript">
<!--
- function on_load() {
+ $(function(){
var row = $('#row').attr('value');
window.opener.document.getElementsByName("stock_" + $('#in_out').attr('value') + "_" + row)[0].value = $('#stock').attr('value');
$(window.opener.document.getElementById("stock_in_out_qty_display_" + row)).html($('#qty_display').attr('value'));
$(window.opener.document.getElementById("stock_in_out_qty_matches_" + row)).val([% qty_matches %]);
window.close();
- }
+ });
-->
</script>
<input type="hidden" name="qty_display" id="qty_display" value="[% HTML.escape(qty_display) %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %][% USE LxERP %][% USE JavaScript %]<body[% UNLESS delivered %] onload="on_load();"[% END %]>
-
+[%- USE HTML %][%- USE LxERP %][%- USE JavaScript %]
[%- UNLESS delivered %]
<script type="text/javascript">
<!--
control.options[initial_bin_index].selected = true;
}
- function on_load() {
+ $(function(){
[%- USE STOCK_INFO_it = Iterator(STOCK_INFO) %][%- FOREACH si = STOCK_INFO_it %]
// new si for wh [% si.warehouse_id %] bin [% si.bin_id %]
[%- SET warehouse_selected = '0' %]
warehouse_selected([% STOCK_INFO_it.count %], 0);
[%- END %]
[%- END %]
- }
+ });
-->
</script>
[%- END %]
[%- END %]
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %][% USE LxERP %]<body>
+[%- USE HTML %][%- USE LxERP %]
[%- IF delivered %]
[%- SET RO = ' readonly' %]
[%- END %]
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<form action="[% HTML.escape(script) %]" method="post">
</table>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<form action="[% HTML.escape(script) %]" method="post">
</table>
</form>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]<script type="text/javascript" src="js/common.js"></script>
-<script type="text/javascript">
- <!--
- function setup_controls() {
- fokus();
- setupDateFormat('[% myconfig_dateformat %]', '[% 'Wrong date format!' | $T8 %]');
- setupPoints('[% myconfig_numberformat %]', '[% 'wrongformat' | $T8 %]');
- }
- -->
-</script>
-
-<body onLoad="setup_controls();">
-
<div class="listtop">[% title %]</div>
<form method="post" name="search" action="dn.pl">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/dunning.js"></script>
<input class="submit" type="submit" name="action" value="[% 'Save' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE L %]
-<body onLoad="[% onload %]">
-
<script type="text/javascript" src="js/common.js"></script>
<form method="post" name="search" action="dn.pl">
<th align="right">[% 'Customer' | $T8 %]</th>
<td colspan="3">
[% IF SHOW_CUSTOMER_DDBOX %]
- <select name="customer_id">
+ <select id='customer' name="customer_id">
<option value=""></option>
[% FOREACH row = ALL_CUSTOMERS %]<option value="[% HTML.escape(row.id) %]">[% HTML.escape(row.name) %]</option>
[% END %]
</select>
[% ELSE %]
- <input name="customer" size="35">
+ <input id='customer' name="customer" size="35">
[% END %]
</td>
</tr>
<input class="submit" type="submit" name="action" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="[% onload %]">
-
+[%- USE HTML %]
<script type="text/javascript">
<!--
function email_updated() {
<button type="button" onclick="email_updated()">[% 'Save and close' | $T8 %]</button>
</form>
-</body>
-</html>
[% USE HTML %] <input type="hidden" name="rowcount" value="[% rowcount %]">
<p>
- <input type="checkbox" name="force_lang" size="6" value="1" onclick="document.getElementsByName('language_id')[0].disabled = !document.getElementsByName('force_lang')[0].checked;">
+ <input type="checkbox" id='force_lang' name="force_lang" size="6" value="1">
[% 'Override invoice language' | $T8 %]
[% PRINT_OPTIONS %]
</p>
</p>
</form>
+ <script type='text/javascript'>
+ $(function(){$("select[name='language_id']").attr('disabled', $('#force_lang').attr('checked') ? '' : 'disabled')})
+ $('#force_lang').click(function(){ $('select[name="language_id"]').attr('disabled', $('#force_lang').attr('checked') ? '' : 'disabled') })
+ </script>
[% L.javascript_tag('jquery.checkall') %]
[% SET all_active = 1 %][% FOREACH row = DUNNINGS %][% IF !row.active %][% SET all_active = 0 %][% LAST %][% END %][% END %]
[% SET all_email = 1 %][% FOREACH row = DUNNINGS %][% IF !row.email %][% SET all_email = 0 %][% LAST %][% END %][% END %]
-<body [% IF onload %] onload="[% onload %]"[% END %]>
-
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/dunning.js"></script>
<hr size=3 noshade>
- <input type="checkbox" name="force_lang" size="6" value="1" onclick="document.getElementsByName('language_id')[0].disabled = !document.getElementsByName('force_lang')[0].checked;">
+ <input type="checkbox" id='force_lang' name="force_lang" size="6" value="1">
[% 'Override invoice language' | $T8 %]
[% PRINT_OPTIONS %]
[% UNLESS DEBUG_DUNNING %]onclick="this.disabled=true; this.value='[% 'The dunning process started' | $T8 %]'; document.Form.submit()"[% END %]>
</form>
-</body>
-</html>
+ <script type='text/javascript'>
+ $(function(){$("select[name='language_id']").attr('disabled', $('#force_lang').attr('checked') ? '' : 'disabled')})
+ $('#force_lang').click(function(){ $('select[name="language_id"]').attr('disabled', $('#force_lang').attr('checked') ? '' : 'disabled') })
+ </script>
+
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %]<body onload="on_load();">
-
+[%- USE HTML %]
<script type="text/javascript">
- <!--
- function on_load() {
- document.Form.subject.focus();
- }
- -->
+ $(function(){ document.Form.subject.focus(); });
</script>
<form action="fu.pl" method="post" name="Form">
<input type="hidden" name="trans_rowcount" value="[% LINKS.size %]">
</form>
-</body>
-</html>
-<body onload="window.close()"></body></html>
+<script type='text/javascript'>$(function(){ window.close() })</script>
[%- USE T8 %]
[% USE HTML %]
-<body>
[%- IF SAVED_MESSAGE %]
<p>[% SAVED_MESSAGE %]</p>
</p>
</form>
-</body>
-</html>
<input type="hidden" name="callback" value="[% HTML.escape(callback) %]">
<input type="hidden" name="rowcount" value="[% FOLLOW_UPS.size %]">
- <p>
<table width="100%">
<tr>
<td class="listheading"> </td>
</td>
<td>[% HTML.escape(row.follow_up_date) %]</td>
<td>[% HTML.escape(row.created_on) %]</td>
- <td><a href="[% edit_url %][% HTML.escape(row.id) %]">[% HTML.escape(row.subject) %]</a></td>
- <td>[% IF row.reference_link %]<a href="[% row.reference_link %]">[% END %][% HTML.escape(row.reference) %][% IF row.reference_link %]</a>[% END %]</td>
+ <td><a href="[% edit_url | html %][% HTML.escape(row.id) %]">[% HTML.escape(row.subject) %]</a></td>
+ <td>[% IF row.reference_link %]<a href="[% row.reference_link | html %]">[% END %][% HTML.escape(row.reference) %][% IF row.reference_link %]</a>[% END %]</td>
<td>[% HTML.escape(row.created_by_name) %]</td>
</tr>
[%- END %]
</table>
- </p>
<p>
<input type="hidden" name="action" value="dispatcher">
[%- USE T8 %]
[%- USE L %]
[% USE HTML %]
-<body onload="on_load()">
-
<script type="text/javascript">
- <!--
- function on_load() {
- document.Form.subject.focus();
- }
- -->
+ $(function(){ document.Form.subject.focus(); });
</script>
<div class="listtop">[% title %]</div>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="[% onload %]">
-
+[%- USE HTML %]
<form name="Form">
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
}
</script>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
-<body[% IF onload %] onload="[% onload %]"[% END %]>
-
<form method="post">
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
//-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="fokus()">
-
+[%- USE HTML %]
<form name="Form" method="post" action="[% script %]">
<table width="100%">
<input name="action" class="submit" type="submit" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="message_error">[% IF title_error %][% title_error %][% ELSE %][% 'Error!' | $T8 %][% END %]
<p class="message_error_label">[% label_error %]</p>
[%- END %]
-</body>
-</html>
-[%- USE LxERP %][% USE HTML %]<body>
+[%-- USE LxERP %][%- USE HTML %]
<h1 class="message_error">[%- LxERP.t8('Error!') %]</h1>
</table>
</div>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
- <table width="100%">
- <tr>
- <th class="message_ok">[% IF title_information %][% title_information %][% ELSE %][% 'Information' | $T8 %][% END %]</th>
- </tr>
- <tr height="5"></tr>
+<div class="message_ok">[% IF title_information %][% title_information %][% ELSE %][% 'Information' | $T8 %][% END %]</div>
+<p>[% label_information %]</p>
- <tr><td>[% label_information %]</td></tr>
- </table>
-
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %] <body>
+[%- USE HTML %]
<h4 class="error">[% 'Item not on file!' | $T8 %]
<input class="submit" type="submit" name="action_back_to_record" value="[% 'Back' | $T8 %]">
</form>
- </body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body [% IF onload %]onload="[% onload %]"[% END %]>
-
+[%- USE HTML %]
<form action="[% HTML.escape(script) %]" method="post" name="Form">
<input type="hidden" name="input_partnumber" value="[% HTML.escape(input_partnumber) %]">
//-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="[% onload %]">
-
+[%- USE HTML %]
<form name="Form">
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
//-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body [% IF onload %]onload="[% onload %]"[% END %]>
-
+[%- USE HTML %]
<form method="post" action="[% HTML.escape(script) %]">
<input type="hidden" name="nextsub" value="[% HTML.escape(nextsub) %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="[% onload %]">
-
+[%- USE HTML %]
<form name="Form">
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
//-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="[% onload %]">
-
+[%- USE HTML %]
<form name="Form">
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
-->
</script>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<p>
<div class="listtop">[% HTML.escape(title) %]</div>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<p>
<div class="listtop">[% HTML.escape(title) %]</div>
</form>
-</body>
-</html>
</form>
-</body>
-</html>
[%- USE LxERP %]
[%- USE T8 %]
[%- USE L %]
-<body onLoad="focus()">
-
<script type="text/javascript">
<!--
function setTaxkey(row) {
[%- USE HTML %]
[%- USE LxERP %]
[%- USE L %]
-<body onLoad="[% onload %]">
-
<form method=post action=gl.pl>
<input type=hidden name=sort value=datesort>
<input class=submit type=submit name=action value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE LxERP %]
-<body>
<form method="post" action="ic.pl">
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE LxERP %]
-<body>
<form method="post" action="ic.pl">
<input type="button" class="submit" onclick="history.back()" value="[% 'Back' | $T8 %]">
</p>
</form>
-</body>
-</html>
-->
</script>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE LxERP %]
-<body onLoad="fokus()">
-
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/parts_language_selection.js"></script>
[%- USE T8 %]
-[% USE HTML %]<body onload="[% onload %]">
-
+[%- USE HTML %]
<form name="Form">
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
//-->
</script>
-</body>
-</html>
[%- USE HTML %]
[%- USE LxERP %]
[%- USE L %]
-<body>
<form method="post" action="ic.pl">
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE LxERP %]
-<body>
<form method="post" action="ic.pl">
</p>
</form>
-</body>
-</html>
[% USE LxERP %][% USE HTML %][% USE L %]
-<body>
<div class="listtop">[% title %]</div>
[% L.submit_tag('action', LxERP.t8('Continue')) %]
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<form method="post" action="[% HTML.escape(script) %]">
[% L.submit_tag("__dummy", LxERP.t8("Continue")) %]
</form>
-</body>
-</html>
</form>
-</body>
-</html>
[%- USE LxERP %]
[%- USE L %]
[%- SET follow_up_trans_info = invnumber _ ' (' _ vendor_name _ ')' %]
-<body>
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/vendor_selection.js"></script>
<script type="text/javascript" src="js/calculate_qty.js"></script>
[% IF creditwarning != '' %]
alert('[% 'Credit Limit exceeded!!!' | $T8 %]');
[% ELSE %]
- focus();
[% END %]
- setupDateFormat('[% dateformat %]', '[% 'Falsches Datumsformat!' | $T8 %]');
- setupPoints('[% numberformat %]', '[% 'wrongformat' | $T8 %]');
});
function set_duedate() {
$.ajax({
<input type="hidden" name="gldate" value="[% gldate %]">
</form>
-</body>
-</html>
[%- USE LxERP %]
[%- USE L %]
[%- SET follow_up_trans_info = invnumber _ ' (' _ customer_name _ ')' %]
-<body>
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/delivery_customer_selection.js"></script>
<script type="text/javascript" src="js/vendor_selection.js"></script>
[% ELSIF creditwarning != '' %]
alert('[% 'Credit Limit exceeded!!!' | $T8 %]');
[% ELSE %]
- focus();
[% END %]
- setupDateFormat('[% dateformat %]', '[% 'Falsches Datumsformat!' | $T8 %]');
- setupPoints('[% numberformat %]', '[% 'wrongformat' | $T8 %]');
});
function set_duedate() {
$.ajax({
--- /dev/null
+function fokus(){ [% IF focus %]$('[% focus %]').focus()[% ELSE %][% fokus %].focus()[% END %] }
--- /dev/null
+[%- USE T8 %]
+$(function() {
+ setupPoints('[% myconfig.numberformat %]', '[% 'wrongformat' | $T8 %]');
+ setupDateFormat('[% myconfig.dateformat %]', '[% 'Falsches Datumsformat!' | $T8 %]');
+})
[%- USE T8 %]
-[% USE HTML %][% USE LxERP %]<body>
+[%- USE HTML %][%- USE LxERP %]
[%- DEFAULT myconfig_dbhost = 'localhost' %]
<noscript>
[% INCLUDE 'generic/information.html'
%]
</noscript>
<center>
- <a class="nomobile" href="http://www.kivitendo.de" target="_top"><img src="image/kivitendo.png" border="0" title="[% 'kivitendo Homepage' | $T8 %]"></a>
+ <a class="nomobile" href="http://www.kivitendo.de" target="_top"><img src="image/kivitendo.png" border="0" alt='[% 'kivitendo' | $T8 %]' title="[% 'kivitendo Homepage' | $T8 %]"></a>
<h3 class="login">[% 'kivitendo' | $T8 %] [% version %]</h3>
[%- todo_list %]
-</body>
-</html>
[%- USE LxERP %]
-<body>
<p><b>[% LxERP.t8('Error!') %]</b></p>
<a href="admin.pl" target="_top">[% LxERP.t8('Administration') %]</a>
</p>
-</body>
-</html>
[%- USE T8 %]
-<body>
<p><b>[% 'Error!' | $T8 %]</b></p>
<a href="admin.pl" target="_top">[% 'Administration' | $T8 %]</a>
</p>
-</body>
-</html>
[% USE LxERP %][% USE HTML %]
-<body>
<div class="listtop">[% title %]</div>
<p>
<p>
<a href="controller.pl?action=LoginScreen/user_login">[%- LxERP.t8('Back to login') %]</a>
</p>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body class="login" onLoad="document.loginscreen.login.focus()">
-
+[%- USE HTML %]
<center>
<table class="login" border="3" cellpadding="20">
<tr>
<table>
<tr>
<th align="right">[% 'Login Name' | $T8 %]</th>
- <td><input class="login" name="{AUTH}login" size="30" tabindex="1"></td>
+ <td><input id='login' class="login" name="{AUTH}login" size="30" tabindex="1"></td>
</tr>
<tr>
<th align="right">[% 'Password' | $T8 %]</th>
</td>
</tr>
</table>
-
-</body>
-</html>
+ <script type='text/javascript'>
+ $(function(){ $('#login').focus() })
+ </script>
[%- USE T8 %]
-<body class="frame-header">
-<div class="frame-header">
+<div id="frame-header">
[% UNLESS is_links %]
<span class="frame-header-element frame-header-left">
[<a href="JavaScript:Switch_Menu();" title="[% 'Switch Menu on / off' | $T8 %]">[% 'Menu' | $T8 %]</a>]
<span class="frame-header-element frame-header-center">
Debug:
[<a href='controller.pl?action=DebugMenu/reload'>FCGI Reload</a>]
- [<a href='controller.pl?action=DebugMenu/toggle&level=request_timer'>[% IF LXDEBUG.level_by_name('request_timer') %]<b>Timing</b>[% ELSE %]Timing[% END %]</a>]
- [<a href='controller.pl?action=DebugMenu/toggle&level=trace'>[% IF LXDEBUG.level_by_name('trace') %]<b>Trace</b>[% ELSE %]Trace[% END %]</a>]
- [<a href='controller.pl?action=DebugMenu/toggle&level=query'>[% IF LXDEBUG.level_by_name('query') %]<b>Query</b>[% ELSE %]Query[% END %]</a>]
- [<a href='controller.pl?action=DebugMenu/toggle&level=warn'>[% IF LXDEBUG.level_by_name('warn') %]<b>Warnings</b>[% ELSE %]Warnings[% END %]</a>]
+ [<a href='controller.pl?action=DebugMenu/toggle&level=request_timer'>[% IF LXDEBUG.level_by_name('request_timer') %]<b>Timing</b>[% ELSE %]Timing[% END %]</a>]
+ [<a href='controller.pl?action=DebugMenu/toggle&level=trace'>[% IF LXDEBUG.level_by_name('trace') %]<b>Trace</b>[% ELSE %]Trace[% END %]</a>]
+ [<a href='controller.pl?action=DebugMenu/toggle&level=query'>[% IF LXDEBUG.level_by_name('query') %]<b>Query</b>[% ELSE %]Query[% END %]</a>]
+ [<a href='controller.pl?action=DebugMenu/toggle&level=warn'>[% IF LXDEBUG.level_by_name('warn') %]<b>Warnings</b>[% ELSE %]Warnings[% END %]</a>]
</span>
[%- END %]
<span class="frame-header-element frame-header-right">
[% now.hms %]
</span>
</div>
-</body>
-</html>
--- /dev/null
+[%- USE JSON %]
+$(function(){$([% JSON.json(sections) %]).each(function(i,b){var a=$('<a class="ml">').append($('<span class="mii ms">').append($('<div>').addClass(b[3])),$('<span class="mic">').append(b[0]));if(b[5])a.attr('href', b[5]);$('#html-menu').append($('<div class="mi">').addClass(b[4]).addClass(b[1]).attr('id','mi'+b[2]).append(a))});$('#html-menu div.i, #html-menu div.sm').not('[id^='+$.cookie('html-menu-selection')+'_]').hide();$('#html-menu div.m').each(function(){$(this).click(function(){$.cookie('html-menu-selection',$(this).attr('id'));$('#html-menu div.mi').not('div.m').not('[id^='+$(this).attr('id')+'_]').hide();$('#html-menu div.mi[id^='+$(this).attr('id')+'_]').toggle()})})})
[%- USE T8 %]
-[% USE HTML %]<body class="menunew">
-
+[% USE HTML %]
<script type="text/javascript">
<!--
function clockon() {
document.getElementById('clock_id').innerHTML = (h<10?'0'+h:h)+":"+(m<10?'0'+m:m);
var timer=setTimeout("clockon()", 10000);
}
-window.onload=clockon
+$(clockon);
//-->
</script>
[<a href="JavaScript:top.main_window.print()">[% 'print' | $T8 %]</a>]
</td>
<td align="right" nowrap>
- [[% 'User' | $T8 %]: [% HTML.escape(login) %] -
+ [[% 'User' | $T8 %]: [% HTML.escape(MYCONFIG.login) %] -
<a href="controller.pl?action=LoginScreen/logout" target="_top">[% 'logout' | $T8 %]</a>]
[% date %] <span id='clock_id' style='position:relative'></span>
</td>
<div id="main_menu_div"></div>
[%- SET main_id = '100' %]
- <ul id="main_menu_model">
+ <ul id="main_menu_model" style='display:none'>
[%- FOREACH mainitem = menu_items %]
[%- SET main_id = main_id + 1 %]
<li id="[% main_id %]"[% IF mainitem.image %] itemIcon="[% mainitem.image %]"[% END %]>
- <a href="[% IF mainitem.href %][% mainitem.href %][% ELSE %]#[% END %]"[% IF mainitem.target %] target="[% mainitem.target %]"[% END %]>
+ <a href="[% IF mainitem.href %][% mainitem.href %][% ELSE %]#[% END %]">
[%- HTML.escape(mainitem.title) %]
</a>
[%- IF mainitem.subitems %]
[%- FOREACH sub1item = mainitem.subitems %]
[%- SET sub1_id = sub1_id + 1 %]
<li id="[% sub1_id %]"[% IF sub1item.image %] itemIcon="[% sub1item.image %]"[% END %]>
- <a href="[% IF sub1item.href %][% sub1item.href %][% ELSE %]#[% END %]"[% IF sub1item.target %] target="[% sub1item.target %]"[% END %]>
+ <a href="[% IF sub1item.href %][% sub1item.href %][% ELSE %]#[% END %]">
[%- HTML.escape(sub1item.title) %]
</a>
[%- IF sub1item.subitems %]
[%- FOREACH sub2item = sub1item.subitems %]
[%- SET sub2_id = sub2_id + 1 %]
<li id="[% sub2_id %]"[% IF sub2item.image %] itemIcon="[% sub2item.image %]"[% END %]>
- <a href="[% IF sub2item.href %][% sub2item.href %][% ELSE %]#[% END %]"[% IF sub2item.target %] target="[% sub2item.target %]"[% END %]>
+ <a href="[% IF sub2item.href %][% sub2item.href %][% ELSE %]#[% END %]">
[%- HTML.escape(sub2item.title) %]
</a>
</li>
[%- END %]
</ul>
- <iframe id="win1" src="[% callback %]" width="100%" height="94%" name="main_window" style="position: absolute; border: 0px; z-index: 99; ">
- <p>[% 'MSG_BROWSER_DOES_NOT_SUPPORT_IFRAMES' | $T8 %]</p>
- </iframe>
<script type="text/javascript">
<!--
-DHTMLSuite.createStandardObjects();
+$(function(){
+ DHTMLSuite.createStandardObjects();
+
+ DHTMLSuite.configObj.setImagePath('image/dhtmlsuite/');
-DHTMLSuite.configObj.setCssPath('[% myconfig.css_path %]/dhtmlsuite/');
-DHTMLSuite.configObj.setImagePath('image/dhtmlsuite/');
+ var menu_model = new DHTMLSuite.menuModel();
+ menu_model.addItemsFromMarkup('main_menu_model');
+ menu_model.init();
+
+ var menu_bar = new DHTMLSuite.menuBar();
+ menu_bar.addMenuItems(menu_model);
+ menu_bar.setTarget('main_menu_div');
+ menu_bar.init();
+});
-var menu_model = new DHTMLSuite.menuModel();
-menu_model.addItemsFromMarkup('main_menu_model');
-menu_model.init();
-var menu_bar = new DHTMLSuite.menuBar();
-menu_bar.addMenuItems(menu_model);
-menu_bar.setTarget('main_menu_div');
-menu_bar.init();
function open_url(url, target) {
-->
</script>
-
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body style="padding:0px; margin:0px;">
-
+[% USE HTML %]
<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript">
<!--
document.getElementById('clock_id').innerHTML = (h<10?'0'+h:h)+":"+(m<10?'0'+m:m);
var timer=setTimeout("clockon()", 10000);
}
-window.onload=clockon
+$(clockon);
//-->
</script>
</tr>
</table>
-
<div id="menuv3">
[% menu %]
</div>
-
<div style="clear: both;"></div>
-
- <iframe id="win1" src="[% callback %]" width="100%" height="94%" name="main_window" style="position: absolute; border: 0px; z-index: 99; ">
- <p>[% 'MSG_BROWSER_DOES_NOT_SUPPORT_IFRAMES' | $T8 %]</p>
- </iframe>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
-<body class="frame-header menuv4">
- <div class="frame-header">
- <span class="frame-header-element frame-header-left">
- [<a href="menuv4.pl?action=display" target="_blank">[% 'new Window' | $T8 %]</a>]
- [<a href="JavaScript:top.main_window.print()">[% 'print' | $T8 %]</a>]
- </span>
- <span class="frame-header-element frame-header-right">
- [[% 'User' | $T8 %]: [% HTML.escape(login) %] -
- <a href="controller.pl?action=LoginScreen/logout" target="_top">[% 'logout' | $T8 %]</a>]
- [% date %] <span id='clock_id' style='position:relative'></span>
- </span>
- </div>
<div id="menuv4">
[% menu %]
</div>
<div style="clear: both;"></div>
- <iframe id="win1" src="[% callback %]" width="100%" height="94%" name="main_window" style="position: absolute; border: 0px; z-index: 99; ">
- <p>[% 'MSG_BROWSER_DOES_NOT_SUPPORT_IFRAMES' | $T8 %]</p>
- </iframe>
-</body>
-
<script type="text/javascript">
<!--
document.getElementById('clock_id').innerHTML = (h<10?'0'+h:h)+":"+(m<10?'0'+m:m);
var timer=setTimeout("clockon()", 10000);
}
-window.onload=clockon
+$(clockon);
//-->
</script>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop" width="100%">[% 'Carry over shipping address' | $T8 %]</div>
</form>
-</body>
-</html>
[%- USE L %]
[%- USE LxERP %]
-<body>
<form method="post" action="[% script %]">
<button class=submit type=button onclick="history.back()">[% 'No' | $T8 %]</button>
</form>
-</body>
-</html>
[% USE HTML %]
[% USE LxERP %]
[% USE L %]
-<body>
<div class="listtop">[% title %]</div>
-->
</script>
-</body>
-</html>
[% END %]
</form>
-
-
- <script type="text/javascript">
- <!--
- $('document').ready(function(){
- setupDateFormat('[% dateformat %]', '[% 'Falsches Datumsformat!' | $T8 %]');
- setupPoints('[% numberformat %]', '[% 'wrongformat' | $T8 %]');
- });
- //-->
- </script>
-</body>
-</html>
[%- USE HTML %]
[%- USE LxERP %]
[%- USE L %]
-<body onLoad="[% onload %]">
<form method="post" name="oe" action="[% script %]">
<div class="listtop">[% 'Overdue sales quotations and requests for quotations' | $T8 %]</div>
-<p>
<table width="100%">
<tr>
<td class="listheading">[% 'Date' | $T8 %]</td>
<td>[% HTML.escape(row.transdate) %]</td>
<td>[% HTML.escape(row.reqdate) %]</td>
<td>
- <a href="[% edit_url %]&vc=[% HTML.url(row.vc) %]&type=[% IF row.vc == 'customer' %]sales_quotation[% ELSE %]request_quotation[% END %]&id=[% HTML.url(row.id) %]">
+ <a href="[% edit_url | html %]&vc=[% row.vc | html %]&type=[% IF row.vc == 'customer' %]sales_quotation[% ELSE %]request_quotation[% END %]&id=[% row.id | html %]">
[% IF row.vc == 'customer' %]
[% 'Sales quotation' | $T8 %]
[% ELSE %]
</tr>
[%- END %]
</table>
-</p>
[% USE LxERP %]
[% USE T8 %]
[%- IF !TABDIALOG %]
-<body>
<p><div class="listtop">[% 'Price information' | $T8 %]</div></p>
</p>
[%- IF !TABDIALOG %]
-</body>
-</html>
[%- END %]
[% USE HTML %]
[% USE L %]
-<body onload="copy_values_and_close()">
-
<script type="text/javascript">
<!--
- function copy_values_and_close() {
+ $(function() {
window.opener.document.getElementsByName("periodic_invoices_config")[0].value = $("#periodic_invoices_config").attr('value');
window.close();
- }
+ })
-->
</script>
[% L.hidden_tag("periodic_invoices_config", periodic_invoices_config) %]
</form>
-</body>
-</html>
[%- USE L %]
[%- SET vclabel = vc == 'customer' ? LxERP.t8('Customer') : LxERP.t8('Vendor') %]
[%- SET vcnumberlabel = vc == 'customer' ? LxERP.t8('Customer Number') : LxERP.t8('Vendor Number') %]
-<body>
<form method="post" action="oe.pl">
<input class="submit" type="submit" name="action" value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[% USE HTML %][% USE T8 %][% USE L %][% USE LxERP %]
-<body>
<form method="post" action="controller.pl">
<div class="listtop">[% FORM.title %]</div>
</table>
</form>
-</body>
-</html>
<script type="text/javascript" src="js/jquery-ui.js"></script>
-<body>
<div class="listtop">[% FORM.title %]</div>
[%- INCLUDE 'common/flash.html' %]
[% L.sortable_element('#payment_term_list tbody', url => 'controller.pl?action=PaymentTerm/reorder', with => 'payment_term_id') %]
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[% L.javascript_tag('show_history.js') %]
-<body>
<form method=post action="[% script %]">
<input type=button onclick="set_history_window([% id %]);" name=history id=history value="[% 'history' | $T8 %]">
</form>
-</body>
-</html>
[%- USE HTML %]
[%- USE T8 %]
-<body>
<table width=100%>
<tr>
<input class=submit type=submit name=action value="[% 'Add' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[% L.javascript_tag('show_history.js') %]
-<body>
<form method=post action="[% script %]">
<input type=button onclick="set_history_window([% id %]);" name=history id=history value="[% 'history' | $T8 %]">
</form>
-</body>
-</html>
[%- USE HTML %]
[%- USE T8 %]
-<body>
<table width=100%>
<tr>
<input class=submit type=submit name=action value="[% 'Add' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE LxERP %]
-<body>
<form method=post action="[% script %]">
<input class=submit type=submit name=action value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %][% USE LxERP %]<body>
+[%- USE HTML %][%- USE LxERP %]
[%- IF message %]
<p>[% message %]</p>
</script>
[% PROCESS 'common/help_overlay.html' %]
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body onload="fokus()">
-
+[%- USE HTML %]
<form method="post" action="projects.pl" name="Form">
<div class="listtop">[% title %]</div>
</p>
</form>
-</body>
-</html>
[%- USE HTML %]
[%- USE L %]
[%- USE LxERP %]
-<body onLoad="[% onload %]">
-
<h1>[% 'Reconciliation' | $T8 %]</h1>
<form method=post action="[% script %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE LxERP %]
[%- L.javascript_tag('jquery.checkall') %]
-<body>
<h1>[% accno | html %]--[% account | html %]</h1>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<h1>[% HTML.escape(title) %]</h1>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body[% IF onload %] onload="[% onload %]"[% END %]>
-
+[%- USE HTML %]
<style type="text/css">
<!--
.top_border {
</form>
[% END %]
-</body>
[%- USE T8 %]
-[% USE HTML %][% USE LxERP %]<body>
+[%- USE HTML %][%- USE LxERP %]
[%- SET default_margin = LxERP.format_amount(1.5) %]
[%- END %]
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE LxERP %]
-<body bgcolor="#ffffff">
-
<h2 align="center">
[% company %]
<br>[% address %]
[%- USE L %]
[%- USE LxERP %]
[%- USE T8 %]
-<body>
<h1>[% 'E-mail Statement to' | $T8 %] [% $ct %]</h1>
<input name=action class=submit type=submit value="[% 'Continue' | $T8 %]">
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<script type="text/javascript">
<!--
</form>
[% END %]
-</body>
</tr>
[%- END %]
-<body onLoad="[% onload %]">
<h1>[% title %]</h1>
<form method=post action='[% script %]'>
</form>
-</body>
-</html>
</tr>
[% END %]
-<body>
<h1>[% title %] [% SET tax_report__accno_title = accno _ '_description' %][% GET $tax_report__accno_title %]</h1>
[%- END %]
</table>
<hr size=3 noshade>
-</body>
-</html>
[% SET arap = 'ar' %]
[% SET iris = 'is' %]
[%- END %]
-<body>
<p><div class="listtop">[% title %]</div></p>
-->
</script>
-</body>
-</html>
[% SET arap = 'ar' %]
[% SET iris = 'is' %]
[%- END %]
-<body>
[%- IF error_message %]
<p><div class="message_error">[% error_message %]</div></p>
<input type="hidden" name="confirmation" value="1">
</form>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
-<body>
<p><div class="listtop">[% title %]</div></p>
</ul>
</p>
-</body>
-</html>
[% SET arap = 'ar' %]
[% SET iris = 'is' %]
[%- END %]
-<body>
<p><div class="listtop">[% title %]: [% HTML.escape(export.ids.join(', ')) %]</div></p>
<input type="hidden" name="vc" value="[% HTML.escape(vc) %]">
</form>
-</body>
-</html>
[%- USE T8 %]
[% USE HTML %]
-<body>
<p><div class="listtop">[% title %]</div></p>
<input type="hidden" name="vc" value="[%- HTML.escape(vc) %]">
</form>
-</body>
-</html>
[%- USE HTML %]
[%- USE LxERP %]
[%- USE L %]
-<body>
<p><div class="listtop">[% title %]</div></p>
<input type="submit" class="submit" name="action_bank_transfer_list" value="[% 'Continue' | $T8 %]">
</p>
</form>
-</body>
-</html>
[% USE HTML %][% USE L %][% USE LxERP %]
-<body>
<div class="listtop">[% FORM.title %]</div>
|
<a href="[% SELF.url_for(controller => 'BackgroundJobHistory', action => 'list') %]">[%- LxERP.t8('View background job history') %]</a>
</p>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<div class="listtop" style="margin-bottom: 10px">[% 'Your TODO list' | $T8 %]</div>
[%- END %]
-</body>
-</html>
Edit templates/webpages/ustva/config_step1_master.html
and run locale/<cc>/locales.pl -->
-<body>
<form name="verzeichnis" method="post" action="[% HTML.escape(script) %]">
<table width="100%">
<tr>
<input type="hidden" name="[% HTML.escape(var.variable) %]" value="[% HTML.escape(var.value) %]">
[%- END %]
</form>
-</body>
and run locale/<cc>/locales.pl -->
-<body>
<form name="elsterform" method="post" action="[% script %]">
<table width="100%">
<tr>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %]<body>
+[%- USE HTML %]
<h1>[% 'Generic Tax Report' | $T8 %]</h1>
<p>[% 'Taxnumber' | $T8 %]: [% taxnumber %]</p>
</table>
-</html>
-</body>
Edit templates/webpages/ustva/report_master.html
and run locale/<cc>/locales.pl -->
- <body>
<form method="post" action="[% HTML.escape(script) %]">
<input type="hidden" name="title" value="[% HTML.escape(title) %]">
</td>
</tr>
</table>
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-<body>
<form method=post name="search_invoice" action=[% script %]>
<th align="right">[% 'Item mode' | $T8 %]</th>
<td colspan="3" align=left><input name="l_parts" class=checkbox type=checkbox value=Y> ([%'Show items from invoices individually' | $T8 %]) </td>
</tr>
- <tr>
+ <tr>
<th align="right">
[% 'Total sum' | $T8 %]
</th>
<td align=left><input name="l_lastcost_total" class=checkbox type=checkbox value=Y checked>[% 'Purchase price total' | $T8 %]</td>
<td align=left><input name="l_marge_total" class=checkbox type=checkbox value=Y checked>[% 'Margetotal' | $T8 %]</td>
<td colspan="4"> ([% 'Single values in item mode, cumulated values in invoice mode' | $T8 %])
-
+
</tr>
<tr>
<td align=left><input name="l_sellprice" class=checkbox type=checkbox value=Y checked>[% 'Sales price' | $T8 %]</td>
</th>
</tr>
[% CUSTOM_VARIABLES_INCLUSION_CODE_CT %]
-
+
<tr><td colspan="7"> </td></tr>
<tr>
<th colspan="4" align="left">
<!--
$(document).ready(function(){
$('customer').focus();
- setupDateFormat('[% dateformat | html %]','[% 'Falsches Datumsformat!' | $T8 %]');
- setupPoints('[% numberformat | html %]','[% 'wrongformat' | $T8 %]');
})
//-->
</script>
- </body>
-</html>
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %][% USE JavaScript %]<body onload="on_load();">
-
+[%- USE HTML %][%- USE JavaScript %]
<script type="text/javascript">
<!--
warehouses = new Array();
control.options[bin_index].selected = true;
}
- function on_load() {
+ $(function() {
warehouse_selected(0, 0);
document.Form.partnumber.focus();
- }
+ })
-->
</script>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %][% USE JavaScript %]<body>
+[%- USE HTML %][%- USE JavaScript %]
<form method="post" action="wh.pl">
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %][% USE JavaScript %]<body onload="on_load();">
-
+[%- USE HTML %][%- USE JavaScript %]
<script type="text/javascript">
<!--
warehouses = new Array();
control.options[bin_index].selected = true;
}
- function on_load() {
+ $(function () {
warehouse_selected(0, 0);
document.Form.partnumber.focus();
- }
+ });
-->
</script>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
-[% USE HTML %][% USE JavaScript %]<body onload="on_load();">
-
+[%- USE HTML %][%- USE JavaScript %]
<script type="text/javascript">
<!--
warehouses = new Array();
control.options[0].selected = true;
}
- function on_load() {
+ $(function() {
[% FOREACH row = CONTENTS %]
warehouse_selected([% loop.count %], [% initial_warehouse_idx %]);
[% END %]
- }
+ });
-->
</script>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE HTML %]
[%- USE L %]
-[% USE JavaScript %]<body onload="on_load();">
-
+[%- USE JavaScript %]
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/part_selection.js"></script>
<script type="text/javascript">
control.options[bin_index].selected = true;
}
- function on_load() {
+ $(function() {
warehouse_selected(0, 0);
document.Form.partnumber.focus();
- }
+ });
-->
</script>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %][% USE JavaScript %][% USE LxERP %]<body onload="on_load(); [% onload %]">
-
+[%- USE HTML %][%- USE JavaScript %][%- USE LxERP %]
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/part_selection.js"></script>
<script type="text/javascript">
control.options[bin_index].selected = true;
}
- function on_load() {
+ $(function() {
warehouse_selected([% warehouse_id %], [% bin_id %]);
- }
+ })
-->
</script>
</p>
</form>
-</body>
-</html>
[%- USE T8 %]
[%- USE L %]
-[% USE HTML %][% USE JavaScript %][% USE LxERP %]<body onload="on_load(); [% onload %]">
-
+[%- USE HTML %][%- USE JavaScript %][%- USE LxERP %]
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/part_selection.js"></script>
<script type="text/javascript">
control.options[bin_index].selected = true;
}
- function on_load() {
+ $(function() {
warehouse_selected([% warehouse_id %], [% bin_id %]);
- }
+ })
-->
</script>
<input type="submit" class="submit" name="action" value="[% 'Stock' | $T8 %]">
[%- END %]
</p>
- </form>
-
-</body>
-</html>
+ </form>
+