fix
This commit is contained in:
parent
887c9087f1
commit
0266ad8e99
@ -121,7 +121,8 @@ onLoad((options) => {
|
||||
state.id = options.id;
|
||||
state.pid = options.pid;
|
||||
const token =
|
||||
window?.plus?.storage.getItem("token") || uni.getStorageSync("token");
|
||||
window?.plus?.storage.getItem("token") ||
|
||||
uni.getStorageSync("store-token");
|
||||
console.log("token", token);
|
||||
// 已经登录了
|
||||
if (token) {
|
||||
@ -236,7 +237,7 @@ const logining = async () => {
|
||||
code: state.code ?? "",
|
||||
});
|
||||
if (res.status === 0) {
|
||||
uni.setStorageSync("token", res.data.Token);
|
||||
uni.setStorageSync("store-token", res.data.Token);
|
||||
uni.setStorageSync("userInfo", res.data.AccountInfo);
|
||||
await paintingDetail();
|
||||
await getBtngetRules();
|
||||
|
@ -19,7 +19,7 @@ const request = new Request({
|
||||
|
||||
const token =
|
||||
window?.plus?.storage.getItem("token") ||
|
||||
uni.getStorageSync("token") ||
|
||||
uni.getStorageSync("store-token") ||
|
||||
"";
|
||||
if (config.isFormData) {
|
||||
config.headers["Content-Type"] = "multipart/form-data";
|
||||
|
Loading…
Reference in New Issue
Block a user