Commit 63d48d0b by jianan

fix(cffp): 游客首页改为零身份初始化

parent edc5e8e9
......@@ -531,28 +531,15 @@
]
uni.removeTabBarBadge({ index: 3 });
// api.loginVerification({
// "loginType": 1,
// }).then((res) => {
// if (res['success']) {
// this.userId = String(res['data']['userId']);
// uni.setStorageSync('isLogin', '1');
// uni.setStorageSync('cffp_userId', this.userId);
// uni.setStorageSync('loginType', 'visitor');
// uni.setStorageSync('uni-token', res.data['token']);
// } else {
// uni.showToast({
// title: res['message'],
// duration: 2000,
// icon: 'none'
// })
// }
// })
// 游客没有用户身份,直接读取公共首页内容。
this.userId = '';
uni.removeStorageSync('isLogin');
uni.removeStorageSync('cffp_userId');
uni.setStorageSync('loginType', 'visitor');
this.courseList();
this.getOneProduct()
this.getOneProduct();
this.initShare();
this.queryAreaCenterInfo()
this.queryAreaCenterInfo();
}
},
querySystemMessage() {
......@@ -738,7 +725,7 @@
// 获取轮播图
queryAreaCenterInfo() {
api.queryAreaCenterInfo({
// userId: uni.getStorageSync('cffp_userId'),
userId: uni.getStorageSync('cffp_userId'),
companyType: `${companyInfo.companyType}`
}).then((res) => {
if (res['success']) {
......
......@@ -111,6 +111,8 @@ const whiteApiList = [`${apiURL}/authorize/obtainToken`,
`${apiURL}/verificationCode`,
`${sfpUrl}/sfp/sfpMain/pocessTracking`,
`${cffpURL}/partner/queryById`,
`${cffpURL}/course/list`,
`${cffpURL}/areaCenter/queryAreaCenterInfo`,
`${apiURL}/sso/ticket/consume`, // Casdoor 票据消费:匿名,唯一凭据是 ticket
];
// ==================== token 获取 & 整页刷新 控制 ====================
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment