refactor: store 目录扁平化重构为 stores(Pinia 推荐结构)

This commit is contained in:
Ray.Hao
2026-04-20 13:53:10 +08:00
parent f669e6951b
commit 33bde0eaf8
46 changed files with 71 additions and 72 deletions

View File

@@ -1,6 +1,6 @@
import { Storage } from "./storage";
import { STORAGE_KEYS, ROLE_ROOT } from "@/constants";
import { useUserStoreHook } from "@/store/modules/user";
import { useUserStoreHook } from "@/stores/user";
import router from "@/router";
// 负责本地凭证与偏好的读写

View File

@@ -1,8 +1,8 @@
import axios, { type InternalAxiosRequestConfig, type AxiosResponse } from "axios";
import qs from "qs";
import { ApiCodeEnum } from "@/enums/api";
import { useUserStoreHook } from "@/store/modules/user";
import { usePermissionStoreHook } from "@/store/modules/permission";
import { useUserStoreHook } from "@/stores/user";
import { usePermissionStoreHook } from "@/stores/permission";
import { AuthStorage, redirectToLogin } from "@/utils/auth";
// 记录已重试的请求,防止无限循环