mirror of https://github.com/tp4a/teleport
调整无侧边栏导航页面布局
parent
9a74a0bd28
commit
29200ae84c
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,66 @@
|
|||
"use strict";
|
||||
|
||||
$app.on_init = function (cb_stack) {
|
||||
$app.dom = {
|
||||
title: $('#title'),
|
||||
icon_bg: $('#icon-bg'),
|
||||
|
||||
err_area: $('#error-area'),
|
||||
err_message: $('#err-message'),
|
||||
err_actions: $('#err-actions'),
|
||||
|
||||
find_password_area: $('#find-my-password'),
|
||||
username: $('#username'),
|
||||
email: $('#email'),
|
||||
captcha_image: $('#captcha-image'),
|
||||
captcha: $('#captcha'),
|
||||
btn_send_email: $('#btn-send-email'),
|
||||
send_result:$('#send-result'),
|
||||
|
||||
password_area: $('#password-area')
|
||||
};
|
||||
|
||||
$app.dom.captcha_image.click(function () {
|
||||
$(this).attr('src', '/auth/captcha?h=28&rnd=' + Math.random());
|
||||
$app.dom.captcha.focus().val('');
|
||||
});
|
||||
|
||||
$app.dom.btn_send_email.click(function() {
|
||||
$app.on_send_email();
|
||||
});
|
||||
|
||||
$app.options.mode = 3;
|
||||
|
||||
if ($app.options.mode === 1) {
|
||||
// show 'find-my-password' page
|
||||
$app.dom.title.text('重置密码');
|
||||
$app.dom.icon_bg.addClass('fa fa-search-plus').css('color', '#4366de');
|
||||
$app.dom.captcha_image.attr('src', '/auth/captcha?h=28&rnd=' + Math.random());
|
||||
$app.dom.find_password_area.show();
|
||||
$app.dom.username.focus();
|
||||
} else if ($app.options.mode === 2) {
|
||||
// show 'password-expired' page
|
||||
$app.dom.icon_bg.addClass('fa fa-warning').css('color', '#ff6242');
|
||||
if ($app.options.code === TPE_NOT_EXISTS) {
|
||||
$app.dom.title.text('链接无效');
|
||||
$app.dom.err_message.html('当前使用的密码重置链接无效,可能已经因过期而被清除!密码重置链接仅在24小时内有效,请及时设置您的新密码!');
|
||||
} else if ($app.options.code === TPE_EXPIRED) {
|
||||
$app.dom.title.text('链接已过期');
|
||||
$app.dom.err_message.html('当前使用的密码重置链接已经过期!密码重置链接仅在24小时内有效,请及时设置您的新密码!');
|
||||
} else {
|
||||
$app.dom.title.text('更新密码');
|
||||
}
|
||||
$app.dom.err_area.show();
|
||||
} else if ($app.options.mode === 3) {
|
||||
// show 'set-new-password' page
|
||||
$app.dom.title.text('重置密码');
|
||||
$app.dom.icon_bg.addClass('fa fa-info-circle').css('color', '#357a3c');
|
||||
$app.dom.password_area.show();
|
||||
}
|
||||
|
||||
cb_stack.exec();
|
||||
};
|
||||
|
||||
$app.on_send_email = function() {
|
||||
|
||||
};
|
|
@ -1,100 +0,0 @@
|
|||
@charset "utf-8";
|
||||
|
||||
@import "_color";
|
||||
@import "_base";
|
||||
|
||||
@header-height: 36px;
|
||||
@footer-height: 24px;
|
||||
|
||||
body {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.container {
|
||||
min-width: 460px;
|
||||
}
|
||||
|
||||
#page-header {
|
||||
height: @header-height;
|
||||
margin-bottom: 10px;
|
||||
border: none;
|
||||
background-color: #2a2a2a;
|
||||
color: #fff;
|
||||
.title {
|
||||
line-height: @header-height;
|
||||
font-size: 18px;
|
||||
}
|
||||
.logo {
|
||||
margin-top: 5px;
|
||||
display: inline-block;
|
||||
width: 93px;
|
||||
height: 30px;
|
||||
background: url(../img/site-logo-small.png) no-repeat;
|
||||
}
|
||||
}
|
||||
|
||||
#page-content {
|
||||
margin-bottom: @footer-height+30px;
|
||||
}
|
||||
|
||||
#page-footer {
|
||||
nav.navbar {
|
||||
min-height: @footer-height;
|
||||
height: @footer-height;
|
||||
line-height: @footer-height;
|
||||
//background-color: rgba(0, 0, 0, 0.6);
|
||||
background-color: #cdcdcd;
|
||||
font-size: 12px;
|
||||
color: #6d6d6d;
|
||||
.container {
|
||||
height: @footer-height;
|
||||
}
|
||||
p {
|
||||
margin: 0 auto;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.error-box {
|
||||
@error-icon-size: 164px;
|
||||
width: 100%;
|
||||
padding-left:20px;
|
||||
margin: 30px auto;
|
||||
|
||||
.error-icon-box {
|
||||
z-index: -1;
|
||||
position: absolute;
|
||||
min-height: @error-icon-size+30px;
|
||||
overflow: hidden;
|
||||
.fa {
|
||||
margin-top: 20px;
|
||||
font-size: @error-icon-size;
|
||||
color: rgb(255, 101, 0);
|
||||
}
|
||||
}
|
||||
|
||||
.error-message-box {
|
||||
min-height: @error-icon-size*2;
|
||||
min-width: 300px;
|
||||
border: 1px solid #fff;
|
||||
background-color: rgba(255, 255, 255, 0.76);
|
||||
box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.3);
|
||||
padding: 15px 15px 15px 30px;
|
||||
margin-left: @error-icon-size*0.75;
|
||||
|
||||
.title {
|
||||
font-size: 180%;
|
||||
//font-weight:bold;
|
||||
margin: 15px 0;
|
||||
}
|
||||
|
||||
hr {
|
||||
border-top: 1px solid #d3d3d3;
|
||||
border-bottom: 1px solid #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@import "_overwrite_bootstrap";
|
|
@ -1,186 +0,0 @@
|
|||
@charset "utf-8";
|
||||
|
||||
@import "_color";
|
||||
@import "_base";
|
||||
@import "_overwrite_bootstrap";
|
||||
|
||||
body {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
//overflow: hidden;
|
||||
}
|
||||
|
||||
#page-header {
|
||||
nav.navbar {
|
||||
height: 70px;
|
||||
margin-bottom: 0;
|
||||
border: none;
|
||||
//background-color: rgba(0, 0, 0, 0.6);
|
||||
background-color: #192e4b;
|
||||
color: #fff;
|
||||
}
|
||||
& nav li {
|
||||
display: inline-block;
|
||||
float: left;
|
||||
}
|
||||
}
|
||||
|
||||
#page-content {
|
||||
padding-top: 70px;
|
||||
padding-bottom: 50px;
|
||||
}
|
||||
|
||||
#page-footer {
|
||||
nav.navbar {
|
||||
min-height: 24px;
|
||||
height: 24px;
|
||||
line-height: 24px;
|
||||
background-color: #c1c1c1;
|
||||
border-top: 1px solid #7b7b7b;
|
||||
font-size: 12px;
|
||||
color: #4e4e4e;
|
||||
.container {
|
||||
height: 24px;
|
||||
}
|
||||
p {
|
||||
margin: 0 auto;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.content-box {
|
||||
margin-top: 20px;
|
||||
background-color: #fff;
|
||||
padding: 20px;
|
||||
box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3);
|
||||
|
||||
.welcome-message {
|
||||
@welcome-icon-size: 18px;
|
||||
|
||||
.fa {
|
||||
display: block;
|
||||
color: #ff272a;
|
||||
font-size: @welcome-icon-size;
|
||||
float: left;
|
||||
}
|
||||
span {
|
||||
display: block;
|
||||
line-height: @welcome-icon-size;
|
||||
padding-left: @welcome-icon-size+5;
|
||||
}
|
||||
}
|
||||
|
||||
.table {
|
||||
width: auto;
|
||||
margin-left: 20px;
|
||||
|
||||
td {
|
||||
border-top: 1px dotted #ddd;
|
||||
padding: 5px;
|
||||
&.key {
|
||||
text-align: right;
|
||||
}
|
||||
&.value {
|
||||
text-align: left;
|
||||
font-weight: bold;
|
||||
}
|
||||
}
|
||||
|
||||
tr:first-child {
|
||||
td {
|
||||
border-top: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
table.form {
|
||||
width: auto;
|
||||
margin-left: 20px;
|
||||
|
||||
& td {
|
||||
padding: 5px;
|
||||
line-height: 1.42857143;
|
||||
vertical-align: middle;
|
||||
&.key {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
label {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.form-control {
|
||||
height: 30px;
|
||||
padding: 5px 10px;
|
||||
font-size: inherit;
|
||||
line-height: inherit;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
h1 .fa-spin {
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 180%;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 140%;
|
||||
}
|
||||
|
||||
.op_box {
|
||||
display: block;
|
||||
padding: 5px;
|
||||
border-radius: 3px;
|
||||
//text-align: center;
|
||||
//margin: 5px 20px 10px 20px;
|
||||
margin: 5px 0;
|
||||
}
|
||||
|
||||
.op_error {
|
||||
//background: rgba(255, 5, 0, 0.5);
|
||||
background-color: #cc3632;
|
||||
border: 1px solid #9c2a26;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.op_wait {
|
||||
background: rgba(255, 255, 255, 0.3);
|
||||
}
|
||||
|
||||
.steps-detail {
|
||||
display: none;
|
||||
margin: 10px;
|
||||
padding: 10px;
|
||||
border: 1px solid #b4b4b4;
|
||||
background-color: #dcdcdc;
|
||||
p {
|
||||
padding-left: 5px;
|
||||
margin: 2px 0 2px 1px;
|
||||
&.error {
|
||||
color: #ffffff;
|
||||
margin: 2px 0 2px 0;
|
||||
background-color: #cc3632;
|
||||
border: 1px solid #9c2a26;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.alert {
|
||||
&.alert-warning {
|
||||
color: #6a542d;
|
||||
border: 1px solid #e2cab4;
|
||||
background-color: #ffe4cb;
|
||||
//padding: 15px;
|
||||
//color: #000000;
|
||||
//margin-bottom: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.error {
|
||||
color:#cc3632;
|
||||
}
|
||||
|
|
@ -5,118 +5,349 @@
|
|||
@import "_table";
|
||||
@import "_overwrite_bootstrap";
|
||||
|
||||
@top-navbar-height: 48px;
|
||||
@top-toolbar-height: 36px;
|
||||
@left-view-width: 220px;
|
||||
@header-height: 48px;
|
||||
@footer-height: 24px;
|
||||
|
||||
@header-height: @top-navbar-height; // + @top-toolbar-height;
|
||||
body {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
//.container {
|
||||
// min-width: 640px;
|
||||
//}
|
||||
|
||||
#page-content {
|
||||
margin-bottom: @footer-height+20px;
|
||||
}
|
||||
|
||||
#page-footer {
|
||||
nav.navbar {
|
||||
min-height: @footer-height;
|
||||
height: @footer-height;
|
||||
line-height: @footer-height;
|
||||
//background-color: rgba(0, 0, 0, 0.6);
|
||||
background-color: #cdcdcd;
|
||||
font-size: 12px;
|
||||
color: #6d6d6d;
|
||||
.container {
|
||||
height: @footer-height;
|
||||
}
|
||||
p {
|
||||
margin: 0 auto;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//@header-height: @top-navbar-height; // + @top-toolbar-height;
|
||||
|
||||
// 顶部状态栏
|
||||
.page-header-fixed {
|
||||
padding-top: @header-height;
|
||||
//.page-header-fixed {
|
||||
//padding-top: @header-height;
|
||||
//}
|
||||
|
||||
.page-header {
|
||||
//border: none;
|
||||
box-shadow: 0 0 3px rgba(0, 0, 0, .5);
|
||||
min-height: @header-height;
|
||||
//height: @header-height;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
//position: fixed;
|
||||
//z-index: 999;
|
||||
|
||||
height: @header-height;
|
||||
margin: 0 0 10px;
|
||||
border: none;
|
||||
background-color: #2a2a2a;
|
||||
//color: #fff;
|
||||
//.title {
|
||||
// line-height: @header-height;
|
||||
// font-size: 18px;
|
||||
//}
|
||||
//.logo {
|
||||
// margin-top: 5px;
|
||||
// display: inline-block;
|
||||
// width: 93px;
|
||||
// height: 30px;
|
||||
// background: url(../img/site-logo-small.png) no-repeat;
|
||||
//}
|
||||
|
||||
//.container-fluid {
|
||||
// padding-left:0;
|
||||
//}
|
||||
|
||||
.top-navbar {
|
||||
min-height: @header-height;
|
||||
height: @header-height;
|
||||
line-height: @header-height - 1px;
|
||||
//margin: 0;
|
||||
//padding:0;
|
||||
background-color: @top-navbar-bg;
|
||||
color: @top-navbar-color;
|
||||
//overflow: hidden;
|
||||
|
||||
a {
|
||||
color: #d5d5d5;
|
||||
|
||||
&:hover {
|
||||
color: #5a8fee;
|
||||
}
|
||||
}
|
||||
|
||||
.brand {
|
||||
float: left;
|
||||
display: inline-block;
|
||||
padding: (@header-height - 24)/2px 0;
|
||||
margin: 0;
|
||||
|
||||
.site-logo {
|
||||
display: block;
|
||||
width: 86px;
|
||||
height: 24px;
|
||||
background: url(../img/site-logo-small.png) no-repeat;
|
||||
}
|
||||
}
|
||||
|
||||
//.title-container {
|
||||
// float: left;
|
||||
// display: inline-block;
|
||||
// margin: 0;
|
||||
// padding: 0;
|
||||
// margin-left: 20px;
|
||||
//
|
||||
// .title {
|
||||
// font-size: 16px;
|
||||
// }
|
||||
//}
|
||||
.breadcrumb-container {
|
||||
float: left;
|
||||
display: inline-block;
|
||||
//padding-top: 6px;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
.breadcrumb {
|
||||
background-color: @top-navbar-bg;
|
||||
//height: @top-navbar-height;
|
||||
margin: 0;
|
||||
border-radius: 0;
|
||||
border: none;
|
||||
padding: 0 0 0 20px;
|
||||
font-size: 16px;
|
||||
color: @top-navbar-color;
|
||||
|
||||
& > li + li:before {
|
||||
font-size: 18px;
|
||||
padding: 0 5px;
|
||||
color: #555;
|
||||
content: '|';
|
||||
//content: "\f105";
|
||||
//font-family: 'FontAwesome';
|
||||
}
|
||||
|
||||
& > li.title {
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
& > li.sub-title {
|
||||
font-size: 14px;
|
||||
color: darken(@top-navbar-color, 10%);
|
||||
line-height: @header-height - 1px;
|
||||
}
|
||||
}
|
||||
}
|
||||
// Status
|
||||
.status-container {
|
||||
float: right;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.header {
|
||||
border: none;
|
||||
box-shadow: 0 0 3px rgba(0, 0, 0, .5);
|
||||
min-height: @header-height;
|
||||
height: @header-height;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
position: fixed;
|
||||
z-index: 999;
|
||||
// for error/reset-password page
|
||||
.info-box {
|
||||
@error-icon-size: 164px;
|
||||
width: 100%;
|
||||
//padding-left:20px;
|
||||
margin: 30px auto;
|
||||
|
||||
//.container-fluid {
|
||||
// padding-left:0;
|
||||
//}
|
||||
.top-navbar {
|
||||
min-height: @top-navbar-height;
|
||||
height: @top-navbar-height;
|
||||
line-height: @top-navbar-height;
|
||||
//margin: 0;
|
||||
//padding:0;
|
||||
background-color: @top-navbar-bg;
|
||||
color: @top-navbar-color;
|
||||
//overflow: hidden;
|
||||
.info-icon-box {
|
||||
z-index: -1;
|
||||
position: absolute;
|
||||
min-height: @error-icon-size+30px;
|
||||
overflow: hidden;
|
||||
.fa {
|
||||
margin-top: 30px;
|
||||
font-size: @error-icon-size;
|
||||
//color: rgb(255, 101, 0);
|
||||
}
|
||||
}
|
||||
|
||||
a {
|
||||
color: #d5d5d5;
|
||||
.info-message-box {
|
||||
min-height: @error-icon-size*2;
|
||||
//min-width: 300px;
|
||||
border: 1px solid #fff;
|
||||
background-color: rgba(255, 255, 255, 0.76);
|
||||
box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.3);
|
||||
padding: 15px 20px 35px 30px;
|
||||
margin-left: @error-icon-size*0.6;
|
||||
|
||||
&:hover {
|
||||
color: #5a8fee;
|
||||
}
|
||||
}
|
||||
.title {
|
||||
font-size: 180%;
|
||||
//font-weight:bold;
|
||||
margin: 15px 0;
|
||||
}
|
||||
|
||||
.brand {
|
||||
float: left;
|
||||
display: inline-block;
|
||||
padding: 12px 0;
|
||||
margin: 0;
|
||||
|
||||
.site-logo {
|
||||
display: block;
|
||||
width: 86px;
|
||||
height: 24px;
|
||||
background: url(../img/site-logo-small.png) no-repeat;
|
||||
}
|
||||
}
|
||||
|
||||
.title-container {
|
||||
float: left;
|
||||
display: inline-block;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
margin-left: 20px;
|
||||
|
||||
.title {
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
.breadcrumb-container {
|
||||
float: left;
|
||||
display: inline-block;
|
||||
//padding-top: 6px;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
.breadcrumb {
|
||||
background-color: @top-navbar-bg;
|
||||
height: @top-navbar-height;
|
||||
margin: 0;
|
||||
border-radius: 0;
|
||||
border: none;
|
||||
padding: 0 0 0 20px;
|
||||
font-size: 16px;
|
||||
color: @top-navbar-color;
|
||||
|
||||
& > li + li:before {
|
||||
font-size: 18px;
|
||||
padding: 0 5px;
|
||||
color: #555;
|
||||
//content: "\f105";
|
||||
content: '|';
|
||||
//font-family: 'FontAwesome';
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.sub-title {
|
||||
font-size: 14px;
|
||||
color: darken(@top-navbar-color, 10%);
|
||||
}
|
||||
}
|
||||
}
|
||||
// Status
|
||||
.status-container {
|
||||
float: right;
|
||||
}
|
||||
|
||||
}
|
||||
hr {
|
||||
//border-top: 1px solid #d3d3d3;
|
||||
//border-bottom: 1px solid #fff;
|
||||
margin:10px 0 20px;
|
||||
border-top: none;
|
||||
border-bottom: 1px dashed #d3d3d3;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// for maintenance page
|
||||
.content-box {
|
||||
//margin-top: 20px;
|
||||
background-color: #fff;
|
||||
padding: 20px;
|
||||
box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3);
|
||||
|
||||
.welcome-message {
|
||||
@welcome-icon-size: 18px;
|
||||
|
||||
.fa {
|
||||
display: block;
|
||||
color: #ff272a;
|
||||
font-size: @welcome-icon-size;
|
||||
float: left;
|
||||
}
|
||||
span {
|
||||
display: block;
|
||||
line-height: @welcome-icon-size;
|
||||
padding-left: @welcome-icon-size+5;
|
||||
}
|
||||
}
|
||||
|
||||
.table {
|
||||
width: auto;
|
||||
margin-left: 20px;
|
||||
|
||||
td {
|
||||
border-top: 1px dotted #ddd;
|
||||
padding: 5px;
|
||||
&.key {
|
||||
text-align: right;
|
||||
}
|
||||
&.value {
|
||||
text-align: left;
|
||||
font-weight: bold;
|
||||
}
|
||||
}
|
||||
|
||||
tr:first-child {
|
||||
td {
|
||||
border-top: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
table.form {
|
||||
width: auto;
|
||||
margin-left: 20px;
|
||||
|
||||
& td {
|
||||
padding: 5px;
|
||||
line-height: 1.42857143;
|
||||
vertical-align: middle;
|
||||
&.key {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
label {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.form-control {
|
||||
height: 30px;
|
||||
padding: 5px 10px;
|
||||
font-size: inherit;
|
||||
line-height: inherit;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
h1 .fa-spin {
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 180%;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 140%;
|
||||
}
|
||||
|
||||
.op_box {
|
||||
display: block;
|
||||
padding: 5px;
|
||||
border-radius: 3px;
|
||||
//text-align: center;
|
||||
//margin: 5px 20px 10px 20px;
|
||||
margin: 5px 0;
|
||||
}
|
||||
|
||||
.op_error {
|
||||
//background: rgba(255, 5, 0, 0.5);
|
||||
background-color: #cc3632;
|
||||
border: 1px solid #9c2a26;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.op_wait {
|
||||
background: rgba(255, 255, 255, 0.3);
|
||||
}
|
||||
|
||||
.steps-detail {
|
||||
display: none;
|
||||
margin: 10px;
|
||||
padding: 10px;
|
||||
border: 1px solid #b4b4b4;
|
||||
background-color: #dcdcdc;
|
||||
p {
|
||||
padding-left: 5px;
|
||||
margin: 2px 0 2px 1px;
|
||||
&.error {
|
||||
color: #ffffff;
|
||||
margin: 2px 0 2px 0;
|
||||
background-color: #cc3632;
|
||||
border: 1px solid #9c2a26;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.alert {
|
||||
&.alert-warning {
|
||||
color: #6a542d;
|
||||
border: 1px solid #e2cab4;
|
||||
background-color: #ffe4cb;
|
||||
//padding: 15px;
|
||||
//color: #000000;
|
||||
//margin-bottom: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.error {
|
||||
color: #cc3632;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
.page-content {
|
||||
margin-top: 10px;
|
||||
margin-bottom: 20px+@footer-height;
|
||||
|
@ -173,188 +404,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
.table-host {
|
||||
//margin-bottom: 20px;
|
||||
width: 100%;
|
||||
//border-bottom: 2px solid #e7e7e7;
|
||||
//border: 1px solid #b3cfe7;
|
||||
border-top: 10px solid #b3cfe7;
|
||||
border-bottom: 1px solid #b3cfe7;
|
||||
|
||||
.cell-host-id {
|
||||
border-left: 1px solid #e7e7e7;
|
||||
padding: 5px;
|
||||
text-align: center;
|
||||
width: 168px;
|
||||
vertical-align: middle;
|
||||
|
||||
.host-id {
|
||||
font-family: @font-family-mono;
|
||||
font-size: 13px;
|
||||
color: #999;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.host-name {
|
||||
display: block;
|
||||
// line-height: 14px;
|
||||
width: 168px;
|
||||
text-align: center;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
font-size: 16px;
|
||||
margin: auto;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.td-ip-item {
|
||||
//min-width: 12em;
|
||||
width: 10em;
|
||||
height: 18px;
|
||||
padding: 2px 4px;
|
||||
margin: 1px auto;
|
||||
|
||||
color: #333;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
border-radius: 9px;
|
||||
line-height: 11px;
|
||||
font-size: 11px;
|
||||
background: #dfdfdf !important;
|
||||
|
||||
span {
|
||||
display: inline-block;
|
||||
font-family: @font-family-mono;
|
||||
font-size: 11px;
|
||||
font-weight: 400;
|
||||
}
|
||||
}
|
||||
|
||||
.actions {
|
||||
margin-top: 20px;
|
||||
a {
|
||||
margin-left: 5px;
|
||||
margin-right: 5px;
|
||||
|
||||
&:first-child {
|
||||
margin-left: 0;
|
||||
}
|
||||
&:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.cell-detail {
|
||||
border-left: 1px solid #e7e7e7;
|
||||
border-right: 1px solid #e7e7e7;
|
||||
//border-right: 1px solid #e7e7e7;
|
||||
vertical-align: top;
|
||||
|
||||
tr {
|
||||
border-top: 1px solid #e7e7e7;
|
||||
|
||||
&:last-child {
|
||||
border-bottom: 1px solid #e7e7e7;
|
||||
}
|
||||
}
|
||||
|
||||
.row-host-info {
|
||||
background-color: #ececed;
|
||||
}
|
||||
|
||||
&.host-offline {
|
||||
background-color: #ffcecc;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
|
||||
.host-offline-msg {
|
||||
color: #802506;
|
||||
font-size: 24px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.cell-log {
|
||||
//display: none;
|
||||
td {
|
||||
border: 1px solid #e7e7e7;
|
||||
|
||||
.host-log {
|
||||
font-size: 12px;
|
||||
outline: none;
|
||||
width: 100%;
|
||||
height: 120px;
|
||||
overflow-y: auto;
|
||||
resize: none;
|
||||
border: none;
|
||||
padding: 5px;
|
||||
|
||||
div {
|
||||
margin-bottom: 3px;
|
||||
.datetime {
|
||||
font-family: @font-family-mono;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.log-box {
|
||||
margin-top: 15px;
|
||||
|
||||
.log-list {
|
||||
margin-top: 5px;
|
||||
border: 1px solid #e7e7e7;
|
||||
font-size: 12px;
|
||||
outline: none;
|
||||
width: 100%;
|
||||
//height: 480px;
|
||||
max-height: 480px;
|
||||
overflow-y: auto;
|
||||
resize: none;
|
||||
//border: none;
|
||||
padding: 5px;
|
||||
|
||||
div {
|
||||
margin-bottom: 3px;
|
||||
|
||||
&:hover {
|
||||
background-color: #f3f3f3;
|
||||
}
|
||||
|
||||
.log-dt {
|
||||
//padding:1px 3px 2px 3px;
|
||||
padding: 0 3px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 1px;
|
||||
margin-right: 3px;
|
||||
background-color: @color-bg-warning;
|
||||
color: @color-text-on-dark-bg;
|
||||
font-family: @font-family-mono;
|
||||
}
|
||||
|
||||
.log-hid {
|
||||
padding: 0 3px;
|
||||
margin-right: 3px;
|
||||
background-color: @color-bg-primary;
|
||||
color: @color-text-on-dark-bg;
|
||||
}
|
||||
.log-hname {
|
||||
padding: 0 3px;
|
||||
margin-right: 3px;
|
||||
background-color: @color-bg-primary;
|
||||
color: @color-text-on-dark-bg;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.page-nav {
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
|
@ -375,5 +424,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
@import "_overwrite_gritter";
|
||||
*/
|
||||
|
||||
@import "_overwrite_gritter";
|
||||
|
|
|
@ -1088,7 +1088,4 @@ i.upload-button {
|
|||
}
|
||||
}
|
||||
|
||||
//@import "_role";
|
||||
//@import "_table";
|
||||
//@import "_overwrite_bootstrap";
|
||||
@import "_overwrite_gritter";
|
||||
|
|
|
@ -2,16 +2,9 @@
|
|||
page_title_ = 'SFTP操作记录'
|
||||
%>
|
||||
|
||||
<%inherit file="../page_no_sidebar_base.mako"/>
|
||||
<%inherit file="../page_single_base.mako"/>
|
||||
|
||||
<%block name="extend_js">
|
||||
</%block>
|
||||
|
||||
<%block name="breadcrumb">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-file-text-o"></i> ${self.attr.page_title_}</li>
|
||||
<li><span id="recorder-info"></span></li>
|
||||
</ol>
|
||||
<%block name="extend_js_file">
|
||||
</%block>
|
||||
|
||||
<%block name="extend_css">
|
||||
|
@ -66,6 +59,17 @@
|
|||
</style>
|
||||
</%block>
|
||||
|
||||
<%block name="page_header">
|
||||
<div class="container-fluid top-navbar">
|
||||
<div class="breadcrumb-container">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-server"></i> ${self.attr.page_title_}</li>
|
||||
<li class="sub-title"><span id="recorder-info"></span></li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</%block>
|
||||
|
||||
<div class="page-content">
|
||||
<div id="no-op-msg">
|
||||
他悄悄地来,又悄悄地走,挥一挥衣袖,没有留下任何操作~~~~
|
||||
|
|
|
@ -2,16 +2,9 @@
|
|||
page_title_ = 'SSH操作记录'
|
||||
%>
|
||||
|
||||
<%inherit file="../page_no_sidebar_base.mako"/>
|
||||
<%inherit file="../page_single_base.mako"/>
|
||||
|
||||
<%block name="extend_js">
|
||||
</%block>
|
||||
|
||||
<%block name="breadcrumb">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-file-text-o"></i> ${self.attr.page_title_}</li>
|
||||
<li><span id="recorder-info"></span></li>
|
||||
</ol>
|
||||
<%block name="extend_js_file">
|
||||
</%block>
|
||||
|
||||
<%block name="extend_css">
|
||||
|
@ -61,6 +54,17 @@
|
|||
</style>
|
||||
</%block>
|
||||
|
||||
<%block name="page_header">
|
||||
<div class="container-fluid top-navbar">
|
||||
<div class="breadcrumb-container">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-server"></i> ${self.attr.page_title_}</li>
|
||||
<li class="sub-title"><span id="recorder-info"></span></li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</%block>
|
||||
|
||||
<div class="page-content">
|
||||
<div id="no-op-msg">
|
||||
他悄悄地来,又悄悄地走,挥一挥衣袖,没有留下任何操作~~~~
|
||||
|
|
|
@ -2,49 +2,65 @@
|
|||
page_title_ = '录像回放'
|
||||
%>
|
||||
|
||||
<%inherit file="../page_no_sidebar_base.mako"/>
|
||||
<%inherit file="../page_single_base.mako"/>
|
||||
|
||||
<%block name="extend_js">
|
||||
<%block name="extend_js_file">
|
||||
<script type="text/javascript" src="${ static_url('plugins/xterm/xterm.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/audit/replay.js') }"></script>
|
||||
</%block>
|
||||
|
||||
<%block name="extend_css">
|
||||
<%block name="extend_css_file">
|
||||
<link href="${ static_url('plugins/xterm/xterm.css') }" rel="stylesheet" type="text/css"/>
|
||||
</%block>
|
||||
|
||||
<%block name="embed_css">
|
||||
<style type="text/css">
|
||||
#xterm-box {
|
||||
margin: 10px 0 48px 0;
|
||||
## margin-top: 10px;
|
||||
## margin-bottom: 48px;
|
||||
## width: 300px;
|
||||
border: 1px solid #9c9c9c;
|
||||
.container {
|
||||
width:100%;
|
||||
padding-right: 20px;
|
||||
}
|
||||
#xterm-box {
|
||||
margin: 10px 0;
|
||||
padding: 5px;
|
||||
background-color: #1e1e1e;
|
||||
## margin-top: 10px;
|
||||
## margin-bottom: 48px;
|
||||
## width: 300px;
|
||||
## border: 1px solid #9c9c9c;
|
||||
}
|
||||
|
||||
.terminal {
|
||||
font-family: Consolas, Monaco, courier-new, courier, monospace;
|
||||
color: #b7b7b7;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.terminal {
|
||||
## background-color: transparent;
|
||||
## background-color: transparent;
|
||||
}
|
||||
|
||||
.terminal .xterm-viewport {
|
||||
## background-color: transparent;
|
||||
## display:none;
|
||||
## overflow: auto;
|
||||
## background-color: transparent;
|
||||
## display:none;
|
||||
## overflow: auto;
|
||||
}
|
||||
|
||||
.terminal .xterm-rows {
|
||||
border-right:1px dashed #363636;
|
||||
border-right: 1px dashed #363636;
|
||||
background-color: #1e1e1e;
|
||||
}
|
||||
</style>
|
||||
</%block>
|
||||
|
||||
<%block name="breadcrumb">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-server"></i> ${self.attr.page_title_}</li>
|
||||
<li><span id="recorder-info"></span></li>
|
||||
</ol>
|
||||
<%block name="page_header">
|
||||
<div class="container-fluid top-navbar">
|
||||
<div class="breadcrumb-container">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-server"></i> ${self.attr.page_title_}</li>
|
||||
<li class="sub-title"><span id="recorder-info"></span></li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</%block>
|
||||
|
||||
|
||||
|
@ -59,15 +75,14 @@
|
|||
<button id="btn-small-font" type="button" class="btn btn-default btn-sm"><i class="fa fa-font fa-fw"></i>-</button>
|
||||
|
||||
<div style="display:inline-block;position:relative;top:4px;margin-left:10px;margin-right:15px;">
|
||||
## <label><input id="btn-skip" type="checkbox"> 跳过无操作时间</label>
|
||||
<span id="btn-skip" style="cursor:pointer;"><i class="fa fa-check-square-o fa-fw"></i> 跳过无操作时间</span>
|
||||
</div>
|
||||
|
||||
<span id="play-status" class="badge badge-normal" style="margin-left:5px;">正在获取数据</span>
|
||||
<span id="play-time" class="badge badge-success" style="margin-left:5px;">总时长:未知</span>
|
||||
</div>
|
||||
<input id="progress" type="range" value="0" min=0 max=100 style="margin-top: 10px;"/>
|
||||
<div id="xterm-box"></div>
|
||||
<input id="progress" type="range" value="0" min=0 max=100 style="margin-top: 10px;"/>
|
||||
<div id="xterm-box"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
%>
|
||||
<%inherit file="../page_login_base.mako"/>
|
||||
|
||||
<%block name="extend_js">
|
||||
<%block name="extend_js_file">
|
||||
<script type="text/javascript" src="${ static_url('js/auth/login.js') }"></script>
|
||||
</%block>
|
||||
|
||||
|
|
|
@ -4,21 +4,24 @@
|
|||
%>
|
||||
<%inherit file="../page_single_base.mako"/>
|
||||
|
||||
<%block name="header_title">
|
||||
<a href="http://teleport.eomsoft.net" target="_blank"><span class="logo"></span></a>
|
||||
</%block>
|
||||
|
||||
<%block name="extend_css_file">
|
||||
<link href="${ static_url('css/error.css') }" rel="stylesheet" type="text/css"/>
|
||||
<%block name="page_header">
|
||||
<div class="container-fluid top-navbar">
|
||||
<div class="brand"><a href="/" target="_blank"><span class="site-logo"></span></a></div>
|
||||
<div class="breadcrumb-container">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-file-text-o"></i> <span id="page-title"></span></li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</%block>
|
||||
|
||||
|
||||
<div class="page-content">
|
||||
<div class="error-box">
|
||||
<div class="error-icon-box">
|
||||
<i class="fa fa-warning"></i>
|
||||
<div class="info-box">
|
||||
<div class="info-icon-box">
|
||||
<i class="fa fa-unlink" style="color:#ff7545;"></i>
|
||||
</div>
|
||||
<div class="error-message-box">
|
||||
<div class="info-message-box">
|
||||
<div id="title" class="title"></div>
|
||||
<hr/>
|
||||
<div id="content" class="content"></div>
|
||||
|
@ -33,14 +36,15 @@
|
|||
|
||||
var err_info = {};
|
||||
err_info['err_' + TPE_PRIVILEGE] = ['权限不足', '您没有访问权限!<br/><br/>如果您确定应该具有此访问权限,请联系系统管理员!<br/><br/>或者您可以选择访问<a href="/">起始页面</a>。'];
|
||||
err_info['err_' + TPE_HTTP_404_NOT_FOUND] = ['404 NOT FOUND', '您访问的页面不存在!请向系统管理员汇报此问题!<br/><br/>或者您可以选择访问<a href="/">起始页面</a>。'];
|
||||
err_info['err_unknown'] = ['未知错误', '发生未知错误,错误编号:'+ $app.options.err_code+'。<br/><br/>请联系系统管理员进行处理!'];
|
||||
err_info['err_' + TPE_HTTP_404_NOT_FOUND] = ['404 NOT FOUND', '您访问的地址不存在!请向系统管理员汇报此问题!<br/><br/>或者您可以选择访问<a href="/">起始页面</a>。'];
|
||||
err_info['err_unknown'] = ['未知错误', '发生未知错误,错误编号:' + $app.options.err_code + '。<br/><br/>请联系系统管理员进行处理!'];
|
||||
|
||||
var err_index = 'err_' + $app.options.err_code;
|
||||
if (!err_info.hasOwnProperty(err_index)) {
|
||||
err_index = 'err_unknown';
|
||||
}
|
||||
|
||||
$('#page-title').html(err_info[err_index][0]);
|
||||
$('#title').html(err_info[err_index][0]);
|
||||
$('#content').html(err_info[err_index][1]);
|
||||
</script>
|
||||
|
|
|
@ -25,16 +25,28 @@
|
|||
</script>
|
||||
</%block>
|
||||
|
||||
## <%block name="page_header">
|
||||
## <div id="page-header" class="header header-fixed-top">
|
||||
## <nav class="navbar navbar-fixed-top">
|
||||
## <div class="container">
|
||||
## <h1><i class="fa fa-cog fa-fw"></i> ${self.attr.page_title_}</h1>
|
||||
## </div>
|
||||
## </nav>
|
||||
## </div>
|
||||
## </%block>
|
||||
|
||||
<%block name="page_header">
|
||||
<div id="page-header" class="header header-fixed-top">
|
||||
<nav class="navbar navbar-fixed-top">
|
||||
<div class="container">
|
||||
<h1><i class="fa fa-cog fa-fw"></i> ${self.attr.page_title_}</h1>
|
||||
</div>
|
||||
</nav>
|
||||
<div class="container-fluid top-navbar">
|
||||
<div class="brand"><a href="/" target="_blank"><span class="site-logo"></span></a></div>
|
||||
<div class="breadcrumb-container">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-cog fa-fw"></i> ${self.attr.page_title_}</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</%block>
|
||||
|
||||
|
||||
## Begin Main Body.
|
||||
|
||||
<div class="content-box">
|
||||
|
|
|
@ -82,7 +82,7 @@
|
|||
## <script type="text/javascript" src="${ static_url('js/teleport/controls.js') }"></script>
|
||||
|
||||
|
||||
<%block name="extend_js"/>
|
||||
<%block name="extend_js_file"/>
|
||||
|
||||
## <script type="text/javascript">
|
||||
## $(document).ready(function () {
|
||||
|
|
|
@ -1,69 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<%!
|
||||
page_title_ = ''
|
||||
%>
|
||||
<!--[if IE 8]><html lang="en" class="ie8"> <![endif]-->
|
||||
<!--[if !IE]><!-->
|
||||
<html lang="zh_CN">
|
||||
<!--<![endif]-->
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge"/>
|
||||
<meta content="yes" name="apple-mobile-web-app-capable">
|
||||
<meta content="black-translucent" name="apple-mobile-web-app-status-bar-style">
|
||||
<title>${self.attr.page_title_}::TELEPORT</title>
|
||||
<link rel="shortcut icon" href="${ static_url('favicon.png') }">
|
||||
|
||||
<link href="${ static_url('plugins/bootstrap/css/bootstrap.min.css') }" rel="stylesheet" type="text/css"/>
|
||||
## <link href="${ static_url('plugins/bootstrap/css/bootstrap-theme.min.css') }" rel="stylesheet" type="text/css"/>
|
||||
<link href="${ static_url('plugins/font-awesome/css/font-awesome.min.css') }" rel="stylesheet">
|
||||
## <link href="${ static_url('css/main.css') }" rel="stylesheet" type="text/css"/>
|
||||
|
||||
<link href="${ static_url('css/maintenance.css') }" rel="stylesheet" type="text/css"/>
|
||||
|
||||
<%block name="extend_css"/>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div>
|
||||
<div id="page-header">
|
||||
<nav class="navbar navbar-fixed-top">
|
||||
<div class="container">
|
||||
<%block name="page_header"/>
|
||||
</div>
|
||||
</nav>
|
||||
</div>
|
||||
|
||||
<div id="page-content">
|
||||
<div class="container">
|
||||
${self.body()}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%include file="_footer.mako"/>
|
||||
</div>
|
||||
|
||||
|
||||
<%block name="extend_content" />
|
||||
|
||||
<script type="text/javascript" src="${ static_url('plugins/underscore/underscore.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/jquery/jquery-2.2.3.min.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/bootstrap/js/bootstrap.min.js') }"></script>
|
||||
<!--[if lt IE 9]>
|
||||
<script src="${ static_url('plugins/html5shiv/html5shiv.min.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/json2/json2.js') }"></script>
|
||||
<![endif]-->
|
||||
|
||||
<script type="text/javascript" src="${ static_url('js/tp-utils.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/tp-const.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/teleport.js') }"></script>
|
||||
|
||||
<%block name="extend_js"/>
|
||||
<%block name="embed_js" />
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,104 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<%!
|
||||
page_title_ = ''
|
||||
%>
|
||||
<!--[if IE 8]><html lang="en" class="ie8"> <![endif]-->
|
||||
<!--[if !IE]><!-->
|
||||
<html lang="zh_CN">
|
||||
<!--<![endif]-->
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge"/>
|
||||
<meta content="yes" name="apple-mobile-web-app-capable">
|
||||
<meta content="black-translucent" name="apple-mobile-web-app-status-bar-style">
|
||||
<title>${self.attr.page_title_}::TELEPORT</title>
|
||||
<link rel="shortcut icon" href="${ static_url('favicon.png') }">
|
||||
|
||||
## <link href="${ static_url('plugins/google-cache/open-sans.css') }" rel="stylesheet">
|
||||
<link href="${ static_url('plugins/bootstrap/css/bootstrap.min.css') }" rel="stylesheet" type="text/css"/>
|
||||
<link href="${ static_url('plugins/font-awesome/css/font-awesome.min.css') }" rel="stylesheet">
|
||||
<link href="${ static_url('plugins/gritter/css/jquery.gritter.css') }" rel="stylesheet">
|
||||
|
||||
<link href="${ static_url('css/single.css') }" rel="stylesheet" type="text/css"/>
|
||||
|
||||
<%block name="extend_css"/>
|
||||
<%block name="embed_css"/>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<!-- begin #page-container -->
|
||||
<div id="page-container" class="page-header-fixed">
|
||||
<div id="header" class="header header-fixed-top">
|
||||
|
||||
<div class="container-fluid top-navbar">
|
||||
<div class="brand"><a href="http://teleport.eomsoft.net" target="_blank"><span class="navbar-logo"></span></a></div>
|
||||
<div class="breadcrumb-container">
|
||||
<%block name="breadcrumb" />
|
||||
</div>
|
||||
|
||||
## <div class="status-container">
|
||||
## more status or global tool buttons goes here.
|
||||
## </div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="footer" class="footer footer-fixed-bottom">
|
||||
<div class="container">
|
||||
<p>触维软件旗下产品 | TELEPORT | ©2015 - 2017 <a href="http://teleport.eomsoft.net/" target="_blank">触维软件</a>,保留所有权利。</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="container-fluid">
|
||||
${self.body()}
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<%block name="extend_content" />
|
||||
|
||||
<script type="text/javascript" src="${ static_url('plugins/underscore/underscore.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/jquery/jquery-2.2.3.min.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/jquery/js.cookie.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/bootstrap/js/bootstrap.min.js') }"></script>
|
||||
<!--[if lt IE 9]>
|
||||
<script type="text/javascript" src="${ static_url('plugins/html5shiv/html5shiv.min.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/json2/json2.js') }"></script>
|
||||
<![endif]-->
|
||||
|
||||
<script type="text/javascript" src="${ static_url('plugins/jquery/jquery.mousewheel.min.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('plugins/gritter/js/jquery.gritter.js') }"></script>
|
||||
|
||||
<script type="text/javascript" src="${ static_url('plugins/keypress/keypress.js') }"></script>
|
||||
|
||||
<script type="text/javascript" src="${ static_url('js/tp-utils.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/tp-const.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/teleport.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/teleport/common.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/teleport/controls.js') }"></script>
|
||||
|
||||
|
||||
<%block name="extend_js"/>
|
||||
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
## $(document).ready(function () {
|
||||
## // once page ready, init ywl object.
|
||||
## ywl.init();
|
||||
## });
|
||||
|
||||
</script>
|
||||
|
||||
<%block name="embed_js" />
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -29,17 +29,25 @@
|
|||
|
||||
<body>
|
||||
|
||||
<div>
|
||||
<%block name="page_header"/>
|
||||
|
||||
<div id="page-content">
|
||||
<div class="container">
|
||||
${self.body()}
|
||||
</div>
|
||||
<div id="page-header" class="page-header">
|
||||
<%block name="page_header" />
|
||||
|
||||
## <div class="container-fluid top-navbar">
|
||||
## <div class="brand"><a href="/" target="_blank"><span class="site-logo"></span></a></div>
|
||||
## <div class="breadcrumb-container">
|
||||
## <%block name="breadcrumb" />
|
||||
## </div>
|
||||
## </div>
|
||||
</div>
|
||||
|
||||
<div id="page-content">
|
||||
<div class="container">
|
||||
${self.body()}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%include file="_footer.mako"/>
|
||||
</div>
|
||||
|
||||
|
||||
## <div id="page-header">
|
||||
|
@ -72,9 +80,12 @@
|
|||
<script type="text/javascript" src="${ static_url('plugins/json2/json2.js') }"></script>
|
||||
<![endif]-->
|
||||
|
||||
<script type="text/javascript" src="${ static_url('plugins/gritter/js/jquery.gritter.js') }"></script>
|
||||
|
||||
<script type="text/javascript" src="${ static_url('js/tp-utils.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/tp-const.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/teleport.js') }"></script>
|
||||
<script type="text/javascript" src="${ static_url('js/teleport/common.js') }"></script>
|
||||
|
||||
<%block name="extend_js_file"/>
|
||||
<%block name="embed_js" />
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
%>
|
||||
<%inherit file="../page_single_base.mako"/>
|
||||
|
||||
<%block name="page_header">
|
||||
<a href="http://teleport.eomsoft.net" target="_blank"><span class="logo"></span></a>
|
||||
<%block name="extend_js_file">
|
||||
<script type="text/javascript" src="${ static_url('js/user/reset-password.js') }"></script>
|
||||
</%block>
|
||||
|
||||
<%block name="embed_css">
|
||||
|
@ -21,36 +21,49 @@
|
|||
</style>
|
||||
</%block>
|
||||
|
||||
<div class="page-content">
|
||||
<div class="error-box">
|
||||
<div class="error-icon-box">
|
||||
<i id="icon-bg" class="fa fa-warning"></i>
|
||||
<%block name="page_header">
|
||||
<div class="container-fluid top-navbar">
|
||||
<div class="brand"><a href="/" target="_blank"><span class="site-logo"></span></a></div>
|
||||
<div class="breadcrumb-container">
|
||||
<ol class="breadcrumb">
|
||||
<li><i class="fa fa-key"></i> 密码管理</li>
|
||||
</ol>
|
||||
</div>
|
||||
<div class="error-message-box">
|
||||
</div>
|
||||
## <a href="http://teleport.eomsoft.net" target="_blank"><span class="logo"></span></a>
|
||||
</%block>
|
||||
|
||||
<div class="page-content">
|
||||
<div class="info-box">
|
||||
<div class="info-icon-box">
|
||||
<i id="icon-bg"></i>
|
||||
</div>
|
||||
<div class="info-message-box">
|
||||
<div id="title" class="title">设置密码</div>
|
||||
<hr/>
|
||||
<div id="content" class="content">
|
||||
|
||||
<div id="error-area" style="display:none;">
|
||||
<div id="message" class="alert alert-danger"></div>
|
||||
<div id="actions" style="display: none;">
|
||||
您可以:
|
||||
<div id="err-message" class="alert alert-danger"></div>
|
||||
<div id="err-actions">
|
||||
现在您可以:
|
||||
<ul>
|
||||
<li>重新找回密码</li>
|
||||
<li>联系管理员重置密码</li>
|
||||
<li><a href="/user/reset-password">尝试重新找回密码</a></li>
|
||||
<li>联系管理员手工重置密码</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="find-my-password" style="display: none;">
|
||||
<div class="row" style="padding:0 20px;">
|
||||
<div class="col-sm-4">
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="fa fa-user-circle-o fa-fw"></i></span>
|
||||
<input data-field="username" type="text" class="form-control mono" placeholder="登录teleport系统的用户名">
|
||||
<input id="username" type="text" class="form-control mono" placeholder="teleport系统用户名">
|
||||
</div>
|
||||
<div class="input-group" style="margin-top:10px;">
|
||||
<span class="input-group-addon"><i class="fa fa-envelope-o fa-fw"></i></span>
|
||||
<input data-field="email" type="text" class="form-control mono" placeholder="用户绑定的电子邮箱">
|
||||
<input id="email" type="text" class="form-control mono" placeholder="用户绑定的电子邮箱">
|
||||
</div>
|
||||
|
||||
<div class="input-group" style="margin-top:10px;">
|
||||
|
@ -61,7 +74,7 @@
|
|||
</div>
|
||||
<p class="input-addon-desc">验证码,点击图片可更换</p>
|
||||
</div>
|
||||
<div class="col-sm-8">
|
||||
<div class="col-md-8">
|
||||
<div class="alert alert-info">
|
||||
<p>请填写用户信息,随后一封密码重置确认函将发送到您的邮箱。</p>
|
||||
<p>请注意,密码重置确认函在24小时内有效!</p>
|
||||
|
@ -72,10 +85,10 @@
|
|||
</div>
|
||||
|
||||
<div class="row" style="padding:0 20px;margin-top:10px;">
|
||||
<div class="col-sm-4">
|
||||
<button type="button" class="btn btn-primary" id="btn-send-email" style="width:100%;"><i class="fa fa-search-plus fa-fw"></i> 找回密码</button>
|
||||
<div class="col-md-4">
|
||||
<button type="button" class="btn btn-primary" id="btn-send-email" style="width:100%;"><i class="fa fa-send fa-fw"></i> 发送密码重置确认函</button>
|
||||
</div>
|
||||
<div class="col-sm-8">
|
||||
<div class="col-md-8">
|
||||
<div id="send-result" class="alert alert-danger" style="display: none;"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -83,15 +96,15 @@
|
|||
|
||||
<div id="password-area" style="display:none;">
|
||||
<div class="row" style="padding:0 20px;">
|
||||
<div class="col-sm-4">
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="fa fa-key fa-fw"></i></span>
|
||||
<span class="input-group-addon"><i class="fa fa-edit"></i></span>
|
||||
<input data-field="password" type="password" class="form-control mono" placeholder="设置新密码">
|
||||
<span class="input-group-btn"><button class="btn btn-default" type="button" id="btn-switch-password"><i class="fa fa-eye fa-fw"></i></button></span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-sm-8">
|
||||
<div class="col-md-8">
|
||||
<div class="alert alert-warning">
|
||||
<p>注意,系统启用强密码策略,要求密码至少8位,必须包含大写字母、小写字母以及数字。</p>
|
||||
</div>
|
||||
|
@ -99,28 +112,14 @@
|
|||
</div>
|
||||
|
||||
<div class="row" style="padding:0 20px;margin-top:10px;">
|
||||
<div class="col-sm-4">
|
||||
<div class="col-md-4">
|
||||
<button type="button" class="btn btn-primary" id="btn-reset-password" style="width:100%;"><i class="fa fa-check fa-fw"></i> 重置密码</button>
|
||||
</div>
|
||||
<div class="col-sm-8">
|
||||
<div class="col-md-8">
|
||||
<div id="reset-result" class="alert alert-danger" style="display: none;"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
## <div class="form-group form-group-sm">
|
||||
## <div class="col-sm-4">
|
||||
## <div class="input-group">
|
||||
## <input data-field="password" type="password" class="form-control mono" placeholder="设置新密码">
|
||||
## <span class="input-group-btn"><button class="btn btn-sm btn-default" type="button" id="btn-switch-password"><i class="fa fa-eye fa-fw"></i></button></span>
|
||||
## </div>
|
||||
## </div>
|
||||
## <div class="col-sm-8">
|
||||
## <button type="button" class="btn btn-sm btn-primary" id="btn-reset-password"><i class="fa fa-check fa-fw"></i> 重置密码</button>
|
||||
## </div>
|
||||
## </div>
|
||||
## <div class="clear-float"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -132,39 +131,5 @@
|
|||
"use strict";
|
||||
$app.add_options(${page_param});
|
||||
console.log($app.options);
|
||||
|
||||
$app.dom = {
|
||||
title: $('#title'),
|
||||
icon_bg: $('#icon-bg'),
|
||||
|
||||
err_area: $('#error-area'),
|
||||
message: $('#message'),
|
||||
actions: $('#actions'),
|
||||
|
||||
find_password_area: $('#find-my-password'),
|
||||
captcha_image: $('#captcha-image'),
|
||||
|
||||
password_area: $('#password-area')
|
||||
};
|
||||
|
||||
$app.dom.captcha_image.click(function () {
|
||||
$(this).attr('src', '/auth/captcha?h=28&rnd=' + Math.random());
|
||||
$app.dom.input_captcha.focus().val('');
|
||||
});
|
||||
|
||||
if ($app.options.mode === 1) {
|
||||
// show 'find-my-password' page
|
||||
$app.dom.title.text('找回密码');
|
||||
$app.dom.icon_bg.removeClass().addClass('fa fa-search-plus');
|
||||
$app.dom.captcha_image.attr('src', '/auth/captcha?h=28&rnd=' + Math.random());
|
||||
$app.dom.find_password_area.show();
|
||||
} else if ($app.options.mode === 2) {
|
||||
// show 'password-expired' page
|
||||
$app.dom.title.text('更新密码');
|
||||
} else if ($app.options.mode === 3) {
|
||||
// show 'set-new-password' page
|
||||
$app.dom.title.text('重置密码');
|
||||
$app.dom.password_area.show();
|
||||
}
|
||||
</script>
|
||||
</%block>
|
||||
|
|
|
@ -74,7 +74,7 @@ class DatabaseInit:
|
|||
f.append('PRIMARY KEY (`name` ASC)')
|
||||
|
||||
self._db_exec(
|
||||
'创建配置项表 config',
|
||||
'创建配置项表...',
|
||||
'CREATE TABLE {}config ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -100,7 +100,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建角色表 role',
|
||||
'创建角色表...',
|
||||
'CREATE TABLE {}role ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -157,7 +157,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建用户表 user',
|
||||
'创建用户表...',
|
||||
'CREATE TABLE {}user ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -176,7 +176,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建用户找回密码表 user_rpt',
|
||||
'创建用户找回密码表...',
|
||||
'CREATE TABLE {}user_rpt ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -203,7 +203,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建组信息表 group',
|
||||
'创建组信息表...',
|
||||
'CREATE TABLE {}group ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -223,7 +223,7 @@ class DatabaseInit:
|
|||
f.append('mid int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建组成员映射表 group_map',
|
||||
'创建组成员映射表...',
|
||||
'CREATE TABLE {}group_map ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -270,7 +270,7 @@ class DatabaseInit:
|
|||
# 将来使用host_attr表来动态扩展主机信息
|
||||
|
||||
self._db_exec(
|
||||
'创建主机表 host',
|
||||
'创建主机表...',
|
||||
'CREATE TABLE {}host ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -326,7 +326,7 @@ class DatabaseInit:
|
|||
f.append('last_secret int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建账号表 acc',
|
||||
'创建账号表...',
|
||||
'CREATE TABLE {}acc ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -358,7 +358,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建账号认证信息表 acc_auth',
|
||||
'创建账号认证信息表...',
|
||||
'CREATE TABLE {}acc_auth ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -424,7 +424,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建运维授权策略表 ops_policy',
|
||||
'创建运维授权策略表...',
|
||||
'CREATE TABLE {}ops_policy ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -462,7 +462,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建运维授权策略明细表 ops_auz',
|
||||
'创建运维授权策略明细表...',
|
||||
'CREATE TABLE {}ops_auz ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -539,7 +539,7 @@ class DatabaseInit:
|
|||
f.append('protocol_port int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建运维授权映射表 ops_map',
|
||||
'创建运维授权映射表...',
|
||||
'CREATE TABLE {}ops_map ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -568,7 +568,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建审计授权策略表 audit_policy',
|
||||
'创建审计授权策略表...',
|
||||
'CREATE TABLE {}audit_policy ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -602,7 +602,7 @@ class DatabaseInit:
|
|||
f.append('create_time int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建审计授权策略明细表 audit_auz',
|
||||
'创建审计授权策略明细表...',
|
||||
'CREATE TABLE {}audit_auz ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -630,7 +630,7 @@ class DatabaseInit:
|
|||
f.append('router_port int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建审计授权映射表 audit_map',
|
||||
'创建审计授权映射表...',
|
||||
'CREATE TABLE {}audit_map ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -658,7 +658,7 @@ class DatabaseInit:
|
|||
f.append('detail TEXT DEFAULT ""')
|
||||
|
||||
self._db_exec(
|
||||
'创建系统日志表 syslog',
|
||||
'创建系统日志表...',
|
||||
'CREATE TABLE {}syslog ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
@ -712,7 +712,7 @@ class DatabaseInit:
|
|||
f.append('time_end int(11) DEFAULT 0')
|
||||
|
||||
self._db_exec(
|
||||
'创建运维录像日志表 record',
|
||||
'创建运维录像日志表...',
|
||||
'CREATE TABLE {}record ({});'.format(self.db.table_prefix, ','.join(f))
|
||||
)
|
||||
|
||||
|
|
|
@ -71,6 +71,9 @@ def get_records(sql_filter, sql_order, sql_limit, sql_restrict, sql_exclude):
|
|||
|
||||
|
||||
def read_record_head(record_id):
|
||||
if not get_cfg().core.detected:
|
||||
return None, TPE_NO_CORE_SERVER
|
||||
|
||||
record_path = os.path.join(get_cfg().core.replay_path, 'ssh', '{:09d}'.format(int(record_id)))
|
||||
header_file_path = os.path.join(record_path, 'tp-ssh.tpr')
|
||||
|
||||
|
@ -151,6 +154,9 @@ def read_record_head(record_id):
|
|||
|
||||
|
||||
def read_record_data(record_id, offset):
|
||||
if not get_cfg().core.detected:
|
||||
return None, TPE_NO_CORE_SERVER
|
||||
|
||||
# read 1000 packages one time from offset.
|
||||
record_path = os.path.join(get_cfg().core.replay_path, 'ssh', '{:09d}'.format(int(record_id)))
|
||||
file_data = os.path.join(record_path, 'tp-ssh.dat')
|
||||
|
|
|
@ -295,7 +295,11 @@ def check_reset_token(token):
|
|||
# s = SQL(db)
|
||||
_time_now = tp_timestamp_utc_now()
|
||||
|
||||
# 0. query user's id
|
||||
# 0. remove expired token (after 3 days)
|
||||
sql = 'DELETE FROM `{dbtp}user_rpt` WHERE create_time<{dbph};'.format(dbtp=db.table_prefix, dbph=db.place_holder)
|
||||
db.query(sql, (_time_now - 3 * 24 * 60 * 60,))
|
||||
|
||||
# 1. query user's id
|
||||
sql = 'SELECT create_time FROM `{dbtp}user_rpt` WHERE token={dbph};'.format(dbtp=db.table_prefix, dbph=db.place_holder)
|
||||
db_ret = db.query(sql, (token,))
|
||||
if db_ret is None or len(db_ret) == 0:
|
||||
|
|
Loading…
Reference in New Issue