1
0
Code Issues Pull Requests Packages Projects Releases Wiki Activity GitHub Gitee

用户管理增删改查全部完成

This commit is contained in:
2023-03-29 17:24:27 +08:00
parent cf962a92da
commit 14907e3e26
24 changed files with 775 additions and 252 deletions

View File

@@ -34,20 +34,7 @@ async function send_request({ url, method = "POST", params, useQS = false, callb
let result = response.data;
// 判断后端是否处理成功
if (!result.success) {
// 用户未登录情况
// if (result.data && result.data.errCode == 20003) {
// ElMessage.error(result?.data?.msg || "用户未登录");
// localStorage.clear();
// // window.location.reload();
// // 如果同时发出多个请求可能会多次进来第二次及之后进入时hash已经变成 #/login 了
// if (!window.location.hash.includes("/login")) {
// let newUrl = '/#/login?redirectTo=' + encodeURIComponent(window.location.hash.substring(1).split('?')[0])
// console.log("newUrl", newUrl)
// window.location.href = newUrl;
// }
// } else {
ElMessage.error(result?.data?.msg || "服务器错误");
// }
ElMessage.error(result?.msg || "服务器错误");
return null;
}
let data = result.data;