feat: 前端根路径导航首页(web/index.html,6 模块入口 + 推理服务状态)

This commit is contained in:
2026-08-05 13:15:03 +08:00
committed by yunmei
parent ca6637b69e
commit b53e71c85d
+98
View File
@@ -0,0 +1,98 @@
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>iAOP 云美工业AI优化平台</title>
<style>
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
background: linear-gradient(160deg, #0b1526 0%, #111c33 60%, #0d1a2e 100%);
color: #e2e8f0; min-height: 100vh; display: flex; flex-direction: column;
}
header {
padding: 48px 24px 24px; text-align: center;
border-bottom: 1px solid rgba(148,163,184,.15);
}
header h1 { font-size: 28px; color: #34d399; letter-spacing: 1px; }
header p { margin-top: 8px; color: #94a3b8; font-size: 14px; }
main {
flex: 1; max-width: 960px; margin: 0 auto; width: 100%;
padding: 32px 24px;
display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
gap: 16px;
}
a.card {
display: block; text-decoration: none; color: inherit;
background: rgba(148,163,184,.06); border: 1px solid rgba(148,163,184,.18);
border-radius: 12px; padding: 20px; transition: all .2s;
}
a.card:hover { transform: translateY(-2px); border-color: #34d399;
background: rgba(52,211,153,.08); }
.card h2 { font-size: 17px; color: #7dd3fc; margin-bottom: 6px; }
.card p { font-size: 13px; color: #94a3b8; line-height: 1.6; }
.card .tag { display: inline-block; margin-top: 10px; font-size: 11px;
color: #34d399; border: 1px solid rgba(52,211,153,.4); border-radius: 20px;
padding: 2px 10px; }
footer { text-align: center; padding: 24px; color: #64748b; font-size: 12px; }
#health { display: inline-block; margin-left: 10px; font-size: 12px;
color: #fbbf24; border: 1px solid rgba(251,191,36,.4); border-radius: 20px;
padding: 2px 10px; vertical-align: middle; }
</style>
</head>
<body>
<header>
<h1>iAOP 云美工业AI优化平台 <span id="health">推理服务检测中…</span></h1>
<p>iAOP-Core 通用内核 · Template-Ti(海绵钛)一期 · 配置化驾驶舱 / 模板配置台 / LLM 助手</p>
</header>
<main>
<a class="card" href="cockpit/">
<h2>🚀 驾驶舱</h2>
<p>四状态工艺流程视图、实时趋势、KPI 卡片、告警面板、NL 查询(PRD 5.5)</p>
<span class="tag">业务用户 · 只读为主</span>
</a>
<a class="card" href="chat/assistant.html">
<h2>💬 对话助手</h2>
<p>NL 工艺查询 / 报警智能解释 / 交接班报告生成(PRD 5.4)</p>
<span class="tag">值班长 · 工程师</span>
</a>
<a class="card" href="studio/">
<h2>🧩 模板配置台</h2>
<p>点位字典导入 / 模型超参 / RAG 知识库 / 驾驶舱布局编排 / 版本发布(PRD 5.7)</p>
<span class="tag">实施 · 行业工程师</span>
</a>
<a class="card" href="admin/">
<h2>⚙️ 管理控制台</h2>
<p>模型管理(版本/阶段/回滚)、知识库管理、告警确认、审计查询</p>
<span class="tag">管理员</span>
</a>
<a class="card" href="auth/users.html">
<h2>👤 用户与角色</h2>
<p>用户管理、角色分配(readonly / engineer / admin)、审计(PRD 8.2)</p>
<span class="tag">管理员</span>
</a>
<a class="card" href="mobile/">
<h2>📱 移动端</h2>
<p>移动端只读驾驶舱与交接班摘要(iOS14+ / Android 10+)</p>
<span class="tag">移动端 · 值班长</span>
</a>
</main>
<footer>iAOP-Core v1.0 · 部署底座 K8s/Helm · 推理服务 :30800 · 前端 :8090</footer>
<script>
// 推理服务健康检测(直连 NodePort,CORS 已放行)
fetch("http://39.101.182.167:30800/health", { method: "GET" })
.then(function (r) { return r.json(); })
.then(function (d) {
var el = document.getElementById("health");
el.textContent = d.status === "ok" || d.status === "dry-run"
? "● 推理服务在线(" + d.backend + ")" : "推理服务异常";
el.style.color = "#34d399";
})
.catch(function () {
var el = document.getElementById("health");
el.textContent = "推理服务不可达";
});
</script>
</body>
</html>