chunk-2557bfba.51598950.js 30 KB

123456789
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-2557bfba"],{"00ba":function(e,t,n){n("bbb7")},1094:function(e,t,n){},"16f7":function(e,t,n){n("b0f5")},"1b69":function(e,t,n){var i=n("c7eb"),r=n("1da1"),a=(n("d3b7"),n("a18c"),n("5daa")),s=n("5f87"),o={};window.ajaxTimeout=2e4,t.a=Object(r.a)(Object(i.a)().mark((function e(){var t,n,l,c,u,f,d,h=arguments;return Object(i.a)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=0<h.length&&void 0!==h[0]?h[0]:"",n=1<h.length&&void 0!==h[1]?h[1]:{},l=2<h.length&&void 0!==h[2]?h[2]:"GET",c=3<h.length&&void 0!==h[3]?h[3]:{},u=4<h.length&&void 0!==h[4]?h[4]:o,f=5<h.length?h[5]:void 0,l=l.toLowerCase(),d={method:l,baseURL:"",url:a.a.baseURL+t,data:n,params:c,processData:!0,timeout:window.ajaxTimeout,headers:u,onUploadProgress:f},f&&"function"==typeof f&&(d.onUploadProgress=f),axios.interceptors.request.use((function(e){return e.data.token||(e.data.token=Object(s.e)()),e}),(function(e){return Promise.reject(new Error("服务器异常,请联系管理员!"))})),axios.interceptors.response.use((()=>{var e=Object(r.a)(Object(i.a)().mark((function e(t){var n;return Object(i.a)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return 200===t.status&&100<=(n=t.data.code)&&n<=104&&(Object(s.i)(),Object(s.g)(),Object(s.f)()),e.abrupt("return",t);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}})(),(function(e){return Promise.reject(e.response.data)})),e.abrupt("return",new Promise((function(e,t){axios(d).then((function(t){e(t.data)})).catch((function(e){e.response&&e.response.data?t(e.response.data):t(e)}))})));case 12:case"end":return e.stop()}}),e)})))},2489:function(e,t,n){n("9246")},"32a4":function(e,t,n){},3658:function(e,t,n){n("b0f9")},"3df7":function(e,t,n){n("1094")},4362:function(e,t,n){var i,r;t.nextTick=function(e){var t=Array.prototype.slice.call(arguments);t.shift(),setTimeout((function(){e.apply(null,t)}),0)},t.platform=t.arch=t.execPath=t.title="browser",t.pid=1,t.browser=!0,t.env={},t.argv=[],t.binding=function(e){throw new Error("No such module. (Possibly not yet loaded)")},r="/",t.cwd=function(){return r},t.chdir=function(e){i=i||n("df7c"),r=i.resolve(e,r)},t.exit=t.kill=t.umask=t.dlopen=t.uptime=t.memoryUsage=t.uvCounters=function(){},t.features={}},"4c1f":function(e,t,n){var i=n("1b69");t.a={list:function(e,t){return Object(i.a)("admin/versionlist",e,"post",t)}}},5449:function(e,t,n){},"69c6":function(e,t,n){n("b75a")},"69f0":function(e,t,n){n("8c0a")},"6e31":function(e,t,n){},"82f9":function(e,t,n){n("bc11")},"8c0a":function(e,t,n){},9246:function(e,t,n){},"93bf":function(e,t,n){
  2. /*!
  3. * screenfull
  4. * v4.2.0 - 2019-04-01
  5. * (c) Sindre Sorhus; MIT License
  6. */
  7. var i,r,a,s,o,l;i="undefined"!=typeof window&&void 0!==window.document?window.document:{},r=e.exports,a="undefined"!=typeof Element&&"ALLOW_KEYBOARD_INPUT"in Element,s=(()=>{for(var e,t=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],n=0,r=t.length,a={};n<r;n++)if((e=t[n])&&e[1]in i){for(n=0;n<e.length;n++)a[t[0][n]]=e[n];return a}return!1})(),o={change:s.fullscreenchange,error:s.fullscreenerror},l={request:function(e){return new Promise(function(t){var n=s.requestFullscreen,r=function(){this.off("change",r),t()}.bind(this);e=e||i.documentElement,/ Version\/5\.1(?:\.\d+)? Safari\//.test(navigator.userAgent)?e[n]():e[n](a?Element.ALLOW_KEYBOARD_INPUT:{}),this.on("change",r)}.bind(this))},exit:function(){return new Promise(function(e){var t;this.isFullscreen?(t=function(){this.off("change",t),e()}.bind(this),i[s.exitFullscreen](),this.on("change",t)):e()}.bind(this))},toggle:function(e){return this.isFullscreen?this.exit():this.request(e)},onchange:function(e){this.on("change",e)},onerror:function(e){this.on("error",e)},on:function(e,t){e=o[e],e&&i.addEventListener(e,t,!1)},off:function(e,t){e=o[e],e&&i.removeEventListener(e,t,!1)},raw:s},s?(Object.defineProperties(l,{isFullscreen:{get:function(){return Boolean(i[s.fullscreenElement])}},element:{enumerable:!0,get:function(){return i[s.fullscreenElement]}},enabled:{enumerable:!0,get:function(){return Boolean(i[s.fullscreenEnabled])}}}),r?(e.exports=l,e.exports.default=l):window.screenfull=l):r?e.exports=!1:window.screenfull=!1},"9bb3":function(e,t,n){n("6e31")},"9f53":function(e,t,n){var i=n("c7eb"),r=n("1da1");t.a={methods:{logout:function(){var e=this;return Object(r.a)(Object(i.a)().mark((function t(){return Object(i.a)().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if("/login"!==e.$route.path)return t.next=3,e.$store.dispatch("user/logout");t.next=4;break;case 3:e.$router.push("/login");case 4:case"end":return t.stop()}}),t)})))()}}}},ad76:function(e,t,n){n("5449")},b0f5:function(e,t,n){},b0f9:function(e,t,n){},b75a:function(e,t,n){},bbb7:function(e,t,n){},bc11:function(e,t,n){},bd11:function(e,t){e.exports=u,e.exports.parse=a,e.exports.compile=function(e,t){return s(a(e,t))},e.exports.tokensToFunction=s,e.exports.tokensToRegExp=c;var n="/",i="./",r=new RegExp(["(\\\\.)","(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?"].join("|"),"g");function a(e,t){for(var a=[],s=0,l=0,c="",u=t&&t.delimiter||n,f=t&&t.delimiters||i,d=!1;null!==(m=r.exec(e));){var h,p,m,b,g=m[0],v=m[1],w=m.index;c+=e.slice(l,w),l=w+g.length,v?(c+=v[1],d=!0):(w="",g=e[l],v=m[2],h=m[3],p=m[4],m=m[5],!d&&c.length&&(b=c.length-1,-1<f.indexOf(c[b]))&&(w=c[b],c=c.slice(0,b)),c&&(a.push(c),c="",d=!1),b=""!==w&&void 0!==g&&g!==w,a.push({name:v||s++,prefix:w,delimiter:g=w||u,optional:"?"===m||"*"===m,repeat:"+"===m||"*"===m,partial:b,pattern:(v=h||p)?v.replace(/([=!:$/()])/g,"\\$1"):"[^"+o(g)+"]+?"}))}return(c||l<e.length)&&a.push(c+e.substr(l)),a}function s(e){for(var t=new Array(e.length),n=0;n<e.length;n++)"object"==typeof e[n]&&(t[n]=new RegExp("^(?:"+e[n].pattern+")$"));return function(n,i){for(var r="",a=i&&i.encode||encodeURIComponent,s=0;s<e.length;s++){var o=e[s];if("string"==typeof o)r+=o;else{var l,c=n?n[o.name]:void 0;if(Array.isArray(c)){if(!o.repeat)throw new TypeError('Expected "'+o.name+'" to not repeat, but got array');if(0===c.length){if(o.optional)continue;throw new TypeError('Expected "'+o.name+'" to not be empty')}for(var u=0;u<c.length;u++){if(l=a(c[u],o),!t[s].test(l))throw new TypeError('Expected all "'+o.name+'" to match "'+o.pattern+'"');r+=(0===u?o.prefix:o.delimiter)+l}}else if("string"==typeof c||"number"==typeof c||"boolean"==typeof c){if(l=a(String(c),o),!t[s].test(l))throw new TypeError('Expected "'+o.name+'" to match "'+o.pattern+'", but got "'+l+'"');r+=o.prefix+l}else{if(!o.optional)throw new TypeError('Expected "'+o.name+'" to be '+(o.repeat?"an array":"a string"));o.partial&&(r+=o.prefix)}}}return r}}function o(e){return e.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1")}function l(e){return e&&e.sensitive?"":"i"}function c(e,t,r){for(var a=(r=r||{}).strict,s=!1!==r.start,c=!1!==r.end,u=o(r.delimiter||n),f=r.delimiters||i,d=[].concat(r.endsWith||[]).map(o).concat("$").join("|"),h=s?"^":"",p=0===e.length,m=0;m<e.length;m++){var b,g=e[m];"string"==typeof g?(h+=o(g),p=m===e.length-1&&-1<f.indexOf(g[g.length-1])):(b=g.repeat?"(?:"+g.pattern+")(?:"+o(g.delimiter)+"(?:"+g.pattern+"))*":g.pattern,t&&t.push(g),g.optional?g.partial?h+=o(g.prefix)+"("+b+")?":h+="(?:"+o(g.prefix)+"("+b+"))?":h+=o(g.prefix)+"("+b+")")}return c?(a||(h+="(?:"+u+")?"),h+="$"===d?"$":"(?="+d+")"):(a||(h+="(?:"+u+"(?="+d+"))?"),p||(h+="(?="+u+"|"+d+")")),new RegExp(h,l(r))}function u(e,t,n){if(e instanceof RegExp){var i=e,r=t;if(r){var s=i.source.match(/\((?!\?)/g);if(s)for(var o=0;o<s.length;o++)r.push({name:o,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,pattern:null})}return i}if(Array.isArray(e)){for(var f=e,d=t,h=n,p=[],m=0;m<f.length;m++)p.push(u(f[m],d,h).source);return new RegExp("(?:"+p.join("|")+")",l(h))}return i=t,c(a(e,t=n),i,t)}},c1f7:function(e,t,n){n.r(t);var i=n("5530"),r={name:"AppMain",computed:{cachedViews:function(){return this.$store.state.tagsView.cachedViews},key:function(){return this.$route.path}}},a=(n("69c6"),n("3df7"),n("2877")),s=(r=Object(a.a)(r,(function(){var e=this._self._c;return e("section",{staticClass:"app-main"},[e("transition",{attrs:{name:"fade-transform",mode:"out-in"}},[e("keep-alive",{attrs:{include:this.cachedViews}},[e("router-view",{key:this.key})],1)],1)],1)}),[],!1,null,"5c229b4f",null).exports,n("c7eb")),o=n("1da1"),l=(n("e9c4"),n("b64b"),n("2f62")),c=(n("99af"),n("4de4"),n("b0c0"),n("d3b7"),n("2ca0"),n("498a"),n("bd11")),u=n.n(c),f=(c={data:function(){return{levelList:null}},watch:{$route:function(e){e.path.startsWith("/redirect/")||this.getBreadcrumb()}},created:function(){this.getBreadcrumb()},methods:{getBreadcrumb:function(){var e=this.$route.matched.filter((function(e){return e.meta&&e.meta.title})),t=e[0];this.isDashboard(t)||(e=[{path:"/welcome/dashboard",meta:{title:"首页"}}].concat(e)),this.levelList=e.filter((function(e){return e.meta&&e.meta.title&&!1!==e.meta.breadcrumb}))},isDashboard:function(e){return e=e&&e.name,!!e&&e.trim().toLocaleLowerCase()==="Dashboard".toLocaleLowerCase()},pathCompile:function(e){var t=this.$route.params;return u.a.compile(e)(t)},handleLink:function(e){var t=e.redirect;e=e.path;t?window.vm.$router.push(t):window.vm.$router.push(this.pathCompile(e))}}},c=(n("9bb3"),Object(a.a)(c,(function(){var e=this,t=e._self._c;return t("el-breadcrumb",{staticClass:"app-breadcrumb",attrs:{separator:"/"}},[t("transition-group",{attrs:{name:"breadcrumb"}},e._l(e.levelList,(function(n,i){return t("el-breadcrumb-item",{key:n.path},["noRedirect"===n.redirect||i==e.levelList.length-1?t("span",{staticClass:"no-redirect"},[e._v(e._s(n.meta.title))]):t("a",{on:{click:function(t){return t.preventDefault(),e.handleLink(n)}}},[e._v(e._s(n.meta.title))])])})),1)],1)}),[],!1,null,"0968a14c",null).exports),n("93bf")),d=n.n(f),h=(f={name:"Screenfull",data:function(){return{isFullscreen:!1}},mounted:function(){this.init()},beforeDestroy:function(){this.destroy()},methods:{click:function(){if(!d.a.enabled)return this.$message({message:"you browser can not work",type:"warning"}),!1;d.a.toggle()},change:function(){this.isFullscreen=d.a.isFullscreen},init:function(){d.a.enabled&&d.a.on("change",this.change)},destroy:function(){d.a.enabled&&d.a.off("change",this.change)}}},f=(n("16f7"),Object(a.a)(f,(function(){var e=this._self._c;return e("div",[e("i",{class:{"el-icon-full-screen rt1":this.isFullscreen,"el-icon-rank rt2":!this.isFullscreen},on:{click:this.click}})])}),[],!1,null,"1f393a58",null).exports),n("4c1f")),p=n("9f53"),m=n("5f87"),b=(c={components:{Breadcrumb:c,Screenfull:f},computed:Object(i.a)({},Object(l.b)(["sidebar","avatar","device"])),mixins:[p.a],data:function(){return{showModel:!1,loading:!1,isShow:!0,statsTime:0,endTime:0,checked:!1,lastNotice:null,parmValue:{type:"",page:1,size:15},activeMsg:null}},mounted:function(){},methods:{openNotice:function(e){var t=this;return Object(o.a)(Object(s.a)().mark((function n(){var i,r;return Object(s.a)().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return Object(m.c)()&&0<Object(m.c)().length?t.lastNotice=JSON.parse(Object(m.c)()):t.lastNotice=null,t.loading=!0,n.next=5,h.a.list(t.parmValue);case 5:(i=n.sent)&&0===i.code&&i.data&&i.data.list&&0<i.data.list.length?(t.activeMsg=i.data.list[0],t.isShow=!0,t.lastNotice+""!="null"?t.activeMsg.addtime===t.lastNotice.addtime&&"1"===t.lastNotice.type?t.checked=!0:t.checked=!1:(r={type:t.checked?"1":"0",addtime:t.activeMsg.addtime},Object(m.l)(JSON.stringify(r)),t.checked=!1),1===e?t.typeShow():t.showModel=!0,n.next=20):n.next=13;break;case 13:if(i&&100<=i.code&&i.code<=104)return n.next=16,t.logout();n.next=18;break;case 16:n.next=20;break;case 18:t.activeMsg=null,t.isShow=!1;case 20:t.loading=!1;case 21:case"end":return n.stop()}}),n)})))()},typeShow:function(){var e=(new Date).valueOf();"VER"===this.activeMsg.sys_type?(this.statsTime=new Date(this.activeMsg.addtime).valueOf(),this.endTime=this.statsTime+6048e5,e>this.statsTime&&e<this.endTime&&!this.checked?this.showModel=!0:this.showModel=!1):(this.statsTime=0,this.endTime=new Date(this.activeMsg.addtime).valueOf(),e<this.endTime&&!this.checked?this.showModel=!0:this.showModel=!1)},toggleSideBar:function(){this.$route.this.$store.dispatch("app/toggleSideBar")},logout:function(){var e=this;return Object(o.a)(Object(s.a)().mark((function t(){return Object(s.a)().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.$store.dispatch("user/logout");case 2:e.$router.push("/login?redirect=".concat(e.$route.fullPath));case 3:case"end":return t.stop()}}),t)})))()},submit:function(){var e={type:this.checked?"1":"0",addtime:this.activeMsg.addtime};Object(m.l)(JSON.stringify(e)),this.showModel=!1}}},f=(n("00ba"),Object(a.a)(c,(function(){var e=this,t=e._self._c;return t("div",{staticClass:"navbar"},[t("breadcrumb",{staticClass:"breadcrumb-container",attrs:{id:"breadcrumb-container"}}),t("div",{staticClass:"right-menu"},["mobile"!==e.device?[t("screenfull",{staticClass:"right-menu-item hover-effect",attrs:{id:"screenfull"}})]:e._e(),t("el-dropdown",{staticClass:"avatar-container right-menu-item hover-effect",attrs:{trigger:"click"}},[t("div",{staticClass:"avatar-wrapper"},[t("img",{staticClass:"user-avatar",attrs:{src:e.avatar}}),t("i",{staticClass:"el-icon-caret-bottom"})]),t("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},[t("el-dropdown-item",{nativeOn:{click:function(t){return e.logout.apply(null,arguments)}}},[t("span",{staticStyle:{display:"block"}},[e._v("退出登录")])])],1)],1)],2),t("el-dialog",{attrs:{title:"系统公告",center:!0,align:"left",top:"22vh",width:"800px","close-on-click-modal":!1,visible:e.showModel,"element-loading-text":"拼命加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"rgba(0, 0, 0, 0.8)","append-to-body":""},on:{close:e.submit,"update:visible":function(t){e.showModel=t}}},[t("el-card",{staticStyle:{"margin-top":"-20px"}},[null!==e.activeMsg?t("el-row",{attrs:{gutter:10}},[t("el-col",{attrs:{span:24}},[t("div",{staticStyle:{padding:"0 0 22px 0"}},[t("el-alert",{staticClass:"my-el-alert",attrs:{closable:!1,"show-icon":"",center:"",title:e.activeMsg.module,type:"VER"===e.activeMsg.sys_type?"success":"warning"}})],1),t("el-form",{staticClass:"demo-table-expand",staticStyle:{"padding-left":"25px"},attrs:{size:"mini","label-position":"left","label-width":"82px"}},[t("el-row",["VER"===e.activeMsg.sys_type?t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:"版本编号:"}},[t("p",{staticStyle:{margin:"0"}},[e._v(e._s(e.activeMsg.version))])])],1):e._e(),t("el-col",{attrs:{span:"VER"===e.activeMsg.sys_type?12:24}},[t("el-form-item",{attrs:{label:"VER"===e.activeMsg.sys_type?"更新时间:":"预计时间:"}},[t("p",{staticStyle:{margin:"0"}},[e._v(" "+e._s(e.activeMsg.addtime)+" ")])])],1),t("el-col",{attrs:{span:24}},[t("el-form-item",{attrs:{label:"更新内容:"}},[t("p",{staticStyle:{margin:"0"},domProps:{innerHTML:e._s(e.activeMsg.system)}})])],1),t("el-col",{staticStyle:{"text-align":"right"},attrs:{span:24}},[t("el-checkbox",{staticClass:"fl",staticStyle:{"padding-top":"5px"},model:{value:e.checked,callback:function(t){e.checked=t},expression:"checked"}},[e._v("我已知晓,后续不再提示!")]),t("el-button",{attrs:{type:"primary",plain:""},on:{click:e.submit}},[e._v("关闭 ")])],1)],1)],1)],1)],1):e._e()],1)],1)],1)}),[],!1,null,"548a3622",null).exports),p={name:"SidebarLogo",props:{collapse:{type:Boolean,required:!0}},data:function(){return{title:"五常稻田"}}},c=(n("c6bb"),Object(a.a)(p,(function(){var e=this,t=e._self._c;return t("div",{staticClass:"sidebar-logo-container",class:{collapse:e.collapse}},[t("transition",{attrs:{name:"sidebarLogoFade"}},[t("router-link",e.collapse?{key:"collapse",staticClass:"sidebar-logo-link",attrs:{to:"/welcome/dashboard"}}:{key:"expand",staticClass:"sidebar-logo-link",attrs:{to:"/welcome/dashboard"}},[t("h1",{staticClass:"sidebar-title"},[e._v(e._s(e.title))])])],1)],1)}),[],!1,null,"0f67a8c7",null).exports),p=n("df7c"),n.n(p)),g=n("61f7"),v=(p=(n("caad"),n("2532"),{name:"MenuItem",functional:!0,props:{icon:{type:String,default:""},title:{type:String,default:""}},render:function(e,t){t=t.props;var n=t.icon,i=(t=t.title,[]);return n&&(n.includes("el-icon")?i.push(e("i",{class:[n,"sub-el-icon"]})):i.push(e("svg-icon",{attrs:{"icon-class":n}}))),t&&i.push(e("span",{slot:"title"},[t])),i}}),p=(n("3658"),Object(a.a)(p,void 0,void 0,!1,null,"4f8af8bb",null).exports),{props:{to:{type:String,required:!0}},computed:{isExternal:function(){return Object(g.d)(this.to)},type:function(){return this.isExternal?"a":"router-link"}},methods:{linkProps:function(e){return this.isExternal?{href:e,target:"_blank",rel:"noopener"}:{to:e}}}}),w=(p={name:"SidebarItem",components:{Item:p,AppLink:Object(a.a)(v,(function(){var e=this;return(0,e._self._c)(e.type,e._b({tag:"component"},"component",e.linkProps(e.to),!1),[e._t("default")],2)}),[],!1,null,null,null).exports},mixins:[{computed:{device:function(){return this.$store.state.app.device}},mounted:function(){this.fixBugIniOS()},methods:{fixBugIniOS:function(){var e,t=this,n=this.$refs.subMenu;n&&(e=n.handleMouseleave,n.handleMouseleave=function(n){"mobile"!==t.device&&e(n)})}}}],props:{item:{type:Object,required:!0},isNest:{type:Boolean,default:!1},basePath:{type:String,default:""}},data:function(){return this.onlyOneChild=null,{}},methods:{hasOneShowingChild:function(){var e=this,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[],n=1<arguments.length?arguments[1]:void 0;t=t.filter((function(t){return!t.hidden&&(e.onlyOneChild=t,!0)}));return 1===t.length||0===t.length&&(this.onlyOneChild=Object(i.a)(Object(i.a)({},n),{},{path:"",noShowingChildren:!0}),!0)},resolvePath:function(e){return Object(g.d)(e)?e:Object(g.d)(this.basePath)?this.basePath:b.a.resolve(this.basePath,e)}}},v=Object(a.a)(p,(function(){var e=this,t=e._self._c;return e.item.hidden?t("div",[e._v(e._s(e.item))]):t("div",[!e.hasOneShowingChild(e.item.children,e.item)||e.onlyOneChild.children&&!e.onlyOneChild.noShowingChildren||e.item.alwaysShow?t("el-submenu",{ref:"subMenu",attrs:{index:e.resolvePath(e.item.path),"popper-append-to-body":""}},[t("template",{slot:"title"},[e.item.meta?t("item",{attrs:{icon:e.item.meta&&e.item.meta.icon,title:e.item.meta.title}}):e._e()],1),e._l(e.item.children,(function(n){return t("sidebar-item",{key:n.path,staticClass:"nest-menu",attrs:{"is-nest":!0,item:n,"base-path":e.resolvePath(n.path)}})}))],2):[e.onlyOneChild.meta?t("app-link",{attrs:{to:e.resolvePath(e.onlyOneChild.path)}},[t("el-menu-item",{class:{"submenu-title-noDropdown":!e.isNest},attrs:{index:e.resolvePath(e.onlyOneChild.path)}},[t("item",{attrs:{icon:e.onlyOneChild.meta.icon||e.item.meta&&e.item.meta.icon,title:e.onlyOneChild.meta.title}})],1)],1):e._e()]],2)}),[],!1,null,null,null).exports,p=n("cf1e"),n.n(p)),x=(p={components:{SidebarItem:v,Logo:c},computed:Object(i.a)(Object(i.a)({},Object(l.b)(["navList","sidebar"])),{},{activeMenu:function(){var e=this.$route,t=e.meta;return t.activeMenu||e.path},showLogo:function(){return!0},variables:function(){return w.a},isCollapse:function(){return!1;
  8. //! this.sidebar.opened;
  9. }})},v=Object(a.a)(p,(function(){var e=this,t=e._self._c;return t("div",{class:{"has-logo":e.showLogo}},[e.showLogo?t("logo",{attrs:{collapse:e.isCollapse}}):e._e(),t("el-scrollbar",{attrs:{"wrap-class":"scrollbar-wrapper"}},[t("el-menu",{attrs:{"default-active":e.activeMenu,collapse:e.isCollapse,"background-color":e.variables.menuBg,"text-color":e.variables.menuText,"unique-opened":!1,"active-text-color":e.variables.menuActiveText,"collapse-transition":!1,mode:"vertical"}},e._l(e.navList,(function(e){return t("sidebar-item",{key:e.path,attrs:{item:e,"base-path":e.path}})})),1)],1)],1)}),[],!1,null,null,null).exports,n("b85c")),y=n("2909"),k=(c=(n("fb6a"),n("ac1f"),n("5319"),n("159b"),n("c740"),{name:"ScrollPane",data:function(){return{left:0}},computed:{scrollWrapper:function(){return this.$refs.scrollContainer.$refs.wrap}},mounted:function(){this.scrollWrapper.addEventListener("scroll",this.emitScroll,!0)},beforeDestroy:function(){this.scrollWrapper.removeEventListener("scroll",this.emitScroll)},methods:{handleScroll:function(e){e=e.wheelDelta||40*-e.deltaY;var t=this.scrollWrapper;t.scrollLeft=t.scrollLeft+e/4},emitScroll:function(){this.$emit("scroll")},moveToTarget:function(e){var t=this.$refs.scrollContainer.$el.offsetWidth,n=this.scrollWrapper,i=this.$parent.$refs.tag,r=null,a=null;0<i.length&&(r=i[0],a=i[i.length-1]),r===e?n.scrollLeft=0:a===e?n.scrollLeft=n.scrollWidth-t:(r=i.findIndex((function(t){return t===e})),a=i[r-1],r=(i=i[r+1]).$el.offsetLeft+i.$el.offsetWidth+4,i=a.$el.offsetLeft-4,r>n.scrollLeft+t?n.scrollLeft=r-t:i<n.scrollLeft&&(n.scrollLeft=i))}}}),p=(n("2489"),{components:{ScrollPane:Object(a.a)(c,(function(){var e=this;return(0,e._self._c)("el-scrollbar",{ref:"scrollContainer",staticClass:"scroll-container",attrs:{vertical:!1},nativeOn:{wheel:function(t){return t.preventDefault(),e.handleScroll.apply(null,arguments)}}},[e._t("default")],2)}),[],!1,null,"1a78fbad",null).exports},data:function(){return{visible:!1,top:0,left:0,selectedTag:{},affixTags:[]}},computed:{visitedViews:function(){return this.$store.state.tagsView.visitedViews},routes:function(){return this.$store.state.user.btnList}},watch:{$route:function(){this.addTags(),this.moveToCurrentTag()},visible:function(e){e?document.body.addEventListener("click",this.closeMenu):document.body.removeEventListener("click",this.closeMenu)}},mounted:function(){this.initTags(),this.addTags()},methods:{isActive:function(e){return e.path===this.$route.path},isAffix:function(e){return e.meta&&e.meta.affix},filterAffixTags:function(e){var t=this,n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"/",r=[];return e.forEach((function(e){var a;e.meta&&e.meta.affix&&(a=b.a.resolve(n,e.path),r.push({fullPath:a,path:a,name:e.name,meta:Object(i.a)({},e.meta)})),e.children&&1<=(a=t.filterAffixTags(e.children,e.path)).length&&(r=[].concat(Object(y.a)(r),Object(y.a)(a)))})),r},initTags:function(){var e,t=this.affixTags=this.filterAffixTags(this.routes),n=Object(x.a)(t);try{for(n.s();!(e=n.n()).done;){var i=e.value;i.name&&this.$store.dispatch("tagsView/addVisitedView",i)}}catch(e){n.e(e)}finally{n.f()}},addTags:function(){return this.$route.name&&this.$store.dispatch("tagsView/addView",this.$route),!1},moveToCurrentTag:function(){var e=this,t=this.$refs.tag;this.$nextTick((function(){var n,i=Object(x.a)(t);try{for(i.s();!(n=i.n()).done;){var r=n.value;if(r.to.path===e.$route.path){e.$refs.scrollPane.moveToTarget(r),r.to.fullPath!==e.$route.fullPath&&e.$store.dispatch("tagsView/updateVisitedView",e.$route);break}}}catch(n){i.e(n)}finally{i.f()}}))},refreshSelectedTag:function(e){var t=this;this.$store.dispatch("tagsView/delCachedView",e).then((function(){var n=e.fullPath;t.$nextTick((function(){t.$router.replace({path:"/redirect"+n})}))}))},closeSelectedTag:function(e){var t=this;this.$store.dispatch("tagsView/delView",e).then((function(n){n=n.visitedViews,t.isActive(e)&&t.toLastView(n,e)}))},closeOthersTags:function(){var e=this;window.vm.$router.push(this.selectedTag),this.$store.dispatch("tagsView/delOthersViews",this.selectedTag).then((function(){e.moveToCurrentTag()}))},closeAllTags:function(e){var t=this;this.$store.dispatch("tagsView/delAllViews").then((function(n){n=n.visitedViews,t.affixTags.some((function(t){return t.path===e.path}))||t.toLastView(n,e)}))},toLastView:function(e,t){e=e.slice(-1)[0],e?window.vm.$router.push(e.fullPath):"Dashboard"===t.name?this.$router.replace({path:"/redirect"+t.fullPath}):window.vm.$router.push("/welcome/dashboard")},openMenu:function(e,t){var n=this.$el.getBoundingClientRect().left,i=this.$el.offsetWidth-105;n=t.clientX-n+15;this.left=i<n?i:n,this.top=t.clientY,this.visible=!0,this.selectedTag=e},closeMenu:function(){this.visible=!1},handleScroll:function(){this.closeMenu()}}}),c=(n("69f0"),n("ad76"),Object(a.a)(p,(function(){var e=this,t=e._self._c;return t("div",{staticClass:"tags-view-container",attrs:{id:"tags-view-container"}},[t("scroll-pane",{ref:"scrollPane",staticClass:"tags-view-wrapper",on:{scroll:e.handleScroll}},e._l(e.visitedViews,(function(n){return t("router-link",{key:n.path,ref:"tag",refInFor:!0,staticClass:"tags-view-item",class:e.isActive(n)?"active":"",attrs:{to:{path:n.path,query:n.query,fullPath:n.fullPath},tag:"span"},nativeOn:{mouseup:function(t){if("button"in t&&1!==t.button)return null;e.isAffix(n)||e.closeSelectedTag(n)},contextmenu:function(t){return t.preventDefault(),e.openMenu(n,t)}}},[e._v(" "+e._s(n.title)+" "),e.isAffix(n)?e._e():t("span",{staticClass:"el-icon-close",on:{click:function(t){return t.preventDefault(),t.stopPropagation(),e.closeSelectedTag(n)}}})])})),1),t("ul",{directives:[{name:"show",rawName:"v-show",value:e.visible,expression:"visible"}],staticClass:"contextmenu",style:{left:e.left+"px",top:e.top+"px"}},[t("li",{on:{click:function(t){return e.refreshSelectedTag(e.selectedTag)}}},[e._v("Refresh")]),e.isAffix(e.selectedTag)?e._e():t("li",{on:{click:function(t){return e.closeSelectedTag(e.selectedTag)}}},[e._v(" Close ")]),t("li",{on:{click:e.closeOthersTags}},[e._v("Close Others")]),t("li",{on:{click:function(t){return e.closeAllTags(e.selectedTag)}}},[e._v("Close All")])])],1)}),[],!1,null,"30c67c78",null).exports),n("4360")),O=document.body;p={name:"Layout",components:{AppMain:r,Navbar:f,Sidebar:v,TagsView:c},mixins:[{watch:{$route:function(e){"mobile"===this.device&&this.sidebar.opened&&k.a.dispatch("app/closeSideBar",{withoutAnimation:!1})}},beforeMount:function(){window.addEventListener("resize",this.$_resizeHandler)},beforeDestroy:function(){window.removeEventListener("resize",this.$_resizeHandler)},mounted:function(){this.$_isMobile()&&(k.a.dispatch("app/toggleDevice","mobile"),k.a.dispatch("app/closeSideBar",{withoutAnimation:!0}))},methods:{$_isMobile:function(){return O.getBoundingClientRect().width-1<992},$_resizeHandler:function(){var e;document.hidden||(e=this.$_isMobile(),k.a.dispatch("app/toggleDevice",e?"mobile":"desktop"),e&&k.a.dispatch("app/closeSideBar",{withoutAnimation:!0}))}}}],computed:Object(i.a)(Object(i.a)({},Object(l.c)({sidebar:function(e){return e.app.sidebar},device:function(e){return e.app.device},showSettings:function(e){return e.settings.showSettings},needTagsView:function(e){return e.settings.tagsView},fixedHeader:function(e){return e.settings.fixedHeader}})),{},{classObj:function(){return{hideSidebar:!1,openSidebar:this.sidebar.opened,withoutAnimation:this.sidebar.withoutAnimation,mobile:!1}}}),methods:{handleClickOutside:function(){this.$store.dispatch("app/closeSideBar",{withoutAnimation:!1})}}},n("82f9"),r=Object(a.a)(p,(function(){var e=this,t=e._self._c;return t("div",{staticClass:"app-wrapper",class:e.classObj},[t("sidebar",{staticClass:"sidebar-container"}),t("div",{staticClass:"main-container",class:{hasTagsView:e.needTagsView}},[t("div",{class:{"fixed-header":e.fixedHeader}},[t("navbar"),e.needTagsView?t("tags-view"):e._e()],1),t("app-main")],1)],1)}),[],!1,null,"1955cf2e",null);t.default=r.exports},c6bb:function(e,t,n){n("32a4")},c740:function(e,t,n){var i=n("23e7"),r=n("b727").findIndex,a=n("44d2"),s=(n=n("ae40"),"findIndex"),o=!0;n=n(s);s in[]&&Array(1)[s]((function(){o=!1})),i({target:"Array",proto:!0,forced:o||!n},{findIndex:function(e){return r(this,e,1<arguments.length?arguments[1]:void 0)}}),a(s)},cf1e:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409EFF",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},df7c:function(e,t,n){(function(e){function n(e,t){for(var n=0,i=e.length-1;0<=i;i--){var r=e[i];"."===r?e.splice(i,1):".."===r?(e.splice(i,1),n++):n&&(e.splice(i,1),n--)}if(t)for(;n--;)e.unshift("..");return e}function i(e,t){if(e.filter)return e.filter(t);for(var n=[],i=0;i<e.length;i++)t(e[i],i,e)&&n.push(e[i]);return n}t.resolve=function(){for(var t="",r=!1,a=arguments.length-1;-1<=a&&!r;a--){var s=0<=a?arguments[a]:e.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(t=s+"/"+t,r="/"===s.charAt(0))}return(r?"/":"")+(t=n(i(t.split("/"),(function(e){return!!e})),!r).join("/"))||"."},t.normalize=function(e){var a=t.isAbsolute(e),s="/"===r(e,-1);return(e=(e=n(i(e.split("/"),(function(e){return!!e})),!a).join("/"))||a?e:".")&&s&&(e+="/"),(a?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(i(e,(function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,n){function i(e){for(var t=0;t<e.length&&""===e[t];t++);for(var n=e.length-1;0<=n&&""===e[n];n--);return n<t?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var r=i(e.split("/")),a=i(n.split("/")),s=Math.min(r.length,a.length),o=s,l=0;l<s;l++)if(r[l]!==a[l]){o=l;break}var c=[];for(l=o;l<r.length;l++)c.push("..");return(c=c.concat(a.slice(o))).join("/")},t.sep="/",t.delimiter=":",t.dirname=function(e){if("string"!=typeof e&&(e+=""),0===e.length)return".";for(var t=47===e.charCodeAt(0),n=-1,i=!0,r=e.length-1;1<=r;--r)if(47===e.charCodeAt(r)){if(!i){n=r;break}}else i=!1;return-1===n?t?"/":".":t&&1===n?"/":e.slice(0,n)},t.basename=function(e,t){return e=(e=>{"string"!=typeof e&&(e+="");for(var t=0,n=-1,i=!0,r=e.length-1;0<=r;--r)if(47===e.charCodeAt(r)){if(!i){t=r+1;break}}else-1===n&&(i=!1,n=r+1);return-1===n?"":e.slice(t,n)})(e),t&&e.substr(-1*t.length)===t?e.substr(0,e.length-t.length):e},t.extname=function(e){"string"!=typeof e&&(e+="");for(var t=-1,n=0,i=-1,r=!0,a=0,s=e.length-1;0<=s;--s){var o=e.charCodeAt(s);if(47===o){if(r)continue;n=s+1;break}-1===i&&(r=!1,i=s+1),46===o?-1===t?t=s:1!==a&&(a=1):-1!==t&&(a=-1)}return-1===t||-1===i||0===a||1===a&&t===i-1&&t===n+1?"":e.slice(t,i)};var r="b"==="ab".substr(-1)?function(e,t,n){return e.substr(t,n)}:function(e,t,n){return t<0&&(t=e.length+t),e.substr(t,n)}}).call(this,n("4362"))}}]);