mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-16 01:46:45 +08:00
首页白屏问题处理: 添加token处理 --提交人:阳华祥
This commit is contained in:
@@ -162,6 +162,7 @@ service.interceptors.request.use(
|
||||
// token 不存在初始化处理
|
||||
let token = CacheUtils.getLocItem('token')
|
||||
if (!token) {
|
||||
console.log('token====>>', token)
|
||||
// 设备类型
|
||||
const target = BusinessCommon.device()
|
||||
// 安卓or苹果(非浏览器)
|
||||
|
||||
@@ -135,6 +135,7 @@ import { getAgentInfo } from '@/api/ebiz/my/my'
|
||||
import { getCongratulationList } from '@/api/ebiz/congratulation/congratulation.js'
|
||||
import dateUtil from '@/assets/js/utils/date-utils.js'
|
||||
import { orgShortNames } from '@/assets/js/utils/orgShortName'
|
||||
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||
export default {
|
||||
components: {
|
||||
[Loading.name]: Loading
|
||||
@@ -163,6 +164,10 @@ export default {
|
||||
}
|
||||
},
|
||||
async created() {
|
||||
let arr = window.location.href.split('?token=')
|
||||
if (arr.length > 1) {
|
||||
CacheUtils.setLocItem('token', arr[1])
|
||||
}
|
||||
await this.getAgentInfo()
|
||||
if (this.isGoodStart) {
|
||||
await this.getTableData()
|
||||
|
||||
Reference in New Issue
Block a user