This.$router.push,导致路由改变,无法正确跳转

我使用的是vue-element-admin作为模板

router配置

import Layout from '@/layout'

export default [
  {
    module: 'WMS',
    path: '/customs/dec',
    component: Layout,
    redirect: 'noRedirect',
    name: 'CustomsDec',
    meta: { title: 'customs.dec', icon: 'component' },
    children: [
      {
        path: 'I/insert',
        component: () => import('@/views/customs/dec/import/import'),
        name: 'Import',
        meta: { title: 'customs.dec.import', icon: 'list' },
        beforeEnter(to, from, next) {
          to.params.ieFlag = 'I'
          next()
        }
      },
      {
        path: 'I/insert/*',
        component: () => import('@/views/customs/dec/import/import'),
        name: 'Import',
        meta: { title: 'customs.dec.import', icon: 'list' },
        hidden: true,
        beforeEnter(to, from, next) {
          to.params.ieFlag = 'I'
          next()
        }
      },
      {
        path: 'E/insert',
        component: () => import('@/views/customs/dec/import/import'),
        name: 'Import',
        meta: { title: 'customs.dec.export', icon: 'list' },
        beforeEnter(to, from, next) {
          to.params.ieFlag = 'E'
          next()
        }
      },
      {
        path: 'E/insert/*',
        component: () => import('@/views/customs/dec/import/import'),
        name: 'Import',
        meta: { title: 'customs.dec.export', icon: 'list' },
        hidden: true,
        beforeEnter(to, from, next) {
          to.params.ieFlag = 'E'
          next()
        }
      },
      {
        path: ':ieFlag/edit/:innerNo',
        component: () => import('@/views/customs/dec/import/import'),
        name: 'Import',
        meta: { title: 'customs.dec.import' },
        hidden: true
      }
    ]
  }
]

TagsView相关内容

<template>
  <div id="tags-view-container" class="tags-view-container">
    <scroll-pane ref="scrollPane" class="tags-view-wrapper" @scroll="handleScroll">
      <router-link
        v-for="tag in visitedViews"
        ref="tag"
        :key="tag.path"
        :class="isActive(tag)?'active':''"
        :to="{ path: tag.path, query: tag.query, fullPath: tag.fullPath }"
        tag="span"
        class="tags-view-item"
        @click.middle.native="!isAffix(tag)?closeSelectedTag(tag):''"
        @contextmenu.prevent.native="openMenu(tag,$event)"
      >
        {{ generateTitle(tag.title) }}
        <span v-if="!isAffix(tag)" class="el-icon-close" @click.prevent.stop="closeSelectedTag(tag)" />
      </router-link>
    </scroll-pane>
    <ul v-show="visible" :style="{left:left+'px',top:top+'px'}" class="contextmenu">
      <li @click="refreshSelectedTag(selectedTag)">{{ $t('tagsView.refresh') }}</li>
      <li v-if="!isAffix(selectedTag)" @click="closeSelectedTag(selectedTag)">{{ $t('tagsView.close') }}</li>
      <li @click="closeOthersTags">{{ $t('tagsView.closeOthers') }}</li>
      <li @click="closeAllTags(selectedTag)">{{ $t('tagsView.closeAll') }}</li>
    </ul>
  </div>
</template>
    openMenu(tag, e) {
      const menuMinWidth = 105
      const offsetLeft = this.$el.getBoundingClientRect().left // container margin left
      const offsetWidth = this.$el.offsetWidth // container width
      const maxLeft = offsetWidth - menuMinWidth // left boundary
      const left = e.clientX - offsetLeft + 15 // 15: margin right

      if (left > maxLeft) {
        this.left = maxLeft
      } else {
        this.left = left
      }

      this.top = e.clientY
      this.visible = true
      this.selectedTag = tag
      console.log('tag', tag)
    },
    closeOthersTags() {
      console.log('closeOthersTags', this.selectedTag)
      this.$router.push(this.selectedTag)
      this.$store.dispatch('tagsView/delOthersViews', this.selectedTag).then(() => {
        this.moveToCurrentTag()
      })
    },

页面

当我按下【关闭其它】时

紧接着我修改了closeOthersTags方法

    closeOthersTags() {
      console.log('closeOthersTags', this.selectedTag)
      // this.$router.push(this.selectedTag)
      // this.$store.dispatch('tagsView/delOthersViews', this.selectedTag).then(() => {
      //   this.moveToCurrentTag()
      // })
    },

结果

进行this.$router.push(this.selectedTag)直接导致了路由的变化(错误的变化)
期待值:fullPath: “/customs/dec/I/edit/3412311211”
实际值:fullPath: “/customs/dec/I/insert”