Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
so-manage-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
smart-operation
so-manage-ui
Commits
6fb24019
Commit
6fb24019
authored
Oct 26, 2022
by
张俊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
菜单调整
parent
e2dd1cbe
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
28 deletions
+29
-28
src/components/bg-menu.vue
src/components/bg-menu.vue
+29
-28
No files found.
src/components/bg-menu.vue
View file @
6fb24019
...
@@ -8,11 +8,9 @@
...
@@ -8,11 +8,9 @@
>
>
<!-- LOGO -->
<!-- LOGO -->
<
router-link
to=
"/"
class=
"bg-logo
"
>
<
div
class=
"bg-logo"
@
click=
"gotoPage
"
>
<img
style=
"width:140px;height:22px;"
src=
"../assets/imgs/img_logo.png"
/>
<img
style=
"width:140px;height:22px;"
src=
"../assets/imgs/img_logo.png"
/>
<!--
<img
style=
"width:40px;height:40px;"
:src=
"logo"
/>
-->
</div>
<!--
<span>
{{
name
}}
</span>
-->
</router-link>
<!-- 菜单 -->
<!-- 菜单 -->
<div
class=
"main-menu"
v-if=
"userInfo&& userInfo.system_id"
>
<div
class=
"main-menu"
v-if=
"userInfo&& userInfo.system_id"
>
...
@@ -49,7 +47,7 @@
...
@@ -49,7 +47,7 @@
<!-- 信息 -->
<!-- 信息 -->
<!-- 购物车 -->
<!-- 购物车 -->
<!-- 用户中心 -->
<!-- 用户中心 -->
<div
class=
"user-center nav-item"
@
click=
"menuAction(systemMenu[0]?systemMenu[0].path:'',systemMenu[0])"
>
<div
class=
"user-center nav-item"
>
<span
class=
"user-icon"
>
<span
class=
"user-icon"
>
<img
style=
"width:24px;height:24px;border-radius:50%;vertical-align:middle;"
v-if=
"userInfo&&userInfo.logo"
:src=
"userInfo&&userInfo.logo"
/>
<img
style=
"width:24px;height:24px;border-radius:50%;vertical-align:middle;"
v-if=
"userInfo&&userInfo.logo"
:src=
"userInfo&&userInfo.logo"
/>
<img
style=
"width:24px;height:24px;border-radius:50%;vertical-align:middle;"
v-else
src=
"../assets/imgs/home_ic_user.png"
/>
<img
style=
"width:24px;height:24px;border-radius:50%;vertical-align:middle;"
v-else
src=
"../assets/imgs/home_ic_user.png"
/>
...
@@ -130,20 +128,20 @@ export default {
...
@@ -130,20 +128,20 @@ export default {
...
mapState
({
...
mapState
({
fontMenu
(
state
)
{
fontMenu
(
state
)
{
let
temp
=
[]
let
temp
=
[]
state
.
menu
.
forEach
(
e
=>
{
//
state.menu.forEach(e => {
if
(
e
.
menuType
==
'
font
'
){
//
if(e.menuType=='font'){
temp
.
push
(
e
)
//
temp.push(e)
}
//
}
});
//
});
return
temp
return
temp
},
},
managerMenu
(
state
){
managerMenu
(
state
){
let
temp
=
[]
let
temp
=
[]
state
.
menu
.
forEach
(
e
=>
{
//
state.menu.forEach(e => {
if
(
e
.
menuType
==
'
system
'
){
//
if(e.menuType=='system'){
temp
.
push
(
e
)
//
temp.push(e)
}
//
}
});
//
});
return
temp
return
temp
},
},
systemMenu
(
state
){
systemMenu
(
state
){
...
@@ -194,13 +192,12 @@ export default {
...
@@ -194,13 +192,12 @@ export default {
// })
// })
},
},
menuAction
(
n
,
parent
)
{
menuAction
(
n
,
parent
)
{
debugger
//不存在则不跳转
//不存在则不跳转
if
(
!
n
){
if
(
!
n
){
return
return
}
}
if
(
n
==
"
logout
"
)
{
if
(
n
==
"
logout
"
)
{
this
.
$axios
.
get
(
`/apaas/system/logout`
).
then
(
res
=>
{
this
.
$axios
.
get
(
`/apaas/system/
v5/user/
logout`
).
then
(
res
=>
{
if
(
res
.
data
.
code
==
'
200
'
){
if
(
res
.
data
.
code
==
'
200
'
){
this
.
$router
.
push
(
'
/login
'
)
this
.
$router
.
push
(
'
/login
'
)
this
.
$store
.
commit
(
'
setUserInfo
'
,
null
)
this
.
$store
.
commit
(
'
setUserInfo
'
,
null
)
...
@@ -249,7 +246,7 @@ export default {
...
@@ -249,7 +246,7 @@ export default {
}
else
{
}
else
{
//判断是否是同区域内跳转
//判断是否是同区域内跳转
//非同区域跳转需要改前缀,如apaas/portal/ui跳转到apaas/manage/ui
//非同区域跳转需要改前缀,如apaas/portal/ui跳转到apaas/manage/ui
if
(
this
.
$store
.
state
.
menuObj
[
this
.
path
]
&&
parent
.
menuType
==
this
.
$store
.
state
.
menuObj
[
this
.
path
].
menuType
){
if
(
this
.
$store
.
state
.
menuObj
[
this
.
path
]
&&
(
parent
.
menuType
==
this
.
$store
.
state
.
menuObj
[
this
.
path
].
menuType
||
([
'
font
'
,
'
system
'
].
includes
(
parent
.
menuType
)
&&
[
'
font
'
,
'
system
'
].
includes
(
this
.
$store
.
state
.
menuObj
[
this
.
path
].
menuType
)))
){
this
.
$router
.
push
(
path
);
this
.
$router
.
push
(
path
);
}
else
{
}
else
{
let
temp
=
''
let
temp
=
''
...
@@ -258,10 +255,13 @@ export default {
...
@@ -258,10 +255,13 @@ export default {
}
else
if
(
this
.
$store
.
state
.
menuObj
[
path
].
menuType
==
'
manager
'
){
}
else
if
(
this
.
$store
.
state
.
menuObj
[
path
].
menuType
==
'
manager
'
){
temp
=
'
/apaas/manage/ui/#
'
temp
=
'
/apaas/manage/ui/#
'
}
}
window
.
location
.
href
=
temp
+
path
window
.
open
(
temp
+
path
)
}
}
}
}
},
},
gotoPage
(){
window
.
open
(
`/apaas/portal/ui/#/`
)
},
intoCartDetail
()
{
intoCartDetail
()
{
this
.
$router
.
push
({
name
:
"
shopCart
"
});
this
.
$router
.
push
({
name
:
"
shopCart
"
});
},
},
...
@@ -458,6 +458,7 @@ export default {
...
@@ -458,6 +458,7 @@ export default {
line-height
:
1
;
line-height
:
1
;
margin
:
0
50px
0
20px
;
margin
:
0
50px
0
20px
;
text-decoration
:
none
;
text-decoration
:
none
;
cursor
:
pointer
;
>
span
{
>
span
{
font-size
:
24px
;
font-size
:
24px
;
...
@@ -652,15 +653,15 @@ export default {
...
@@ -652,15 +653,15 @@ export default {
padding-left
:
32px
;
padding-left
:
32px
;
position
:
inherit
;
position
:
inherit
;
&
:
:
before
{
//
&::before{
content
:
''
;
//
content:'';
width
:
1px
;
//
width: 1px;
height
:
24px
;
//
height: 24px;
background-color
:
#5c6da4
;
//
background-color: #5c6da4;
position
:
absolute
;
//
position: absolute;
left
:
0
;
//
left: 0;
top
:
16px
;
//
top: 16px;
}
//
}
}
}
// 用户中心
// 用户中心
.user-center
{
.user-center
{
...
...
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