| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191 |
- <!DOCTYPE html>
- <html lang="zh-CN">
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>登录 - 展厅控制</title>
- <style>
- :root {
- --primary-color: #4ecdc4;
- --secondary-color: #ff6b6b;
- --accent-color: #feca57;
- --dark-text: #333;
- --light-text: #fff;
- --bg-gradient: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
- --card-bg: #ffffff;
- }
- * {
- margin: 0;
- padding: 0;
- box-sizing: border-box;
- }
- body {
- font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
- background: var(--bg-gradient);
- min-height: 100vh;
- display: flex;
- align-items: center;
- justify-content: center;
- color: var(--dark-text);
- }
- .login-container {
- background: var(--card-bg);
- border-radius: 15px;
- padding: 40px;
- width: 100%;
- max-width: 400px;
- box-shadow: 0 10px 25px rgba(0,0,0,0.1);
- animation: fadeIn 0.5s ease-out;
- }
- @keyframes fadeIn {
- from { opacity: 0; transform: translateY(-20px); }
- to { opacity: 1; transform: translateY(0); }
- }
- .header {
- text-align: center;
- margin-bottom: 30px;
- }
- .header h1 {
- color: #2c3e50;
- font-size: 24px;
- margin-bottom: 10px;
- }
- .header p {
- color: #7f8c8d;
- font-size: 14px;
- }
- .form-group {
- margin-bottom: 20px;
- }
- label {
- display: block;
- margin-bottom: 8px;
- color: #555;
- font-weight: 600;
- font-size: 14px;
- }
- input {
- width: 100%;
- padding: 12px;
- border: 1px solid #ddd;
- border-radius: 8px;
- font-size: 15px;
- transition: border-color 0.3s;
- }
- input:focus {
- border-color: var(--primary-color);
- outline: none;
- }
- .btn-submit {
- width: 100%;
- padding: 12px;
- background-color: var(--primary-color);
- color: white;
- border: none;
- border-radius: 8px;
- font-size: 16px;
- font-weight: 600;
- cursor: pointer;
- transition: background-color 0.3s, transform 0.1s;
- }
- .btn-submit:hover {
- background-color: #3dbdb4;
- }
- .btn-submit:active {
- transform: translateY(1px);
- }
- .alert {
- padding: 12px;
- border-radius: 8px;
- margin-bottom: 20px;
- font-size: 14px;
- text-align: center;
- }
- .alert-error {
- background-color: #ffebee;
- color: #c62828;
- border: 1px solid #ffcdd2;
- }
- .sso-divider {
- margin: 20px 0;
- text-align: center;
- color: #95a5a6;
- font-size: 14px;
- }
- .btn-sso {
- display: block;
- width: 100%;
- padding: 12px;
- margin-top: 10px;
- background-color: #3498db;
- color: white;
- text-align: center;
- text-decoration: none;
- border-radius: 8px;
- font-size: 16px;
- font-weight: 600;
- transition: background-color 0.3s;
- }
- .btn-sso:hover {
- background-color: #2980b9;
- }
- </style>
- </head>
- <body>
- <div class="login-container">
- <div class="header">
- <h1>展厅控制系统</h1>
- <p>请登录以继续</p>
- </div>
-
- {% with messages = get_flashed_messages(with_categories=true) %}
- {% if messages %}
- {% for category, message in messages %}
- <div class="alert alert-{{ category }}">
- {{ message }}
- </div>
- {% endfor %}
- {% endif %}
- {% endwith %}
- <form method="POST" action="/login">
- <div class="form-group">
- <label for="username">账号</label>
- <input type="text" id="username" name="username" placeholder="请输入账号" required autofocus>
- </div>
-
- <div class="form-group">
- <label for="password">密码</label>
- <input type="password" id="password" name="password" placeholder="请输入密码" required>
- </div>
-
- <button type="submit" class="btn-submit">登录</button>
-
- <div class="sso-divider">
- <span>或</span>
- </div>
- <a href="/login/sso" class="btn-sso">统一登录</a>
- </form>
- </div>
- </body>
- </html>
|