Remove non-admin workbench
This commit is contained in:
@@ -71,7 +71,7 @@ instance.interceptors.response.use(
|
||||
// 认证相关的错误由具体页面自行处理,避免重复提示
|
||||
return Promise.reject(error);
|
||||
}
|
||||
// 如果当前项目不存在或已失效,清理项目并跳到工作台
|
||||
// 如果当前项目不存在或已失效,清理项目并跳到项目管理页
|
||||
if (status === 404 && typeof data?.message === "string" && data.message.toLowerCase().includes("study")) {
|
||||
try {
|
||||
const studyStore = useStudyStore();
|
||||
@@ -79,7 +79,7 @@ instance.interceptors.response.use(
|
||||
} catch {
|
||||
/* ignore */
|
||||
}
|
||||
router.push("/workbench");
|
||||
router.push("/admin/projects");
|
||||
}
|
||||
if (status === 401) {
|
||||
const config = error.config as ApiRequestConfig;
|
||||
|
||||
Reference in New Issue
Block a user