feat: 优化登录逻辑
This commit is contained in:
@@ -1,16 +1,14 @@
|
||||
import { removeAccessToken } from "@/constant/token";
|
||||
import request from "../base/request";
|
||||
|
||||
const wxLogin = (args) => {
|
||||
const oauthToken = (args) => {
|
||||
const config = {
|
||||
header: {
|
||||
Authorization: "Basic Y3VzdG9tOmN1c3RvbQ==", // 可在此动态设置 token
|
||||
"Content-Type": "application/x-www-form-urlencoded",
|
||||
},
|
||||
};
|
||||
|
||||
removeAccessToken();
|
||||
|
||||
return request.post("/auth/oauth2/token", args, config);
|
||||
};
|
||||
|
||||
@@ -40,7 +38,7 @@ const getPrivacyAgreement = (args) => {
|
||||
};
|
||||
|
||||
export {
|
||||
wxLogin,
|
||||
oauthToken,
|
||||
bindUserPhone,
|
||||
checkUserPhone,
|
||||
getLoginUserPhone,
|
||||
|
||||
Reference in New Issue
Block a user