更新
This commit is contained in:
@@ -207,11 +207,12 @@ export default {
|
||||
});
|
||||
},
|
||||
callbackLogin(res) {
|
||||
let { authTokenDTO, isCompanyAccount } = res.data;
|
||||
let { authTokenDTO } = res.data;
|
||||
if (authTokenDTO.loginFlag) {
|
||||
uni.setStorageSync("Authorization", authTokenDTO.accessToken);
|
||||
uni.setStorageSync("accountStatus", isCompanyAccount);
|
||||
// uni.setStorageSync("accountStatus", isCompanyAccount);
|
||||
uni.setStorageSync("user", authTokenDTO.loginUser);
|
||||
// console.log()
|
||||
uni.reLaunch({
|
||||
url: "/pages/index/index",
|
||||
});
|
||||
|
||||
@@ -153,7 +153,6 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
discountInfo: {},
|
||||
params: {
|
||||
sitePriceAmount: "",
|
||||
oilProductCode: "",
|
||||
@@ -161,10 +160,12 @@ export default {
|
||||
sitePrice: "",
|
||||
oilSitePrice: "",
|
||||
},
|
||||
discountInfo: {},
|
||||
siteInfo: {},
|
||||
handleInfo: {
|
||||
number: [],
|
||||
spear: {},
|
||||
currentSpear: [],
|
||||
},
|
||||
};
|
||||
},
|
||||
@@ -455,26 +456,7 @@ export default {
|
||||
font-weight: 500;
|
||||
}
|
||||
}
|
||||
// .illustrate {
|
||||
// min-height: 30vh;
|
||||
// > .title {
|
||||
// position: relative;
|
||||
// padding: 30rpx 0;
|
||||
// text-align: center;
|
||||
// > uni-icons {
|
||||
// position: absolute;
|
||||
// top: 50%;
|
||||
// right: 30rpx;
|
||||
// transform: translateY(-50%);
|
||||
// }
|
||||
// }
|
||||
// > .text {
|
||||
// padding: 0 20rpx;
|
||||
// text-align: center;
|
||||
// font-size: 28rpx;
|
||||
// color: #999;
|
||||
// }
|
||||
// }
|
||||
|
||||
.container {
|
||||
min-height: 100vh;
|
||||
background: #f6f6f6;
|
||||
|
||||
@@ -15,10 +15,6 @@ const instance = axios.create({
|
||||
timeout: 10000,
|
||||
});
|
||||
|
||||
let token = "";
|
||||
let unionId = "";
|
||||
let openId = "";
|
||||
|
||||
instance.interceptors.request.use(
|
||||
(config) => {
|
||||
if (!config.hideLoading) {
|
||||
@@ -27,15 +23,9 @@ instance.interceptors.request.use(
|
||||
});
|
||||
}
|
||||
|
||||
if (!token) {
|
||||
token = uni.getStorageSync("Authorization") || " ";
|
||||
}
|
||||
if (!unionId) {
|
||||
unionId = uni.getStorageSync("unionid");
|
||||
}
|
||||
if (!openId) {
|
||||
openId = uni.getStorageSync("openid");
|
||||
}
|
||||
const token = uni.getStorageSync("Authorization") || " ";
|
||||
const unionId = uni.getStorageSync("unionid");
|
||||
const openId = uni.getStorageSync("openid");
|
||||
|
||||
config.headers["Authorization"] = token;
|
||||
config.headers["imei"] = unionId;
|
||||
|
||||
Reference in New Issue
Block a user