chore: 针对的并非框架

This commit is contained in:
手瓜一十雪
2024-08-10 17:45:17 +08:00
parent 80d2218aa6
commit 6371d79d33
9 changed files with 18 additions and 12 deletions

View File

@@ -9,7 +9,7 @@
<body>
<script>
async function CheckQQLoginStatus(retCredential) {
async function CheckQQLoginStatus(retCredential) {
let QQLoginResponse = await fetch('../api/QQLogin/CheckLoginStatus', {
method: 'POST',
headers: {
@@ -46,6 +46,12 @@
return false;
}
async function InitPage() {
//查找URL参数是否有token
let url = new URL(window.location.href);
let token = url.searchParams.get("token");
if (token) {
localStorage.setItem('auth', token);
}
let authData = localStorage.getItem('auth');
let isLogined = await CheckWebUiLogined(authData);
if (authData && isLogined) {