From 38902b24ceed494a2936edfe4d72e8c48e15bce0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Sven=20Sch=C3=B6ling?= Date: Fri, 21 Sep 2012 12:58:05 +0200 Subject: [PATCH] login Layout --- SL/Controller/Layout.pm | 2 ++ SL/Controller/Layout/Login.pm | 26 +++++++++++++++++++ SL/Controller/LoginScreen.pm | 5 ++++ css/lx-office-erp/main.css | 10 ++++++- .../webpages/login_screen/user_login.html | 8 +++--- 5 files changed, 46 insertions(+), 5 deletions(-) create mode 100644 SL/Controller/Layout/Login.pm diff --git a/SL/Controller/Layout.pm b/SL/Controller/Layout.pm index d618730b6..82d5da848 100644 --- a/SL/Controller/Layout.pm +++ b/SL/Controller/Layout.pm @@ -5,6 +5,7 @@ use parent qw(SL::Controller::Base); use SL::Menu; use SL::Controller::Layout::Admin; +use SL::Controller::Layout::Login; use SL::Controller::Layout::Classic; use SL::Controller::Layout::V3; use SL::Controller::Layout::V4; @@ -20,6 +21,7 @@ sub new { return SL::Controller::Layout::V4->new if $params{style} eq 'v4'; return SL::Controller::Layout::Javascript->new if $params{style} eq 'neu'; return SL::Controller::Layout::Admin->new if $params{style} eq 'admin'; + return SL::Controller::Layout::Login->new if $params{style} eq 'login'; return SL::Controller::Layout::None->new; } diff --git a/SL/Controller/Layout/Login.pm b/SL/Controller/Layout/Login.pm new file mode 100644 index 000000000..60f6e940a --- /dev/null +++ b/SL/Controller/Layout/Login.pm @@ -0,0 +1,26 @@ +package SL::Controller::Layout::Login; + +use strict; +use parent qw(SL::Controller::Layout::Base); + +sub new { + my ($class, @slurp) = @_; + + my $self = $class->SUPER::new(@slurp); + + $self->add_sub_layouts([ + SL::Controller::Layout::None->new, + ]); + + $self; +} + +sub start_content { + "
\n"; +} + +sub end_content { + "
\n"; +} + +1; diff --git a/SL/Controller/LoginScreen.pm b/SL/Controller/LoginScreen.pm index 9d0e94bc3..e73224bcc 100644 --- a/SL/Controller/LoginScreen.pm +++ b/SL/Controller/LoginScreen.pm @@ -7,6 +7,7 @@ use parent qw(SL::Controller::Base); use SL::Dispatcher::AuthHandler::User; use SL::User; +__PACKAGE__->run_before('set_layout'); # # actions # @@ -116,4 +117,8 @@ sub error_state { }->{$_[0]}; } +sub set_layout { + $::request->{layout} = SL::Controller::Layout->new(style => 'login'); +} + 1; diff --git a/css/lx-office-erp/main.css b/css/lx-office-erp/main.css index 6b08408bf..08b3c6d76 100644 --- a/css/lx-office-erp/main.css +++ b/css/lx-office-erp/main.css @@ -14,12 +14,17 @@ input:focus, textarea:focus, select:focus { background-color: yellow; } +html { + height: 100%; +} + body { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10pt; background-color: white; background-image: url("../../image/fade.png"); background-repeat:repeat-x; color: black; + height: 100%; } td { @@ -51,7 +56,10 @@ th { .login { font-family: Verdana, Arial, Helvetica, sans-serif; } -body.login { +div.login { + min-height: 100%; + height: auto !important; + height: 100%; background: #b8d1f3; color: #A0A0A0; } diff --git a/templates/webpages/login_screen/user_login.html b/templates/webpages/login_screen/user_login.html index 118ba9b32..08776e760 100644 --- a/templates/webpages/login_screen/user_login.html +++ b/templates/webpages/login_screen/user_login.html @@ -1,7 +1,5 @@ [%- USE T8 %] [%- USE HTML %] - -
@@ -25,7 +23,7 @@ - + @@ -46,4 +44,6 @@
[% 'Login Name' | $T8 %]
[% 'Password' | $T8 %]
- + -- 2.20.1