forked from admin/struts2-demo
feat: expand struts demo lab
This commit is contained in:
@@ -1,44 +1,111 @@
|
||||
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
|
||||
<%@ taglib prefix="s" uri="/struts-tags" %>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>登录成功 - Struts2 Demo</title>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Success Dashboard - Struts2 Demo Lab</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: 'Segoe UI', sans-serif;
|
||||
background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
|
||||
body {
|
||||
margin: 0;
|
||||
min-height: 100vh;
|
||||
padding: 24px;
|
||||
font-family: "Aptos", "Segoe UI", "Microsoft YaHei", sans-serif;
|
||||
background: linear-gradient(135deg, #0d8f7c 0%, #31c48d 55%, #d4f7e7 100%);
|
||||
color: #123028;
|
||||
}
|
||||
.shell {
|
||||
max-width: 1080px;
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex-direction: column;
|
||||
gap: 18px;
|
||||
}
|
||||
.card {
|
||||
background: white;
|
||||
padding: 40px;
|
||||
border-radius: 15px;
|
||||
text-align: center;
|
||||
box-shadow: 0 15px 50px rgba(0,0,0,0.3);
|
||||
background: rgba(255,255,255,0.94);
|
||||
border-radius: 28px;
|
||||
padding: 28px;
|
||||
box-shadow: 0 24px 60px rgba(0,0,0,0.18);
|
||||
}
|
||||
h1 { color: #11998e; font-size: 3em; margin-bottom: 20px; }
|
||||
p { color: #666; font-size: 1.2em; margin-bottom: 30px; }
|
||||
.btn {
|
||||
display: inline-block;
|
||||
padding: 12px 30px;
|
||||
background: #11998e;
|
||||
color: white;
|
||||
.eyebrow {
|
||||
font-size: 12px;
|
||||
letter-spacing: 0.12em;
|
||||
text-transform: uppercase;
|
||||
color: #0d8f7c;
|
||||
font-weight: 800;
|
||||
}
|
||||
h1, h2 { margin: 10px 0 12px; }
|
||||
p { margin: 0; color: #446056; line-height: 1.85; }
|
||||
.stats {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, minmax(0, 1fr));
|
||||
gap: 12px;
|
||||
margin-top: 18px;
|
||||
}
|
||||
.stat {
|
||||
padding: 16px;
|
||||
border-radius: 18px;
|
||||
border: 1px solid #d7eee6;
|
||||
background: #f7fcfa;
|
||||
}
|
||||
.stat span { display: block; color: #5f7f75; font-size: 12px; margin-bottom: 6px; }
|
||||
.stat strong { font-size: 22px; }
|
||||
.links {
|
||||
display: flex;
|
||||
gap: 10px;
|
||||
flex-wrap: wrap;
|
||||
margin-top: 18px;
|
||||
}
|
||||
.link-btn {
|
||||
display: inline-flex;
|
||||
padding: 10px 14px;
|
||||
border-radius: 999px;
|
||||
background: #e8f8f2;
|
||||
color: #0d8f7c;
|
||||
text-decoration: none;
|
||||
border-radius: 25px;
|
||||
transition: transform 0.3s;
|
||||
font-weight: 700;
|
||||
}
|
||||
@media (max-width: 760px) {
|
||||
.stats { grid-template-columns: 1fr; }
|
||||
}
|
||||
.btn:hover { transform: scale(1.05); }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="card">
|
||||
<h1>✅ 登录成功!</h1>
|
||||
<p>欢迎回来,<s:property value="username"/>!</p>
|
||||
<a href="../index.jsp" class="btn">返回首页</a>
|
||||
<div class="shell">
|
||||
<section class="card">
|
||||
<div class="eyebrow">Result</div>
|
||||
<h1>Demo flow completed successfully</h1>
|
||||
<p>This page now acts as a shared success dashboard for multiple form-based actions. It makes the result screen more useful than a single success line.</p>
|
||||
</section>
|
||||
|
||||
<section class="card">
|
||||
<div class="eyebrow">Current submission</div>
|
||||
<h2><s:property value="displayName != null ? displayName : username"/></h2>
|
||||
<p><s:property value="recommendation != null ? recommendation : profileStage"/></p>
|
||||
|
||||
<div class="stats">
|
||||
<div class="stat">
|
||||
<span>Username</span>
|
||||
<strong><s:property value="username" default="demo-user"/></strong>
|
||||
</div>
|
||||
<div class="stat">
|
||||
<span>Role or stage</span>
|
||||
<strong><s:property value="role != null ? role : profileStage"/></strong>
|
||||
</div>
|
||||
<div class="stat">
|
||||
<span>Timestamp</span>
|
||||
<strong><s:property value="loginTime != null ? loginTime : submittedAt"/></strong>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="links">
|
||||
<a class="link-btn" href="../index.jsp">Back to portal</a>
|
||||
<a class="link-btn" href="form.jsp">Open user form</a>
|
||||
<a class="link-btn" href="../validation/form.jsp">Run validation demo</a>
|
||||
<a class="link-btn" href="../upload/index.jsp">Open upload demo</a>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user