feat(partner): 升级创客平级收益支持两代级联机制与单元测试用例
这个提交包含在:
@@ -117,7 +117,8 @@ class Index extends Backend
|
||||
$background = $background ? (stripos($background, 'http') === 0 ? $background : config('site.cdnurl') . $background) : '';
|
||||
$this->view->assign('keeyloginhours', $keeyloginhours);
|
||||
$this->view->assign('background', $background);
|
||||
$this->view->assign('title', __('Login'));
|
||||
$siteName = Config::get('site.name');
|
||||
$this->view->assign('title', ($siteName ? $siteName . ' · ' : '') . __('Login'));
|
||||
Hook::listen("admin_login_init", $this->request);
|
||||
return $this->view->fetch();
|
||||
}
|
||||
|
||||
@@ -14,6 +14,14 @@ return [
|
||||
'Keep login' => '保持会话',
|
||||
'Guest' => '游客',
|
||||
'Welcome' => '%s,你好!',
|
||||
'Welcome back' => '欢迎回来',
|
||||
'Admin console' => '运营控制台',
|
||||
'Sign in to continue' => '使用管理员账号继续',
|
||||
'Show password' => '显示密码',
|
||||
'Hide password' => '隐藏密码',
|
||||
'Secure session' => '安全会话',
|
||||
'Audited actions' => '操作留痕',
|
||||
'Role based access' => '权限可控',
|
||||
'View' => '查看',
|
||||
'Add' => '添加',
|
||||
'Edit' => '编辑',
|
||||
|
||||
@@ -1,145 +1,617 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
{include file="common/meta" /}
|
||||
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500&family=IBM+Plex+Sans:wght@400;500;600&family=Noto+Serif+SC:wght@500;600;700&display=swap" rel="stylesheet">
|
||||
<style type="text/css">
|
||||
body {
|
||||
color: #999;
|
||||
background-color: #f1f4fd;
|
||||
background-size: cover;
|
||||
:root {
|
||||
--ink: #0b1412;
|
||||
--ink-soft: #14201c;
|
||||
--paper: #f3ead8;
|
||||
--paper-deep: #e7dcc4;
|
||||
--brass: #c4a46a;
|
||||
--brass-deep: #9c7d3f;
|
||||
--celadon: #7f927c;
|
||||
--text: #1c211d;
|
||||
--muted: #6d6a5e;
|
||||
--line: rgba(28, 33, 29, 0.12);
|
||||
--danger: #a63d32;
|
||||
--font-display: "Noto Serif SC", "Songti SC", "STSong", serif;
|
||||
--font-ui: "IBM Plex Sans", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
|
||||
--font-mono: "IBM Plex Mono", "SFMono-Regular", Menlo, monospace;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #444;
|
||||
html,
|
||||
body.login-body {
|
||||
min-height: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
.login-screen {
|
||||
max-width: 430px;
|
||||
padding: 0;
|
||||
margin: 100px auto 0 auto;
|
||||
|
||||
body.login-body {
|
||||
margin: 0;
|
||||
color: var(--text);
|
||||
font-family: var(--font-ui);
|
||||
background: var(--ink);
|
||||
-webkit-font-smoothing: antialiased;
|
||||
}
|
||||
|
||||
.login-screen .well {
|
||||
border-radius: 3px;
|
||||
-webkit-box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
|
||||
box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
|
||||
background: rgba(255, 255, 255, 1);
|
||||
border: none;
|
||||
/*overflow: hidden;*/
|
||||
padding: 0;
|
||||
body.login-body a {
|
||||
color: var(--brass-deep);
|
||||
}
|
||||
|
||||
@media (max-width: 767px) {
|
||||
.login-screen {
|
||||
padding: 0 20px;
|
||||
}
|
||||
.login-shell {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.8fr);
|
||||
min-height: 100dvh;
|
||||
}
|
||||
|
||||
.profile-img-card {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
display: block;
|
||||
-moz-border-radius: 50%;
|
||||
-webkit-border-radius: 50%;
|
||||
border-radius: 50%;
|
||||
margin: -93px auto 30px;
|
||||
border: 5px solid #fff;
|
||||
}
|
||||
|
||||
.profile-name-card {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.login-head {
|
||||
background: #899fe1;
|
||||
border-radius: 3px 3px 0 0;
|
||||
}
|
||||
|
||||
.login-form {
|
||||
padding: 40px 30px;
|
||||
.login-brand {
|
||||
position: relative;
|
||||
z-index: 99;
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
padding: 48px 56px 40px;
|
||||
color: #efe6d4;
|
||||
background:
|
||||
radial-gradient(ellipse 70% 50% at 10% 90%, rgba(196, 164, 106, 0.16), transparent 55%),
|
||||
radial-gradient(ellipse 50% 40% at 90% 8%, rgba(127, 146, 124, 0.18), transparent 50%),
|
||||
linear-gradient(160deg, var(--ink-soft), var(--ink) 62%);
|
||||
}
|
||||
|
||||
#login-form {
|
||||
margin-top: 20px;
|
||||
.login-brand::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
background-image:
|
||||
linear-gradient(rgba(196, 164, 106, 0.08) 1px, transparent 1px),
|
||||
linear-gradient(90deg, rgba(196, 164, 106, 0.08) 1px, transparent 1px);
|
||||
background-size: 56px 56px;
|
||||
mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.7), transparent 88%);
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
#login-form .input-group {
|
||||
margin-bottom: 15px;
|
||||
.login-brand::after {
|
||||
content: attr(data-mark);
|
||||
position: absolute;
|
||||
right: -4%;
|
||||
bottom: -10%;
|
||||
font-family: var(--font-display);
|
||||
font-size: clamp(180px, 28vw, 340px);
|
||||
font-weight: 700;
|
||||
line-height: 0.8;
|
||||
color: rgba(243, 234, 216, 0.045);
|
||||
pointer-events: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
#login-form .form-control {
|
||||
.brand-top,
|
||||
.brand-copy,
|
||||
.brand-foot {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.brand-mark {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 12px;
|
||||
font-family: var(--font-mono);
|
||||
font-size: 12px;
|
||||
letter-spacing: 0.18em;
|
||||
text-transform: uppercase;
|
||||
color: var(--brass);
|
||||
}
|
||||
|
||||
.brand-mark i {
|
||||
display: block;
|
||||
width: 28px;
|
||||
height: 1px;
|
||||
background: var(--brass);
|
||||
}
|
||||
|
||||
.brand-copy {
|
||||
max-width: 520px;
|
||||
padding: 48px 0;
|
||||
}
|
||||
|
||||
.brand-copy h1 {
|
||||
margin: 0 0 16px;
|
||||
font-family: var(--font-display);
|
||||
font-size: clamp(40px, 5vw, 64px);
|
||||
font-weight: 600;
|
||||
line-height: 1.15;
|
||||
letter-spacing: 0.04em;
|
||||
color: #f7f0e2;
|
||||
}
|
||||
|
||||
.brand-copy p {
|
||||
margin: 0 0 28px;
|
||||
max-width: 28em;
|
||||
font-size: 16px;
|
||||
line-height: 1.7;
|
||||
color: rgba(243, 234, 216, 0.72);
|
||||
}
|
||||
|
||||
.brand-points {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 10px;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
.brand-points li {
|
||||
padding: 7px 12px;
|
||||
border: 1px solid rgba(196, 164, 106, 0.28);
|
||||
color: #e7d7b0;
|
||||
font-size: 12px;
|
||||
letter-spacing: 0.08em;
|
||||
}
|
||||
|
||||
.brand-foot {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
gap: 16px;
|
||||
font-family: var(--font-mono);
|
||||
font-size: 12px;
|
||||
letter-spacing: 0.08em;
|
||||
color: rgba(243, 234, 216, 0.45);
|
||||
}
|
||||
|
||||
.login-panel {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 40px 36px;
|
||||
background:
|
||||
linear-gradient(180deg, rgba(255, 255, 255, 0.28), transparent 28%),
|
||||
var(--paper);
|
||||
}
|
||||
|
||||
.login-card {
|
||||
width: 100%;
|
||||
max-width: 400px;
|
||||
}
|
||||
|
||||
.login-greet {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 14px;
|
||||
margin-bottom: 28px;
|
||||
}
|
||||
|
||||
.login-avatar {
|
||||
position: relative;
|
||||
width: 52px;
|
||||
height: 52px;
|
||||
flex: 0 0 52px;
|
||||
border-radius: 50%;
|
||||
background: var(--paper-deep);
|
||||
box-shadow: inset 0 0 0 1px var(--line);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.login-avatar::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
inset: 14px 14px 10px;
|
||||
border-radius: 50% 50% 40% 40%;
|
||||
background: #b7aa90;
|
||||
}
|
||||
|
||||
.login-avatar::after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
bottom: -8px;
|
||||
width: 34px;
|
||||
height: 22px;
|
||||
transform: translateX(-50%);
|
||||
border-radius: 16px 16px 0 0;
|
||||
background: #8f846c;
|
||||
}
|
||||
|
||||
#profile-img {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
#profile-img.is-ready {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.login-greet-text {
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.login-greet-text em,
|
||||
#profile-name {
|
||||
display: block;
|
||||
margin: 0 0 4px;
|
||||
font-style: normal;
|
||||
font-size: 12px;
|
||||
letter-spacing: 0.14em;
|
||||
color: var(--brass-deep);
|
||||
font-family: var(--font-mono);
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.login-greet.has-user em {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.login-greet:not(.has-user) #profile-name {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.login-greet-text h2 {
|
||||
margin: 0;
|
||||
font-family: var(--font-display);
|
||||
font-size: 28px;
|
||||
font-weight: 600;
|
||||
line-height: 1.25;
|
||||
letter-spacing: 0.06em;
|
||||
}
|
||||
|
||||
#errtips {
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.login-field {
|
||||
margin-bottom: 18px;
|
||||
}
|
||||
|
||||
.login-field label {
|
||||
display: block;
|
||||
margin-bottom: 8px;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
color: var(--text);
|
||||
}
|
||||
|
||||
</style>
|
||||
<!--@formatter:off-->
|
||||
{if $background}
|
||||
<style type="text/css">
|
||||
body{
|
||||
background-image: url('{$background|htmlentities}');
|
||||
.login-control {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
body.login-body .login-control .form-control {
|
||||
height: 50px;
|
||||
padding: 12px 16px;
|
||||
border: 1px solid rgba(28, 33, 29, 0.16);
|
||||
border-radius: 2px;
|
||||
background: rgba(255, 255, 255, 0.55);
|
||||
box-shadow: none;
|
||||
color: var(--text);
|
||||
font-size: 16px;
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
body.login-body .login-control .form-control:hover {
|
||||
border-color: rgba(156, 125, 63, 0.45);
|
||||
}
|
||||
|
||||
body.login-body .login-control .form-control:focus {
|
||||
border-color: var(--brass-deep);
|
||||
box-shadow: 0 0 0 3px rgba(196, 164, 106, 0.28);
|
||||
background: #fffdf8;
|
||||
}
|
||||
|
||||
body.login-body .login-control.has-toggle .form-control {
|
||||
padding-right: 48px;
|
||||
}
|
||||
|
||||
.field-toggle {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
width: 48px;
|
||||
height: 50px;
|
||||
border: 0;
|
||||
background: transparent;
|
||||
color: var(--muted);
|
||||
cursor: pointer;
|
||||
touch-action: manipulation;
|
||||
}
|
||||
|
||||
.field-toggle:hover,
|
||||
.field-toggle:focus,
|
||||
.field-toggle.is-on {
|
||||
color: var(--brass-deep);
|
||||
}
|
||||
|
||||
.field-toggle:focus-visible {
|
||||
outline: 2px solid var(--brass);
|
||||
outline-offset: -4px;
|
||||
}
|
||||
|
||||
.field-toggle .icon-off {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.field-toggle.is-on .icon-on {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.field-toggle.is-on .icon-off {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
body.login-body .login-control .input-group {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
body.login-body .login-control .input-group .form-control {
|
||||
flex: 1 1 auto;
|
||||
}
|
||||
|
||||
body.login-body .login-control .input-group-addon {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 0;
|
||||
border: 1px solid rgba(28, 33, 29, 0.16);
|
||||
border-left: 0;
|
||||
background: #fffdf8;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
body.login-body .login-control .input-group-addon img {
|
||||
display: block;
|
||||
width: 108px;
|
||||
height: 48px;
|
||||
}
|
||||
|
||||
body.login-body .login-keep.checkbox {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
min-height: 44px;
|
||||
margin: 6px 0 22px;
|
||||
}
|
||||
|
||||
body.login-body .login-keep label {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
margin: 0;
|
||||
font-weight: 400;
|
||||
color: var(--muted);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
body.login-body .login-keep input[type="checkbox"] {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
margin: 0;
|
||||
accent-color: var(--brass-deep);
|
||||
}
|
||||
|
||||
body.login-body .login-submit.btn {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
min-height: 50px;
|
||||
padding: 0 16px;
|
||||
border: 0;
|
||||
border-radius: 2px;
|
||||
background: var(--ink);
|
||||
box-shadow: none;
|
||||
color: #f3ead8;
|
||||
font-size: 16px;
|
||||
font-weight: 500;
|
||||
letter-spacing: 0.28em;
|
||||
text-indent: 0.28em;
|
||||
transition: background 180ms ease, transform 160ms ease;
|
||||
}
|
||||
|
||||
body.login-body .login-submit.btn:hover,
|
||||
body.login-body .login-submit.btn:focus {
|
||||
background: #16221e;
|
||||
color: #f7f0e2;
|
||||
}
|
||||
|
||||
body.login-body .login-submit.btn:active {
|
||||
transform: scale(0.985);
|
||||
}
|
||||
|
||||
body.login-body .login-submit.btn:focus-visible {
|
||||
outline: 2px solid var(--brass);
|
||||
outline-offset: 3px;
|
||||
}
|
||||
|
||||
body.login-body .login-submit.btn.disabled,
|
||||
body.login-body .login-submit.btn[disabled] {
|
||||
opacity: 0.55;
|
||||
cursor: not-allowed;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
.login-note {
|
||||
margin: 22px 0 0;
|
||||
text-align: center;
|
||||
font-size: 12px;
|
||||
line-height: 1.6;
|
||||
color: var(--muted);
|
||||
}
|
||||
|
||||
.login-rise {
|
||||
animation: login-rise 640ms cubic-bezier(0.22, 1, 0.36, 1) both;
|
||||
}
|
||||
|
||||
.login-rise-2 { animation-delay: 80ms; }
|
||||
.login-rise-3 { animation-delay: 150ms; }
|
||||
.login-rise-4 { animation-delay: 220ms; }
|
||||
|
||||
@keyframes login-rise {
|
||||
from {
|
||||
opacity: 0;
|
||||
transform: translateY(12px);
|
||||
}
|
||||
</style>
|
||||
to {
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 900px) {
|
||||
.login-shell {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
|
||||
.login-brand {
|
||||
min-height: 240px;
|
||||
padding: 28px 24px 24px;
|
||||
}
|
||||
|
||||
.brand-copy {
|
||||
padding: 20px 0 8px;
|
||||
}
|
||||
|
||||
.brand-copy h1 {
|
||||
font-size: 32px;
|
||||
}
|
||||
|
||||
.brand-copy p,
|
||||
.brand-points {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.login-panel {
|
||||
align-items: flex-start;
|
||||
padding: 28px 20px 40px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.login-rise,
|
||||
body.login-body .login-submit.btn {
|
||||
animation: none;
|
||||
transition: none;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
{if $background}
|
||||
<style type="text/css">
|
||||
.login-brand {
|
||||
background-image:
|
||||
linear-gradient(160deg, rgba(11, 20, 18, 0.82), rgba(11, 20, 18, 0.7) 62%),
|
||||
url('{$background|htmlentities}');
|
||||
background-size: cover;
|
||||
background-position: center;
|
||||
}
|
||||
</style>
|
||||
{/if}
|
||||
<!--@formatter:on-->
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="login-wrapper">
|
||||
<div class="login-screen">
|
||||
<div class="well">
|
||||
<div class="login-head">
|
||||
<img src="__CDN__/assets/img/login-head.png" style="width:100%;"/>
|
||||
<body class="login-body">
|
||||
<div class="login-shell">
|
||||
<aside class="login-brand" aria-label="{:__('Admin console')}" data-mark="{$site.name|mb_substr=0,1,'utf-8'|htmlentities}">
|
||||
<div class="brand-top login-rise">
|
||||
<span class="brand-mark"><i></i>{:__('Admin console')}</span>
|
||||
</div>
|
||||
<div class="brand-copy login-rise login-rise-2">
|
||||
<h1>{$site.name|htmlentities}</h1>
|
||||
<p>{:__('Sign in to continue')}。会话受权限约束,关键操作可追溯。</p>
|
||||
<ul class="brand-points">
|
||||
<li>{:__('Secure session')}</li>
|
||||
<li>{:__('Audited actions')}</li>
|
||||
<li>{:__('Role based access')}</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="brand-foot login-rise login-rise-3">
|
||||
<span>{:date('Y.m.d')}</span>
|
||||
<span>{$site.version|htmlentities}</span>
|
||||
</div>
|
||||
</aside>
|
||||
|
||||
<main class="login-panel">
|
||||
<div class="login-card login-rise login-rise-4">
|
||||
<div class="login-greet">
|
||||
<div class="login-avatar">
|
||||
<img id="profile-img" alt="" width="52" height="52" src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"/>
|
||||
</div>
|
||||
<div class="login-form">
|
||||
<img id="profile-img" class="profile-img-card" src="__CDN__/assets/img/avatar.png"/>
|
||||
<p id="profile-name" class="profile-name-card"></p>
|
||||
|
||||
<form action="" method="post" id="login-form">
|
||||
<!--@AdminLoginFormBegin-->
|
||||
<div id="errtips" class="hide"></div>
|
||||
{:token()}
|
||||
<div class="input-group">
|
||||
<div class="input-group-addon"><span class="glyphicon glyphicon-user" aria-hidden="true"></span></div>
|
||||
<input type="text" class="form-control" id="pd-form-username" placeholder="{:__('Username')}" name="username" autocomplete="off" value="" data-rule="{:__('Username')}:required;username"/>
|
||||
</div>
|
||||
|
||||
<div class="input-group">
|
||||
<div class="input-group-addon"><span class="glyphicon glyphicon-lock" aria-hidden="true"></span></div>
|
||||
<input type="password" class="form-control" id="pd-form-password" placeholder="{:__('Password')}" name="password" autocomplete="off" value="" data-rule="{:__('Password')}:required;password"/>
|
||||
</div>
|
||||
<!--@CaptchaBegin-->
|
||||
{if $Think.config.fastadmin.login_captcha}
|
||||
<div class="input-group">
|
||||
<div class="input-group-addon"><span class="glyphicon glyphicon-option-horizontal" aria-hidden="true"></span></div>
|
||||
<input type="text" name="captcha" class="form-control" placeholder="{:__('Captcha')}" data-rule="{:__('Captcha')}:required;length({$Think.config.captcha.length|htmlentities})" autocomplete="off"/>
|
||||
<span class="input-group-addon" style="padding:0;border:none;cursor:pointer;">
|
||||
<img src="{:rtrim('__PUBLIC__', '/')}/index.php?s=/captcha" width="100" height="30" onclick="this.src = '{:rtrim('__PUBLIC__', '/')}/index.php?s=/captcha&r=' + Math.random();"/>
|
||||
</span>
|
||||
</div>
|
||||
{/if}
|
||||
<!--@CaptchaEnd-->
|
||||
{if $keeyloginhours>0}
|
||||
<div class="form-group checkbox">
|
||||
<label class="inline" for="keeplogin" data-toggle="tooltip" title="{:__('The duration of the session is %s hours', $keeyloginhours)}">
|
||||
<input type="checkbox" name="keeplogin" id="keeplogin" value="1"/>
|
||||
{:__('Keep login')}
|
||||
</label>
|
||||
</div>
|
||||
{/if}
|
||||
<div class="form-group">
|
||||
<button type="submit" class="btn btn-success btn-lg btn-block" style="background:#708eea;">{:__('Sign in')}</button>
|
||||
</div>
|
||||
<!--@AdminLoginFormEnd-->
|
||||
</form>
|
||||
<div class="login-greet-text">
|
||||
<em>{:__('Welcome back')}</em>
|
||||
<span id="profile-name"></span>
|
||||
<h2>{:__('Login')}</h2>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<form action="" method="post" id="login-form">
|
||||
<!--@AdminLoginFormBegin-->
|
||||
<div id="errtips" class="hide"></div>
|
||||
{:token()}
|
||||
|
||||
<div class="login-field">
|
||||
<label for="pd-form-username">{:__('Username')}</label>
|
||||
<div class="login-control">
|
||||
<input type="text" class="form-control" id="pd-form-username" placeholder="{:__('Username')}" name="username" autocomplete="username" value="" data-rule="{:__('Username')}:required;username"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="login-field">
|
||||
<label for="pd-form-password">{:__('Password')}</label>
|
||||
<div class="login-control has-toggle">
|
||||
<input type="password" class="form-control" id="pd-form-password" placeholder="{:__('Password')}" name="password" autocomplete="current-password" value="" data-rule="{:__('Password')}:required;password"/>
|
||||
<button type="button" class="field-toggle" id="toggle-password" aria-label="{:__('Show password')}" aria-pressed="false" aria-controls="pd-form-password" data-show="{:__('Show password')}" data-hide="{:__('Hide password')}">
|
||||
<span class="icon-on" aria-hidden="true">
|
||||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.7">
|
||||
<path d="M2 12s3.5-7 10-7 10 7 10 7-3.5 7-10 7S2 12 2 12Z"/>
|
||||
<circle cx="12" cy="12" r="3"/>
|
||||
</svg>
|
||||
</span>
|
||||
<span class="icon-off" aria-hidden="true">
|
||||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.7">
|
||||
<path d="M3 3l18 18"/>
|
||||
<path d="M10.6 10.6a3 3 0 0 0 4.2 4.2"/>
|
||||
<path d="M9.9 5.1A11 11 0 0 1 12 5c6.5 0 10 7 10 7a17.4 17.4 0 0 1-3.2 4.4"/>
|
||||
<path d="M6.1 6.1C3.8 7.8 2 12 2 12s3.5 7 10 7a10.6 10.6 0 0 0 4.2-.9"/>
|
||||
</svg>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--@CaptchaBegin-->
|
||||
{if $Think.config.fastadmin.login_captcha}
|
||||
<div class="login-field">
|
||||
<label for="pd-form-captcha">{:__('Captcha')}</label>
|
||||
<div class="login-control">
|
||||
<div class="input-group">
|
||||
<input type="text" id="pd-form-captcha" name="captcha" class="form-control" placeholder="{:__('Captcha')}" data-rule="{:__('Captcha')}:required;length({$Think.config.captcha.length|htmlentities})" autocomplete="off"/>
|
||||
<span class="input-group-addon" style="padding:0;border:none;cursor:pointer;">
|
||||
<img src="{:rtrim('__PUBLIC__', '/')}/index.php?s=/captcha" width="108" height="48" alt="{:__('Captcha')}" onclick="this.src = '{:rtrim('__PUBLIC__', '/')}/index.php?s=/captcha&r=' + Math.random();"/>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
<!--@CaptchaEnd-->
|
||||
|
||||
{if $keeyloginhours>0}
|
||||
<div class="form-group checkbox login-keep">
|
||||
<label class="inline" for="keeplogin" data-toggle="tooltip" title="{:__('The duration of the session is %s hours', $keeyloginhours)}">
|
||||
<input type="checkbox" name="keeplogin" id="keeplogin" value="1"/>
|
||||
{:__('Keep login')}
|
||||
</label>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
<div class="form-group">
|
||||
<button type="submit" class="btn btn-success btn-lg btn-block login-submit">{:__('Sign in')}</button>
|
||||
</div>
|
||||
<!--@AdminLoginFormEnd-->
|
||||
</form>
|
||||
<p class="login-note">{$site.name|htmlentities} · {:date('Y')}</p>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
{include file="common/script" /}
|
||||
</body>
|
||||
|
||||
在新工单中引用
屏蔽一个用户