Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
apaas-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
gzga-jzapi
apaas-ui
Commits
9b47d054
Commit
9b47d054
authored
May 18, 2020
by
徐一鸣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新首页
parent
5158a48b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
113 additions
and
27 deletions
+113
-27
src/components/menu.vue
src/components/menu.vue
+112
-26
src/router/index.js
src/router/index.js
+1
-1
No files found.
src/components/menu.vue
View file @
9b47d054
<
template
>
<
template
>
<div
class=
"menu"
>
<div
class=
"menu"
>
<img
src=
"../assets/imgs/home_img_logo.png"
alt
class=
"logo"
/>
<img
src=
"../assets/imgs/home_img_logo.png"
alt
class=
"logo"
/>
<div
style=
"float:right;cursor: pointer;position:relative;"
class=
"user_hover"
>
<div
style=
"float:right;cursor: pointer;position:relative;"
class=
"user_hover"
>
<span
class=
"user"
>
用户
</span>
<span
class=
"user"
>
用户
</span>
<img
src=
"../assets/imgs/home_ic_user.png"
alt
class=
"user_pic"
/>
<img
src=
"../assets/imgs/home_ic_user.png"
alt
class=
"user_pic"
/>
<div
class=
"user_menu"
>
<div
class=
"user_menu"
>
<div
v-for=
"(item,index) in user_arr"
:key=
"index+700"
@
click=
"gotopage(index)"
>
{{
item
}}
</div>
<div
v-for=
"(item, index) in user_arr"
:key=
"index + 700"
@
click=
"gotopage(index)"
>
{{
item
}}
</div>
</div>
</div>
<div
class=
"sj"
></div>
<div
class=
"sj"
></div>
</div>
</div>
<div
style=
"float:right;cursor: pointer;position:relative;"
class=
"shop_hover"
>
<div
style=
"float:right;cursor: pointer;position:relative;"
class=
"shop_hover"
>
<div
class=
"number"
>
99+
</div>
<div
class=
"number"
>
99+
</div>
<img
src=
"../assets/imgs/home_ic_shop.png"
alt
class=
"car"
/>
<img
src=
"../assets/imgs/home_ic_shop.png"
alt
class=
"car"
/>
<div
class=
"shop_menu"
>
<div
class=
"shop_menu"
>
<div
class=
"shop_list_title"
>
最近加入的服务:
</div>
<div
class=
"shop_list_title"
>
最近加入的服务:
</div>
<div
<div
v-for=
"(item,index) in shopping_list"
v-for=
"(item,
index) in shopping_list"
:key=
"'shopping' + index"
:key=
"'shopping' + index"
class=
"shop_list_cell shop_line"
class=
"shop_list_cell shop_line"
>
>
...
@@ -24,16 +36,24 @@
...
@@ -24,16 +36,24 @@
class=
"shop_img"
class=
"shop_img"
/>
/>
<div
class=
"shop_cell_msgs"
>
<div
class=
"shop_cell_msgs"
>
<p
@
click=
"getDetail(item.id)"
class=
"shop_cell_name over_one"
>
{{
item
.
name
}}
</p>
<p
@
click=
"getDetail(item.id)"
class=
"shop_cell_name over_one"
>
{{
item
.
name
}}
</p>
<p
class=
"shop_cell_msg bover_one"
>
{{
item
.
type
}}
</p>
<p
class=
"shop_cell_msg bover_one"
>
{{
item
.
type
}}
</p>
<p
class=
"shop_cell_msg over_one"
>
{{
item
.
creator
}}
</p>
<p
class=
"shop_cell_msg over_one"
>
{{
item
.
creator
}}
</p>
</div>
</div>
<div>
<div>
<img
@
click=
"deleteItem(item.id)"
src=
"../assets/imgs/ic_delete.png"
alt
/>
<img
@
click=
"deleteItem(item.id)"
src=
"../assets/imgs/ic_delete.png"
alt
/>
</div>
</div>
</div>
</div>
<div
class=
"shop_footer"
>
<div
class=
"shop_footer"
>
<el-button
@
click=
"settlement"
size=
"small"
class=
"shop_settlement"
>
去购物车申请结算
</el-button>
<el-button
@
click=
"settlement"
size=
"small"
class=
"shop_settlement"
>
去购物车申请结算
</el-button>
</div>
</div>
</div>
</div>
<div
class=
"shop_sj"
></div>
<div
class=
"shop_sj"
></div>
...
@@ -41,14 +61,32 @@
...
@@ -41,14 +61,32 @@
<div
style=
"float:right"
>
<div
style=
"float:right"
>
<div
<div
v-for=
"(item,index) in menu_arr"
v-for=
"(item,
index) in menu_arr"
:key=
"index
+
200"
:key=
"index
+
200"
class=
"menu_box"
class=
"menu_box
user_hover
"
@
click=
"now_menu = index"
@
click=
"now_menu = index"
:style=
"
now_menu==index?
{color:'#fff'}:{
}"
:style=
"
{ color: now_menu == index ? '#fff' : ''
}"
>
>
{{
item
}}
{{
item
.
name
}}
<div
class=
"bottom_show"
v-if=
"now_menu==index"
></div>
<div
class=
"user_menu"
v-if=
"item.children && item.children.length"
style=
"left: 30px;"
>
<div
v-for=
"(v, index) in item.children"
:key=
"index + 700"
@
click=
"gotoChildPage(v)"
>
{{
v
.
name
}}
</div>
</div>
<div
class=
"sj"
v-if=
"item.children && item.children.length"
style=
"left: 60px;"
></div>
<div
class=
"bottom_show"
v-if=
"now_menu == index"
></div>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -58,14 +96,57 @@
...
@@ -58,14 +96,57 @@
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
menu_arr
:
[
"
工作台
"
,
"
技术支持
"
,
"
服务超市
"
],
menu_arr
:
[
now_menu
:
0
,
{
name
:
"
工作台
"
,
path
:
"
/workplace
"
,
},
{
name
:
"
技术支持
"
,
path
:
""
,
},
{
name
:
"
服务超市
"
,
path
:
"
/services_shop
"
,
children
:
[
{
name
:
"
数据服务
"
,
path
:
"
/shop/data_service_list
"
,
},
{
name
:
"
时空服务
"
,
path
:
"
/shop/space_time_service_list
"
,
},
{
name
:
"
视频服务
"
,
path
:
"
/shop/video_service_list
"
,
},
{
name
:
"
感知服务
"
,
path
:
"
/shop/perception_service_list
"
,
},
{
name
:
"
综合应用
"
,
path
:
"
/shop/comprehensive_app_list
"
,
},
{
name
:
"
云资源服务
"
,
path
:
"
/shop/cloud
"
,
},
{
name
:
"
应用商店
"
,
path
:
"
/shop/app_store_list
"
,
},
],
},
],
now_menu
:
2
,
user_arr
:
[
user_arr
:
[
"
个人档案
"
,
"
个人档案
"
,
"
消息通知
"
,
"
消息通知
"
,
"
收银中心
"
,
"
收银中心
"
,
"
关于BD-aPaaS
"
,
"
关于BD-aPaaS
"
,
"
退出登录
"
"
退出登录
"
,
],
],
shopping_list
:
[
shopping_list
:
[
{
{
...
@@ -78,7 +159,7 @@ export default {
...
@@ -78,7 +159,7 @@ export default {
num
:
2
,
num
:
2
,
checkedSubscription
:
false
,
checkedSubscription
:
false
,
specification
:
1
,
specification
:
1
,
specificationApplication
:
2
specificationApplication
:
2
,
},
},
{
{
id
:
1
,
id
:
1
,
...
@@ -89,7 +170,7 @@ export default {
...
@@ -89,7 +170,7 @@ export default {
num
:
2
,
num
:
2
,
checkedSubscription
:
false
,
checkedSubscription
:
false
,
specification
:
1
,
specification
:
1
,
specificationApplication
:
2
specificationApplication
:
2
,
},
},
{
{
id
:
2
,
id
:
2
,
...
@@ -101,9 +182,9 @@ export default {
...
@@ -101,9 +182,9 @@ export default {
num
:
2
,
num
:
2
,
checkedSubscription
:
true
,
checkedSubscription
:
true
,
specification
:
1
,
specification
:
1
,
specificationApplication
:
2
specificationApplication
:
2
,
}
}
,
]
]
,
};
};
},
},
methods
:
{
methods
:
{
...
@@ -111,13 +192,18 @@ export default {
...
@@ -111,13 +192,18 @@ export default {
console
.
log
(
n
);
console
.
log
(
n
);
},
},
settlement
()
{
settlement
()
{
this
.
$router
.
push
({
name
:
"
shoppingCart
"
});
this
.
$router
.
push
({
name
:
"
shoppingCart
"
});
},
},
deleteItem
()
{},
deleteItem
()
{},
getDetail
()
{
getDetail
()
{
// if you want goto detail page, you should give me the type at first
// if you want goto detail page, you should give me the type at first
}
},
}
gotoChildPage
(
v
)
{
if
(
v
.
path
)
{
this
.
$router
.
push
(
v
.
path
);
}
},
},
};
};
</
script
>
</
script
>
...
@@ -304,4 +390,4 @@ export default {
...
@@ -304,4 +390,4 @@ export default {
text-overflow
:
ellipsis
;
text-overflow
:
ellipsis
;
white-space
:
nowrap
;
white-space
:
nowrap
;
}
}
</
style
>
</
style
>
\ No newline at end of file
src/router/index.js
View file @
9b47d054
...
@@ -22,7 +22,7 @@ export default new Router({
...
@@ -22,7 +22,7 @@ export default new Router({
path
:
"
/index
"
,
path
:
"
/index
"
,
name
:
"
index
"
,
name
:
"
index
"
,
component
:
()
=>
import
(
"
@/pages/index
"
),
component
:
()
=>
import
(
"
@/pages/index
"
),
redirect
:
"
/
workplace
"
,
redirect
:
"
/
services_shop
"
,
children
:
[
children
:
[
{
{
path
:
"
/fwzc
"
,
// 服务注册
path
:
"
/fwzc
"
,
// 服务注册
...
...
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