{"remainingRequest":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\xq-web-bpm\\src\\components\\common\\HtTabsComponentHref.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\src\\components\\common\\HtTabsComponentHref.vue","mtime":1675071991694},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/es7.object.get-own-property-descriptors\";\nimport \"core-js/modules/web.dom.iterable\";\nimport \"core-js/modules/es6.object.keys\";\nimport \"core-js/modules/es6.function.name\";\nimport \"core-js/modules/es6.regexp.replace\";\nimport _defineProperty from \"D:/jenkins/workspace/xq-web-bpm/node_modules/@babel/runtime/helpers/esm/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\nimport { mapGetters } from \"vuex\";\nimport menuApi from \"@/api/menu.js\";\nexport default {\n  name: \"ht-tabs-component-href\",\n  components: {},\n  props: {},\n  computed: _objectSpread(_objectSpread({}, mapGetters({\n    tabsStyle: \"styleSetting/tabsStyle\"\n  })), {}, {\n    finalTabsStyle: function finalTabsStyle() {\n      // 使用菜单的配置\n      if ((this.tabsStyle.tabType == \"menuSetting\" || this.tabsStyle.tabType == null) && this.menuTabsStyle) {\n        return this.menuTabsStyle;\n      } // 使用默认的\n\n\n      if (this.tabsStyle.tabType == null || (this.tabsStyle.tabType == \"menuSetting\" || this.tabsStyle.tabType == null) && !this.menuTabsStyle) {\n        return {\n          tabType: \"\"\n        };\n      } // 使用全局的配置\n\n\n      return this.tabsStyle;\n    }\n  }),\n  data: function data() {\n    return {\n      href: \"\",\n      //外部菜单url地址\n      tabComponentOptions: [],\n      currentTabComponent: \"\",\n      menuTabsStyle: null\n    };\n  },\n  methods: {\n    handlePaneClick: function handlePaneClick(data) {\n      if (data.alias) {\n        this.currentTabComponent = data.alias;\n      }\n    }\n  },\n  beforeRouteEnter: function beforeRouteEnter(to, from, next) {\n    next(function (vm) {\n      // 通过 `vm` 访问组件实例\n      var routePath = vm.$route.path;\n\n      if (routePath && routePath.indexOf('/sysplat/href/') == -1) {\n        var i = routePath.lastIndexOf('/');\n        routePath = routePath.slice(i + 1);\n      } else {\n        routePath = routePath.replace('/sysplat/', '');\n      }\n\n      menuApi.getMenuByAlias(routePath, function (m) {\n        if (m) {\n          vm.$emit(\"menuChange\", m);\n\n          if (m.children && m.children.length > 0) {\n            vm.tabComponentOptions = m.children;\n            vm.href = vm.tabComponentOptions[0].href;\n            vm.currentTabComponent = m.activeTab || vm.tabComponentOptions[0].alias;\n          } else {\n            vm.tabComponentOptions = [];\n            vm.currentTabComponent = m.alias;\n\n            if (m.href.indexOf(\"?token=\") == -1) {\n              vm.href = m.href + \"?token=\" + vm.$store.state.login.currentUser.token;\n            } else {\n              vm.href = m.href;\n            }\n          }\n\n          if (m.tabsStyle) {\n            vm.menuTabsStyle = JSON.parse(m.tabsStyle);\n          } else {\n            vm.menuTabsStyle = null;\n          }\n        } else {\n          // 没有菜单的路由跳转   需要显示TAb名称需要定义tobName参数传递过来\n          vm.tabComponentOptions = [];\n          vm.currentTabComponent = to.name;\n          vm.$emit(\"menuChange\", {\n            name: to.params.tobName\n          });\n        }\n      });\n    });\n  },\n  beforeRouteUpdate: function beforeRouteUpdate(to, from, next) {\n    // 在当前路由改变，但是该组件被复用时调用\n    // 举例来说，对于一个带有动态参数的路径 /foo/:id，在 /foo/1 和 /foo/2 之间跳转的时候，\n    // 由于会渲染同样的 Foo 组件，因此组件实例会被复用。而这个钩子就会在这个情况下被调用。\n    // 可以访问组件实例 `this`\n    // 通过 `vm` 访问组件实例\n    next();\n    var vm = this;\n    var routePath = to.fullPath;\n\n    if (routePath && routePath.indexOf('/sysplat/href/') == -1) {\n      var i = routePath.lastIndexOf('/');\n      routePath = routePath.slice(i + 1);\n    } else {\n      routePath = routePath.replace('/sysplat/', '');\n    }\n\n    menuApi.getMenuByAlias(routePath, function (m) {\n      if (m) {\n        vm.$emit(\"menuChange\", m);\n\n        if (m.children && m.children.length > 0) {\n          vm.tabComponentOptions = m.children;\n          vm.href = vm.tabComponentOptions[0].href;\n          vm.currentTabComponent = m.activeTab || vm.tabComponentOptions[0].alias;\n        } else {\n          vm.tabComponentOptions = [];\n          vm.currentTabComponent = m.alias;\n\n          if (m.href.indexOf(\"?token=\") == -1) {\n            vm.href = m.href + \"?token=\" + vm.$store.state.login.currentUser.token;\n          } else {\n            vm.href = m.href;\n          }\n        }\n\n        if (m.tabsStyle) {\n          vm.menuTabsStyle = JSON.parse(m.tabsStyle);\n        } else {\n          vm.menuTabsStyle = null;\n        }\n      } else {\n        // 没有菜单的路由跳转   需要显示TAb名称需要定义tobName参数传递过来\n        vm.tabComponentOptions = [];\n        vm.currentTabComponent = to.name;\n        vm.$emit(\"menuChange\", {\n          name: to.params.tobName ? to.params.tobName : to.meta.menuLabel\n        });\n      }\n    });\n  }\n};",null]}