Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mocp-uniapp
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pangchong
mocp-uniapp
Commits
260b15d3
Commit
260b15d3
authored
May 21, 2024
by
pangchong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 修改登录信息
parent
3dd242bb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
src/store/user.js
+3
-3
No files found.
src/store/user.js
View file @
260b15d3
...
...
@@ -21,7 +21,7 @@ const useUserStore = defineStore('user', {
state
:
()
=>
{
return
{
token
:
''
,
user
_i
nfo
:
undefined
,
user
I
nfo
:
undefined
,
menuList
:
cloneDeep
(
menuList
),
homeMenuList
:
cloneDeep
(
menuList
),
allMenuItem
:
{
id
:
999
,
name
:
'全部菜单'
,
icon
:
'all'
,
group
:
''
,
count
:
0
}
...
...
@@ -45,14 +45,14 @@ const useUserStore = defineStore('user', {
//用户登录
setUserInfo
(
data
)
{
this
.
token
=
data
.
token
this
.
user
_i
nfo
=
data
this
.
user
I
nfo
=
data
//跳转工作台
uni
.
switchTab
({
url
:
'/pages/panel/index'
})
},
//退出登录
handleLogOut
()
{
this
.
token
=
''
this
.
user
_i
nfo
=
undefined
this
.
user
I
nfo
=
undefined
//返回登录页面
uni
.
redirectTo
({
url
:
'/pages/login/index'
})
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment