{"remainingRequest":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\babel-loader\\lib\\index.js!C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\style-vw-loader\\index.js??ref--0-2!C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\src\\components\\common\\Tags.vue?vue&type=script&lang=js&","dependencies":[{"path":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\src\\components\\common\\Tags.vue","mtime":1663828782923},{"path":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\babel.config.js","mtime":1663828782900},{"path":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000},{"path":"C:\\Users\\100zone\\Desktop\\baizong\\community\\SmartCommunity\\videoSurveillance\\node_modules\\style-vw-loader\\index.js","mtime":1540864632000}],"contextDependencies":[],"result":["import \"core-js/modules/es6.function.name\";\nimport \"core-js/modules/es7.array.includes\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\nvar detaillist = ['/viewDetail', '/installplanView'];\nexport default {\n data: function data() {\n return {// tagsList: []\n };\n },\n methods: {\n // 点击标签页\n isActive: function isActive(path) {\n if (path instanceof Object) {\n var fullpath = this.setFullPath(path);\n return fullpath === this.$route.fullPath;\n }\n\n return path === this.$route.fullPath;\n },\n // 关闭单个标签\n closeTags: function closeTags(index) {\n if (this.tagsList.length > 1) {\n var delItem = this.tagsList.splice(index, 1)[0];\n var item = this.tagsList[index] ? this.tagsList[index] : this.tagsList[index - 1];\n\n if (item) {\n if (detaillist.includes(delItem.path.path)) {\n var delfullpath = this.setFullPath(delItem.path);\n delfullpath === this.$route.fullPath && this.$router.push(item.path);\n } else {\n delItem.path === this.$route.fullPath && this.$router.push(item.path);\n }\n }\n }\n },\n // 关闭其他标签\n closeOther: function closeOther() {\n var _this = this;\n\n var curItem = this.tagsList.filter(function (item) {\n if (detaillist.includes(_this.$route.path)) {\n var fullpath = item.path instanceof Object ? _this.setFullPath(item.path) : item.path;\n return fullpath === _this.$route.fullPath;\n }\n\n return item.path === _this.$route.fullPath;\n });\n this.tagsList.splice(0, this.tagsList.length);\n this.$store.dispatch('tags', curItem.concat());\n },\n setFullPath: function setFullPath(item) {\n var itemfullpath = '';\n\n if (JSON.stringify(item) != '{}') {\n itemfullpath = item.path + '?';\n\n _.mapKeys(item.query, function (val, key) {\n if (!_.isEmpty(String(val)) && val) {\n if (key == 'planName') {\n val = encodeURI(val);\n }\n\n itemfullpath += \"\".concat(key, \"=\").concat(val, \"&\");\n }\n });\n\n if (itemfullpath.substr(itemfullpath.length - 1, 1) == '&') {\n itemfullpath = itemfullpath.slice(0, itemfullpath.length - 1);\n }\n }\n\n return itemfullpath;\n },\n // 设置标签\n setTags: function setTags(route) {\n var _this2 = this;\n\n var tagArr = {\n title: route.title || route.meta.title,\n path: route.fullPath\n };\n\n if (!!route.name) {\n tagArr = {\n title: route.title || route.meta.title,\n path: route.fullPath,\n name: route.name\n };\n }\n\n var isExist = this.tagsList.some(function (item, index) {\n var thisBi = item.path.indexOf(route.path) > -1;\n\n if (thisBi) {\n _this2.tagsList.splice(index, 1, tagArr);\n\n _this2.$store.dispatch('tags', _this2.tagsList);\n }\n\n return thisBi;\n });\n\n if (!isExist) {\n if (route.path === '/') {\n return;\n }\n\n if (this.tagsList.length >= 8) {\n this.tagsList.shift();\n }\n\n this.tagsList.push(tagArr);\n this.$store.dispatch('tags', this.tagsList);\n }\n }\n },\n computed: {\n showTags: function showTags() {\n return this.tagsList.length > 0;\n },\n tagsList: function tagsList() {\n return this.$store.getters['getTagsList'];\n }\n },\n watch: {\n $route: function $route(newValue, oldValue) {\n this.setTags(newValue);\n }\n },\n created: function created() {\n this.setTags(this.$route);\n }\n};",{"version":3,"mappings":";;;;;;;;;;;;;;;AAcA;AACA;AACAA,MADA,kBACA;AACA,YACA;AADA;AAGA,GALA;AAMAC;AACA;AACAC,YAFA,oBAEAC,IAFA,EAEA;AACA;AACA;AACA;AACA;;AACA;AACA,KARA;AASA;AACAC,aAVA,qBAUAC,KAVA,EAUA;AACA;AACA;AACA;;AACA;AACA;AACA;AACAC;AACA,WAHA,MAGA;AACAC;AACA;AACA;AACA;AACA,KAvBA;AAwBA;AACAC,cAzBA,wBAyBA;AAAA;;AACA;AACA;AACA;AACA;AACA;;AACA;AACA,OANA;AAOA;AACA;AACA,KAnCA;AAoCAC,eApCA,uBAoCAC,IApCA,EAoCA;AACA;;AACA;AACAC;;AACAC;AACA;AACA;AACAC;AACA;;AACAF;AACA;AACA,SAPA;;AAQA;AACAA;AACA;AACA;;AACA;AACA,KArDA;AAsDA;AACAG,WAvDA,mBAuDAC,KAvDA,EAuDA;AAAA;;AACA;AACAC,8CADA;AAEAb;AAFA;;AAIA;AACAc;AACAD,gDADA;AAEAb,8BAFA;AAGAe;AAHA;AAKA;;AAEA;AACA;;AACA;AACA;;AAEA;AACA;;AACA;AACA,OARA;;AASA;AACA;AACA;AACA;;AACA;AACA;AACA;;AACA;AACA;AACA;AACA;AAvFA,GANA;AA+FAC;AACAC,YADA,sBACA;AACA;AACA,KAHA;AAIAC,YAJA,sBAIA;AACA;AACA;AANA,GA/FA;AAuGAC;AACAC,UADA,kBACAC,QADA,EACAC,QADA,EACA;AACA;AACA;AAHA,GAvGA;AA4GAC,SA5GA,qBA4GA;AACA;AACA;AA9GA","names":["data","methods","isActive","path","closeTags","index","delfullpath","delItem","closeOther","setFullPath","item","itemfullpath","_","val","setTags","route","title","tagArr","name","computed","showTags","tagsList","watch","$route","newValue","oldValue","created"],"sourceRoot":"src/components/common","sources":["Tags.vue"],"sourcesContent":["\r\n \r\n\r\n\r\n\r\n"]}]}