File tree Expand file tree Collapse file tree 1 file changed +2
-12
lines changed Expand file tree Collapse file tree 1 file changed +2
-12
lines changed Original file line number Diff line number Diff line change 4141 <div class =" page-header-index-wide" >
4242 <slot >
4343 <!-- keep-alive -->
44- <route -view ref =" content" ></route -view >
44+ <router -view ref =" content" ></router -view >
4545 </slot >
4646 </div >
4747 </div >
5050
5151<script >
5252import PageHeader from ' @/components/PageHeader'
53- import RouteView from ' ./RouteView'
5453
5554export default {
5655 name: ' PageView' ,
5756 components: {
58- RouteView,
5957 PageHeader
6058 },
6159 props: {
@@ -88,21 +86,13 @@ export default {
8886 updated () {
8987 this .getPageHeaderInfo ()
9088 },
91- computed: {
92-
93- getPageTitle () {
94- return this .$route .meta .title
95- }
96-
97- },
9889 methods: {
9990 getPageHeaderInfo () {
10091 // eslint-disable-next-line
10192 this .pageTitle = (typeof (this .title ) === ' string' || ! this .title ) ? this .title : this .$route .meta .title
10293
10394 // 因为套用了一层 route-view 所以要取 ref 对象下的子节点的第一个对象
104- const content = this .$refs .content && this .$refs .content .$children [0 ]
105-
95+ const content = this .$refs .content
10696 if (content) {
10797 this .description = content .description
10898 this .linkList = content .linkList
You can’t perform that action at this time.
0 commit comments