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