checkpoint: 重写 langchain agent 前的快照

包含未合入 main 的工作:
- CAS 单点登录接入 (CasSecurityConfig + 4 个 CAS 类)
- LoginController 改 POST + body, 修 URL 密码暴露
- chat_test.py 修 texts→text typo
- 前端外部系统侧边栏 + login API POST
- gateway-nginx.conf

下一步: 从这个分支拉 feat/langgraph-rewrite 做 langchain-chat agent 重写
回滚点: git checkout backup/pre-langgraph

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-07 14:58:53 +08:00
parent f8e8017434
commit 911f7adee6
17 changed files with 647 additions and 10 deletions

View File

@@ -8,9 +8,9 @@ export function fetchChatConfig<T>() {
})
}
// 登录
// 登录POST + body避免密码出现在 URL/access log
export function fetchVerify<T>(data: object) {
return get<T>({
return post<T>({
url: '/app/api/oauth/token',
data,
})

View File

@@ -56,6 +56,14 @@
{{ loginTip }}
</el-button>
</el-form-item>
<el-form-item>
<el-button
style="width: 100%; background: #FF2500; color: #fff; border-color: #FF2500;"
@click="goCasLogin"
>
通过统一身份登录
</el-button>
</el-form-item>
</el-form>
</div>
</div>
@@ -139,6 +147,22 @@ const handleVerify = async () => {
}
};
// 跳后端 CAS 入口;后端 302 跳 CAS 服务器
const goCasLogin = () => {
window.location.href = `/chat_web_backend/cas/login`;
};
// 处理 CAS 回调URL 含 cas_token 参数 → 存 token 后跳首页
onMounted(() => {
const params = new URLSearchParams(window.location.search);
const casToken = params.get("cas_token");
if (casToken) {
authStore.setToken(casToken);
window.history.replaceState({}, document.title, window.location.pathname + window.location.hash.split("?")[0]);
router.push("/chat");
}
});
</script>
<style scoped lang="scss">
.loginPage {