-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- [新增] 因为滚动条受到全局的影响, 所以我们使用scrollBehavior路由钩子, 解决初始化问题
- Loading branch information
Showing
4 changed files
with
56 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"ret": true, | ||
"data": { | ||
"sightName": "大连圣亚海洋世界(AAAA景区)", | ||
"bannerImg": "http://img1.qunarzz.com/sight/p0/201404/23/04b92c99462687fa1ba45c1b5ba4ad77.jpg_600x330_bf9c4904.jpg", | ||
"gallaryImgs": [ | ||
"http://img1.qunarzz.com/sight/p0/201404/23/04b92c99462687fa1ba45c1b5ba4ad77.jpg_800x800_70debc93.jpg", | ||
"http://img1.qunarzz.com/sight/p0/1709/76/7691528bc7d7ad3ca3.img.png_800x800_9ef05ee7.png" | ||
], | ||
"categoryList": [ | ||
{ | ||
"title": "成人票", | ||
"children": [ | ||
{ | ||
"title": "成人三馆联票", | ||
"children": [ | ||
{ | ||
"title": "成人三馆联票 - 某一连锁店销售" | ||
} | ||
] | ||
}, | ||
{ | ||
"title": "成人五馆联票" | ||
} | ||
] | ||
}, | ||
{ | ||
"title": "学生票" | ||
}, | ||
{ | ||
"title": "儿童票" | ||
}, | ||
{ | ||
"title": "特惠票" | ||
} | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
<template> | ||
<div id="app"> | ||
<keep-alive> | ||
<keep-alive :exclude="['Detail']"> | ||
<router-view /> | ||
</keep-alive> | ||
</div> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,4 +24,8 @@ export default new Router({ | |
component: Detail, | ||
}, | ||
], | ||
scrollBehavior() { | ||
return {x: 0, y: 0}; | ||
}, | ||
|
||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters