-tags
-crm
-/users/datev-export*
-/users/templates-cache/
-/users/session_files/
-/users/pid/
-/users/.cache/
-/users/kivitendo-print*
-users/.openoffice.org2/
-/config/lx_office.conf
+/config/authentication.pl
+/config/console.conf
/config/kivitendo.conf
-/doc/online/*/*.html
-pod2html*
+/config/lx-erp-local.conf
+/config/lx_office.conf
/doc/build/dobudish*
+/doc/online/*/*.html
+/locale/*/missing
+/locale/*/lost
/spool/*
+/templates/demo*
+/users/*_finanzamt.ini
+/users/.cache/
+/users/.fonts.cache*
+/users/.openoffice.org2/
+/users/.recently-used
+/users/.texmf-var
+/users/console_history
+/users/datev-export*
+/users/kivitendo-print*
+/users/pid/
+/users/session_files/
+/users/templates-cache/
+/users/xvfb_display
/webdav/*
+crm
+pod2html*
+tags
use SL::Helper::DateTime;
use SL::InstanceConfiguration;
use SL::Template::Plugin::HTMLFixes;
+use SL::User;
# Trailing new line is added so that Perl will not add the line
# number 'die' was called in.
$::lxdebug = LXDebug->new;
$::auth = SL::Auth->new;
$::form = undef;
- %::myconfig = ();
$::request = undef;
+ %::myconfig = User->get_default_myconfig;
}
$SIG{__WARN__} = sub {
sub handle {
my ($self, %params) = @_;
- %::myconfig = ();
+ %::myconfig = User->get_default_myconfig;
my $ok = $::auth->is_api_token_cookie_valid;
$ok ||= $::form->{'{AUTH}admin_password'} && ($::auth->authenticate_root($::form->{'{AUTH}admin_password'}) == $::auth->OK());
use parent qw(Rose::Object);
sub handle {
- %::myconfig = ();
+ %::myconfig = User->get_default_myconfig;
return 1;
}
my $client_id = $::form->{'{AUTH}client_id'} || $::auth->get_session_value('client_id');
return $self->_error(%param) if !$client_id || !$::auth->set_client($client_id);
- %::myconfig = $::auth->read_user(login => $login);
+ %::myconfig = User->get_default_myconfig($::auth->read_user(login => $login));
return $self->_error(%param) unless $::myconfig{login};
} else {
$css_path = "$css_path/kivitendo";
}
- $::myconfig{css_path} = $css_path; # needed for menunew, FIXME: don't do this here
return $css_path;
}
+{ %{ $_[0] } }
}
+sub get_default_myconfig {
+ my ($self_or_class, %user_config) = @_;
+
+ return (
+ countrycode => 'de',
+ css_path => 'css', # Needed for menunew, see SL::Layout::Base::get_stylesheet_for_user
+ dateformat => 'dd.mm.yy',
+ numberformat => '1.000,00',
+ stylesheet => 'kivitendo.css',
+ timeformat => 'hh:mm',
+ %user_config,
+ );
+}
+
1;
+++ /dev/null
-lx-erp-local.conf
-authentication.pl
-console.conf
+++ /dev/null
-missing
-lost
+++ /dev/null
-missing
-lost
+++ /dev/null
-.recently-used
-.fonts.cache*
-*_finanzamt.ini
-xvfb_display
-console_history
-.texmf-var
+++ /dev/null
-imagecache
+++ /dev/null
-pspfontcache