From d3f9657e35c979dae5a5a68eb0a4e5040aa3eda4 Mon Sep 17 00:00:00 2001 From: Catouse Date: Thu, 13 Mar 2014 11:15:18 +0800 Subject: [PATCH] * fixed style of login view. --- lib/front/front.class.php | 12 ++++---- module/user/css/login.css | 46 ++++++++++++----------------- module/user/js/login.js | 25 +++------------- module/user/view/login.html.php | 52 ++++++++++++++------------------- www/js/jquery/lib.js | 12 ++++---- 5 files changed, 57 insertions(+), 90 deletions(-) diff --git a/lib/front/front.class.php b/lib/front/front.class.php index 10ab0455df..34dfa89e55 100644 --- a/lib/front/front.class.php +++ b/lib/front/front.class.php @@ -224,10 +224,10 @@ class html foreach($options as $key => $value) { $key = str_replace('item', '', $key); - $string .= "save; } - return " "; + return " "; } /** @@ -431,7 +431,7 @@ EOT; public static function resetButton() { global $lang; - return " "; + return " "; } /** @@ -445,7 +445,7 @@ EOT; { global $lang; if(isonlybody()) return false; - return ""; + return ""; } /** @@ -459,7 +459,7 @@ EOT; */ public static function commonButton($label = '', $misc = '', $class = '') { - return " "; + return " "; } /** diff --git a/module/user/css/login.css b/module/user/css/login.css index 28c9de635d..0a2182f2af 100644 --- a/module/user/css/login.css +++ b/module/user/css/login.css @@ -1,28 +1,18 @@ -html,body{background-color: #036;} -#container{margin: 10% auto 0 auto;} -#login-panel{margin: 0 auto;width: 540px;min-height: 280px;background-color: #fff;border: 1px solid #dfdfdf;-moz-border-radius:3px; -webkit-border-radius:3px; border-radius:3px;-moz-box-shadow:0px 0px 30px rgba(0,0,0,0.75); -webkit-box-shadow:0px 0px 30px rgba(0,0,0,0.75); box-shadow:0px 0px 30px rgba(0,0,0,0.75);} -#login-panel .panel-head{min-height: 70px;background-color: #edf3fe;border-bottom: 1px solid #dfdfdf;position: relative;} -#login-panel .panel-head h3{margin: 0 0 0 20px;padding: 0;line-height: 70px;} -#login-panel .panel-head .nav{float: right;position: absolute;right: 0;top: 0;padding: 0;} -#login-panel .panel-head .nav .btn{clear: both;display: block;margin: 10px 10px 0 0;position: absolute;top: 6px;right: 6px;border-color: #ccc;} -#login-panel #mobile{height: 28px;} -#login-panel #mobile i{margin: 0;padding: 0;} -#login-panel #lang{right: 60px;padding: 8px;width: auto;word-spacing:nowrap; overflow:visible;min-width: 80px;text-align: center;} -#login-panel .panel-content{padding-left: 150px;background:url('theme/default/images/main/zt-logo.png') 50px top no-repeat;} -#login-panel .panel-content table{border: none;width: 300px;margin: 20px auto;} -#login-panel .panel-content table td{padding: 6px;} -#login-panel .panel-content table td.attr{font-weight: bold;text-align: right;vertical-align: middle;} -#login-panel .panel-content input.text-2{width: 212px;} -#login-panel .panel-content .button-s{width: 80px;} -#login-panel .panel-content .button-c{width: 88px;margin-right: 0;} -#login-panel .panel-foot{text-align: center;padding: 15px;line-height: 2em;background-color: #e5e5e5;border-top: 1px solid #dfdfdf;} -.droppanel{display: none;margin: 0;padding: 4px 0;position: absolute;left: 0;top: 55px;background-color: #fff;-moz-box-shadow:0px 2px 6px rgba(0,0,0,0.5); -webkit-box-shadow:0px 2px 6px rgba(0,0,0,0.5); box-shadow:0px 2px 6px rgba(0,0,0,0.5);z-index: 9999;} -#langs{left: -166px;} -#qrcode{left: -310px;padding: 0;} -#qrcode h4{background-color: #e5e5e5;line-height: 2em;padding:5px 15px;} -.droppanel li{list-style: none;min-width: 120px;font-size: 14px;} -.droppanel li a{display: block;padding: 8px 15px;border-bottom: 1px dashed #eee;} -.droppanel li a:hover{background-color: #e5e5e5;color: #333;} -.droppanel li a.active{background-color: #FAFFBD;} -#poweredby{float: none; color: #eee;text-align: center;margin-top: 30px;} -#poweredby a{color: #fff;} +html,body{background-color: #036} +#container{margin: 10% auto 0 auto} +#login-panel{margin: 0 auto;width: 540px;min-height: 280px;background-color: #fff;border: 1px solid #dfdfdf;-moz-border-radius:3px; -webkit-border-radius:3px; border-radius:3px;-moz-box-shadow:0px 0px 30px rgba(0,0,0,0.75); -webkit-box-shadow:0px 0px 30px rgba(0,0,0,0.75); box-shadow:0px 0px 30px rgba(0,0,0,0.75)} +#login-panel .panel-head{min-height: 70px;background-color: #edf3fe;border-bottom: 1px solid #dfdfdf;position: relative} +#login-panel .panel-head h4{margin: 0 0 0 20px;padding: 0;line-height: 70px} +#login-panel .panel-actions{float: right;position: absolute;right: 15px;top: 18px;padding: 0} +#login-panel .panel-actions .dropdown {display: inline-block; margin-right: 2px} +#mobile {font-size: 28px; padding: 1px 12px; line-height: 28px} +#login-panel .panel-content{padding-left: 150px;background:url('theme/default/images/main/zt-logo.png') 50px top no-repeat; min-height: 161px} +#login-panel .panel-content table{border: none;width: 300px;margin: 20px auto} +#login-panel .panel-content .button-s{width: 80px} +#login-panel .panel-content .button-c{width: 88px;margin-right: 0} +#login-panel .panel-foot{text-align: center;padding: 15px;line-height: 2em;background-color: #e5e5e5;border-top: 1px solid #dfdfdf} +#poweredby{float: none; color: #eee;text-align: center;margin-top: 30px} +#poweredby a{color: #fff} +#keeplogin label {font-weight: normal} +.popover {max-width: 500px} +.popover-content {padding: 0} diff --git a/module/user/js/login.js b/module/user/js/login.js index 0f32200ebe..eb9d45e829 100644 --- a/module/user/js/login.js +++ b/module/user/js/login.js @@ -3,28 +3,11 @@ $(document).ready(function() { $('#account').focus(); - $("#lang").click(function(event) + $("#langs li > a").click(function() { - $("#langs").toggle(); - event.stopPropagation(); + selectLang($(this).data('value')); + console.log($(this).data('value')); }); - $(document).click(function(event) - { - $("#langs").hide(); - $("#qrcode").hide(); - }); - - $("#langs a").click(function() - { - $("#langs a").removeClass('active'); - $(this).addClass("active"); - selectLang($(this).attr("data-value")); - }); - - $("#mobile").click(function(event) { - $("#qrcode").toggle(); - event.stopPropagation(); - return false; - }); + $('#mobile').popover({html: true, container: 'body'}); }) diff --git a/module/user/view/login.html.php b/module/user/view/login.html.php index 5dba1d3eb2..090d8c046b 100644 --- a/module/user/view/login.html.php +++ b/module/user/view/login.html.php @@ -11,47 +11,39 @@ include '../../common/view/header.lite.html.php'; ?> -
-
-
-

welcome, $app->company->name);?>

-