优化
This commit is contained in:
parent
b57f31ad5e
commit
257c2d51ef
@ -1,9 +1,9 @@
|
||||
<template>
|
||||
<div id="app">
|
||||
<router-view class="main"/>
|
||||
<!-- <div v-if="dd.pc" class="pc commonFont">
|
||||
<div v-if="!dd.pc && !dd.other" class="pc commonFont">
|
||||
请移步PC端操作
|
||||
</div> -->
|
||||
</div>
|
||||
<router-view v-else class="main"/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@ -1,20 +1,21 @@
|
||||
import { getDepList } from '@/api/report'
|
||||
import { apiUserInfo } from '@/api/login'
|
||||
import * as dd from 'dingtalk-jsapi'
|
||||
const user = {
|
||||
state: {
|
||||
deplist: [],
|
||||
info: {},
|
||||
info: dd.other ? JSON.parse(localStorage.getItem('info')) : {},
|
||||
auth: JSON.parse(localStorage.getItem('auth')) || {}
|
||||
|
||||
},
|
||||
mutations: {
|
||||
SET_USER_INFO: (state, info) => {
|
||||
localStorage.setItem('info', JSON.stringify(info))
|
||||
dd.other && localStorage.setItem('info', JSON.stringify(info))
|
||||
state.info = info
|
||||
console.log('state.info: ', state.info)
|
||||
},
|
||||
SET_USER_AUTH: (state, auth) => {
|
||||
localStorage.setItem('auth', JSON.stringify(auth))
|
||||
dd.other && localStorage.setItem('auth', JSON.stringify(auth))
|
||||
state.auth = auth
|
||||
console.log('state.auth: ', state.auth)
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user