fix:fix tabsView path bug
This commit is contained in:
		@@ -30,13 +30,16 @@ export default {
 | 
				
			|||||||
      $event.preventDefault()
 | 
					      $event.preventDefault()
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    generateRoute() {
 | 
					    generateRoute() {
 | 
				
			||||||
      if (this.$route.matched[this.$route.matched.length - 1].name) {
 | 
					      if (this.$route.name) {
 | 
				
			||||||
        return this.$route.matched[this.$route.matched.length - 1]
 | 
					        return this.$route
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      this.$route.matched[0].path = '/'
 | 
					      return false
 | 
				
			||||||
      return this.$route.matched[0]
 | 
					 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    addViewTabs() {
 | 
					    addViewTabs() {
 | 
				
			||||||
 | 
					      const route = this.generateRoute()
 | 
				
			||||||
 | 
					      if (!route) {
 | 
				
			||||||
 | 
					        return false
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
      this.$store.dispatch('addVisitedViews', this.generateRoute())
 | 
					      this.$store.dispatch('addVisitedViews', this.generateRoute())
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    isActive(path) {
 | 
					    isActive(path) {
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user