diff --git a/webroot/index.html b/webroot/index.html index d19a2e3..1a0d9ec 100644 --- a/webroot/index.html +++ b/webroot/index.html @@ -1 +1 @@ -通用采集器系统
\ No newline at end of file +通用采集器系统
\ No newline at end of file diff --git a/webroot/static/css/chunk-495d4d48.020b6379.css b/webroot/static/css/chunk-495d4d48.020b6379.css deleted file mode 100644 index a65f2e4..0000000 --- a/webroot/static/css/chunk-495d4d48.020b6379.css +++ /dev/null @@ -1 +0,0 @@ -.card-panel-icon[data-v-6d214a14]{float:left;font-size:48px;width:50%;display:block;margin-bottom:10px;color:#f4516c}.text[data-v-6d214a14]{font-size:14px}.item[data-v-6d214a14]{margin-bottom:18px;display:-webkit-box;display:-ms-flexbox;display:flex} \ No newline at end of file diff --git a/webroot/static/css/chunk-58fe3d45.de7c3763.css b/webroot/static/css/chunk-58fe3d45.de7c3763.css new file mode 100644 index 0000000..0bdbfdf --- /dev/null +++ b/webroot/static/css/chunk-58fe3d45.de7c3763.css @@ -0,0 +1 @@ +.card-panel-icon[data-v-519aaf7f]{float:left;font-size:48px;width:50%;display:block;margin-bottom:10px;color:#f4516c}.text[data-v-519aaf7f]{font-size:14px}.item[data-v-519aaf7f]{margin-bottom:18px;display:-webkit-box;display:-ms-flexbox;display:flex} \ No newline at end of file diff --git a/webroot/static/js/app.5c3201c6.js b/webroot/static/js/app.fca4d47b.js similarity index 99% rename from webroot/static/js/app.5c3201c6.js rename to webroot/static/js/app.fca4d47b.js index 5707ed3..f3d9ec7 100644 --- a/webroot/static/js/app.5c3201c6.js +++ b/webroot/static/js/app.fca4d47b.js @@ -1 +1 @@ -(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["app"],{0:function(e,t,n){e.exports=n("56d7")},"028b":function(e,t,n){"use strict";var a=n("f12c"),i=n.n(a);i.a},1343:function(e,t,n){},"14b4":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-memory",use:"icon-memory-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},1605:function(e,t,n){e.exports=n.p+"static/img/admin.ecba1844.gif"},"186a":function(e,t,n){"use strict";var a=n("dc52"),i=n.n(a);i.a},"18f0":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-link",use:"icon-link-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"1b2d":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-interface",use:"icon-interface-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},2753:function(e,t,n){"use strict";var a=n("1343"),i=n.n(a);i.a},"2a3d":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-password",use:"icon-password-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"30c3":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-example",use:"icon-example-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"47f1":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-table",use:"icon-table-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"4cdc":function(e,t,n){},"4df5":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-eye",use:"icon-eye-usage",viewBox:"0 0 128 64",content:''});c.a.add(r);t["default"]=r},"51ff":function(e,t,n){var a={"./dashboard.svg":"f782","./deviceManage.svg":"c504","./deviceStatus.svg":"b37b","./example.svg":"30c3","./eye-open.svg":"d7ec","./eye.svg":"4df5","./form.svg":"eb1b","./interface.svg":"1b2d","./link.svg":"18f0","./memory.svg":"14b4","./nested.svg":"dcf8","./password.svg":"2a3d","./table.svg":"47f1","./template.svg":"dcbb","./tree.svg":"93cd","./user.svg":"b3b5","./wireless.svg":"f117"};function i(e){var t=o(e);return n(t)}function o(e){var t=a[e];if(!(t+1)){var n=new Error("Cannot find module '"+e+"'");throw n.code="MODULE_NOT_FOUND",n}return t}i.keys=function(){return Object.keys(a)},i.resolve=o,e.exports=i,i.id="51ff"},"56d7":function(e,t,n){"use strict";n.r(t);n("96cf");var a=n("3b8d"),i=(n("cadf"),n("551c"),n("f751"),n("097d"),n("2b0e")),o=(n("f5df"),n("5c96")),c=n.n(o),r=(n("0fae"),n("f0d9")),s=n.n(r),l=(n("b20f"),function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{attrs:{id:"app"}},[n("router-view")],1)}),u=[],d={name:"App"},m=d,h=n("2877"),p=Object(h["a"])(m,l,u,!1,null,null,null),f=p.exports,v=n("bc3a"),b=n.n(v),g=n("2f62"),w=(n("7f7f"),{sidebar:function(e){return e.app.sidebar},device:function(e){return e.app.device},token:function(e){return e.user.token},avatar:function(e){return e.user.avatar},name:function(e){return e.user.name}}),x=w,y=n("a78e"),k=n.n(y),M={sidebar:{opened:!k.a.get("sidebarStatus")||!!+k.a.get("sidebarStatus"),withoutAnimation:!1},device:"desktop"},z={TOGGLE_SIDEBAR:function(e){e.sidebar.opened=!e.sidebar.opened,e.sidebar.withoutAnimation=!1,e.sidebar.opened?k.a.set("sidebarStatus",1):k.a.set("sidebarStatus",0)},CLOSE_SIDEBAR:function(e,t){k.a.set("sidebarStatus",0),e.sidebar.opened=!1,e.sidebar.withoutAnimation=t},TOGGLE_DEVICE:function(e,t){e.device=t}},_={toggleSideBar:function(e){var t=e.commit;t("TOGGLE_SIDEBAR")},closeSideBar:function(e,t){var n=e.commit,a=t.withoutAnimation;n("CLOSE_SIDEBAR",a)},toggleDevice:function(e,t){var n=e.commit;n("TOGGLE_DEVICE",t)}},C={namespaced:!0,state:M,mutations:z,actions:_},S=n("83d6"),H=n.n(S),E=H.a.showSettings,B=H.a.fixedHeader,O=H.a.sidebarLogo,T={showSettings:E,fixedHeader:B,sidebarLogo:O},L={CHANGE_SETTING:function(e,t){var n=t.key,a=t.value;e.hasOwnProperty(n)&&(e[n]=a)}},V={changeSetting:function(e,t){var n=e.commit;n("CHANGE_SETTING",t)}},A={namespaced:!0,state:T,mutations:L,actions:V},$="token";function j(){return k.a.get($)}function D(e){return k.a.set($,e)}function R(){return k.a.remove($)}var I=b.a.create({timeout:5e3});I.interceptors.request.use((function(e){return yt.getters.token&&(e.headers["token"]=j()),e}),(function(e){return console.log(e),Promise.reject(e)})),I.interceptors.response.use((function(e){var t=e.data;return t}),(function(e){return console.log("err"+e),Object(o["Message"])({message:e.message,type:"error",duration:5e3}),Promise.reject(e)}));var N=I;function P(e){var t="";return t="/api/v1/system/login",N({url:t,method:"post",data:e})}function q(e){var t="";return t="/api/v1/system/loginParam",N({url:t,method:"get",params:{}})}function G(){var e="";return e="/api/v1/system/reboot",N({url:e,method:"post"})}console.log("当前环境:production");n("3b2b"),n("a481");var F,U,K=n("8c4f"),J=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"app-wrapper",class:e.classObj},["mobile"===e.device&&e.sidebar.opened?n("div",{staticClass:"drawer-bg",on:{click:e.handleClickOutside}}):e._e(),e._v(" "),n("sidebar",{staticClass:"sidebar-container"}),e._v(" "),n("div",{staticClass:"main-container"},[n("div",{class:{"fixed-header":e.fixedHeader}},[n("navbar")],1),e._v(" "),n("app-main")],1)],1)},W=[],Y=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"navbar"},[a("hamburger",{staticClass:"hamburger-container",attrs:{"is-active":e.sidebar.opened},on:{toggleClick:e.toggleSideBar}}),e._v(" "),a("breadcrumb",{staticClass:"breadcrumb-container"}),e._v(" "),a("div",{staticClass:"right-menu"},[a("el-dropdown",{staticClass:"avatar-container",attrs:{trigger:"click"}},[a("div",{staticClass:"avatar-wrapper"},[a("img",{staticClass:"user-avatar",attrs:{src:n("1605")}}),e._v(" "),a("i",{staticClass:"el-icon-caret-bottom"})]),e._v(" "),a("el-dropdown-menu",{staticClass:"user-dropdown",attrs:{slot:"dropdown"},slot:"dropdown"},[a("router-link",{attrs:{to:"/"}},[a("el-dropdown-item",[e._v("\n 回到首页\n ")])],1),e._v(" "),a("el-dropdown-item",{attrs:{divided:""}},[a("span",{staticStyle:{display:"block"},on:{click:e.logout}},[e._v("重启系统")])])],1)],1)],1)],1)},Q=[],X=n("db72"),Z=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-breadcrumb",{staticClass:"app-breadcrumb",attrs:{separator:"/"}},[n("transition-group",{attrs:{name:"breadcrumb"}},e._l(e.levelList,(function(t,a){return n("el-breadcrumb-item",{key:t.path},["noRedirect"===t.redirect||a==e.levelList.length-1?n("span",{staticClass:"no-redirect"},[e._v(e._s(t.meta.title))]):n("a",{on:{click:function(n){return n.preventDefault(),e.handleLink(t)}}},[e._v(e._s(t.meta.title))])])})),1)],1)},ee=[],te=n("bd11"),ne=n.n(te),ae={data:function(){return{levelList:null}},watch:{$route:function(){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:"/dashboard",meta:{title:"首页"}}].concat(e)),this.levelList=e.filter((function(e){return e.meta&&e.meta.title&&!1!==e.meta.breadcrumb}))},isDashboard:function(e){var t=e&&e.name;return!!t&&t.trim().toLocaleLowerCase()==="Dashboard".toLocaleLowerCase()},pathCompile:function(e){var t=this.$route.params,n=ne.a.compile(e);return n(t)},handleLink:function(e){var t=e.redirect,n=e.path;t?this.$router.push(t):this.$router.push(this.pathCompile(n))}}},ie=ae,oe=(n("976b"),Object(h["a"])(ie,Z,ee,!1,null,"33d79dae",null)),ce=oe.exports,re=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticStyle:{padding:"0 15px"},on:{click:e.toggleClick}},[n("svg",{staticClass:"hamburger",class:{"is-active":e.isActive},attrs:{viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg",width:"64",height:"64"}},[n("path",{attrs:{d:"M408 442h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8zm-8 204c0 4.4 3.6 8 8 8h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56zm504-486H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 632H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM142.4 642.1L298.7 519a8.84 8.84 0 0 0 0-13.9L142.4 381.9c-5.8-4.6-14.4-.5-14.4 6.9v246.3a8.9 8.9 0 0 0 14.4 7z"}})])])},se=[],le={name:"Hamburger",props:{isActive:{type:Boolean,default:!1}},methods:{toggleClick:function(){this.$emit("toggleClick")}}},ue=le,de=(n("186a"),Object(h["a"])(ue,re,se,!1,null,"49e15297",null)),me=de.exports,he={components:{Breadcrumb:ce,Hamburger:me},computed:Object(X["a"])({},Object(g["b"])(["sidebar","avatar"])),methods:{toggleSideBar:function(){this.$store.dispatch("app/toggleSideBar")},logout:function(){var e=Object(a["a"])(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.$store.dispatch("user/logout");case 2:this.$router.push("/login");case 3:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()}},pe=he,fe=(n("2753"),Object(h["a"])(pe,Y,Q,!1,null,"d179ddf0",null)),ve=fe.exports,be=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{class:{"has-logo":e.showLogo}},[e.showLogo?n("logo",{attrs:{collapse:e.isCollapse}}):e._e(),e._v(" "),n("el-scrollbar",{attrs:{"wrap-class":"scrollbar-wrapper"}},[n("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.routes,(function(e){return n("sidebar-item",{key:e.path,attrs:{item:e,"base-path":e.path}})})),1)],1)],1)},ge=[],we=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"sidebar-logo-container",class:{collapse:e.collapse}},[n("transition",{attrs:{name:"sidebarLogoFade"}},[e.collapse?n("router-link",{key:"collapse",staticClass:"sidebar-logo-link",attrs:{to:"/"}},[e.logo?n("img",{staticClass:"sidebar-logo",attrs:{src:e.logo}}):n("h1",{staticClass:"sidebar-title"},[e._v(e._s(e.title)+" ")])]):n("router-link",{key:"expand",staticClass:"sidebar-logo-link",attrs:{to:"/"}},[e.logo?n("img",{staticClass:"sidebar-logo",attrs:{src:e.logo}}):e._e(),e._v(" "),n("h1",{staticClass:"sidebar-title"},[e._v(e._s(e.title)+" ")])])],1)],1)},xe=[],ye={name:"SidebarLogo",props:{collapse:{type:Boolean,required:!0}},data:function(){return{title:"Vue Admin Template",logo:"https://wpimg.wallstcn.com/69a1c46c-eb1c-4b46-8bd4-e9e686ef5251.png"}}},ke=ye,Me=(n("6b31"),Object(h["a"])(ke,we,xe,!1,null,"5bb1c0e2",null)),ze=Me.exports,_e=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.item.hidden?e._e():n("div",{staticClass:"menu-wrapper"},[!e.hasOneShowingChild(e.item.children,e.item)||e.onlyOneChild.children&&!e.onlyOneChild.noShowingChildren||e.item.alwaysShow?n("el-submenu",{ref:"subMenu",attrs:{index:e.resolvePath(e.item.path),"popper-append-to-body":""}},[n("template",{slot:"title"},[e.item.meta?n("item",{attrs:{icon:e.item.meta&&e.item.meta.icon,title:e.item.meta.title}}):e._e()],1),e._v(" "),e._l(e.item.children,(function(t){return n("sidebar-item",{key:t.path,staticClass:"nest-menu",attrs:{"is-nest":!0,item:t,"base-path":e.resolvePath(t.path)}})}))],2):[e.onlyOneChild.meta?n("app-link",{attrs:{to:e.resolvePath(e.onlyOneChild.path)}},[n("el-menu-item",{class:{"submenu-title-noDropdown":!e.isNest},attrs:{index:e.resolvePath(e.onlyOneChild.path)}},[n("item",{attrs:{icon:e.onlyOneChild.meta.icon||e.item.meta&&e.item.meta.icon,title:e.onlyOneChild.meta.title}})],1)],1):e._e()]],2)},Ce=[],Se=n("df7c"),He=n.n(Se),Ee=n("61f7"),Be={name:"MenuItem",functional:!0,props:{icon:{type:String,default:""},title:{type:String,default:""}},render:function(e,t){var n=t.props,a=n.icon,i=n.title,o=[];return a&&o.push(e("svg-icon",{attrs:{"icon-class":a}})),i&&o.push(e("span",{slot:"title"},[i])),o}},Oe=Be,Te=Object(h["a"])(Oe,F,U,!1,null,null,null),Le=Te.exports,Ve=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("component",e._b({},"component",e.linkProps(e.to),!1),[e._t("default")],2)},Ae=[],$e={props:{to:{type:String,required:!0}},methods:{linkProps:function(e){return Object(Ee["a"])(e)?{is:"a",href:e,target:"_blank",rel:"noopener"}:{is:"router-link",to:e}}}},je=$e,De=Object(h["a"])(je,Ve,Ae,!1,null,null,null),Re=De.exports,Ie={computed:{device:function(){return this.$store.state.app.device}},mounted:function(){this.fixBugIniOS()},methods:{fixBugIniOS:function(){var e=this,t=this.$refs.subMenu;if(t){var n=t.handleMouseleave;t.handleMouseleave=function(t){"mobile"!==e.device&&n(t)}}}}},Ne={name:"SidebarItem",components:{Item:Le,AppLink:Re},mixins:[Ie],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=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1?arguments[1]:void 0,a=t.filter((function(t){return!t.hidden&&(e.onlyOneChild=t,!0)}));return 1===a.length||0===a.length&&(this.onlyOneChild=Object(X["a"])(Object(X["a"])({},n),{},{path:"",noShowingChildren:!0}),!0)},resolvePath:function(e){return Object(Ee["a"])(e)?e:Object(Ee["a"])(this.basePath)?this.basePath:He.a.resolve(this.basePath,e)}}},Pe=Ne,qe=Object(h["a"])(Pe,_e,Ce,!1,null,null,null),Ge=qe.exports,Fe=n("cf1e"),Ue=n.n(Fe),Ke={components:{SidebarItem:Ge,Logo:ze},computed:Object(X["a"])(Object(X["a"])({},Object(g["b"])(["sidebar"])),{},{routes:function(){return this.$router.options.routes},activeMenu:function(){var e=this.$route,t=e.meta,n=e.path;return t.activeMenu?t.activeMenu:n},showLogo:function(){return this.$store.state.settings.sidebarLogo},variables:function(){return Ue.a},isCollapse:function(){return!this.sidebar.opened}})},Je=Ke,We=Object(h["a"])(Je,be,ge,!1,null,null,null),Ye=We.exports,Qe=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"app-main"},[n("transition",{attrs:{name:"fade-transform",mode:"out-in"}},[n("router-view",{key:e.key})],1)],1)},Xe=[],Ze={name:"AppMain",computed:{key:function(){return this.$route.path}}},et=Ze,tt=(n("e4de"),n("028b"),Object(h["a"])(et,Qe,Xe,!1,null,"64cf4d83",null)),nt=tt.exports,at=document,it=at.body,ot=992,ct={watch:{$route:function(e){"mobile"===this.device&&this.sidebar.opened&&yt.dispatch("app/closeSideBar",{withoutAnimation:!1})}},beforeMount:function(){window.addEventListener("resize",this.$_resizeHandler)},beforeDestroy:function(){window.removeEventListener("resize",this.$_resizeHandler)},mounted:function(){var e=this.$_isMobile();e&&(yt.dispatch("app/toggleDevice","mobile"),yt.dispatch("app/closeSideBar",{withoutAnimation:!0}))},methods:{$_isMobile:function(){var e=it.getBoundingClientRect();return e.width-1=0}function o(e){var t=["admin","111111"];return t.indexOf(e.trim())>=0}n.d(t,"a",(function(){return a})),n.d(t,"c",(function(){return i})),n.d(t,"b",(function(){return o}))},"6b31":function(e,t,n){"use strict";var a=n("4cdc"),i=n.n(a);i.a},"83d6":function(e,t){e.exports={title:"通用采集器系统",fixedHeader:!1,sidebarLogo:!1}},8902:function(e,t,n){},"93cd":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-tree",use:"icon-tree-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"976b":function(e,t,n){"use strict";var a=n("f14a"),i=n.n(a);i.a},"9f2b":function(e,t,n){"use strict";var a=n("bf90"),i=n.n(a);i.a},b20f:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409EFF",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},b37b:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-deviceStatus",use:"icon-deviceStatus-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},b3b5:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-user",use:"icon-user-usage",viewBox:"0 0 130 130",content:''});c.a.add(r);t["default"]=r},bf90:function(e,t,n){},c504:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-deviceManage",use:"icon-deviceManage-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},cf1e:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409EFF",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},d27f:function(e,t,n){"use strict";var a=n("e176"),i=n.n(a);i.a},d7ec:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-eye-open",use:"icon-eye-open-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},dc52:function(e,t,n){},dcbb:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-template",use:"icon-template-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},dcf8:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-nested",use:"icon-nested-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},e176:function(e,t,n){},e4de:function(e,t,n){"use strict";var a=n("8902"),i=n.n(a);i.a},eb1b:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-form",use:"icon-form-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},f117:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-wireless",use:"icon-wireless-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},f12c:function(e,t,n){},f14a:function(e,t,n){},f782:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-dashboard",use:"icon-dashboard-usage",viewBox:"0 0 128 100",content:''});c.a.add(r);t["default"]=r}},[[0,"runtime","chunk-elementUI","chunk-libs"]]]); \ No newline at end of file +(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["app"],{0:function(e,t,n){e.exports=n("56d7")},"028b":function(e,t,n){"use strict";var a=n("f12c"),i=n.n(a);i.a},1343:function(e,t,n){},"14b4":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-memory",use:"icon-memory-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},1605:function(e,t,n){e.exports=n.p+"static/img/admin.ecba1844.gif"},"186a":function(e,t,n){"use strict";var a=n("dc52"),i=n.n(a);i.a},"18f0":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-link",use:"icon-link-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"1b2d":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-interface",use:"icon-interface-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},2753:function(e,t,n){"use strict";var a=n("1343"),i=n.n(a);i.a},"2a3d":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-password",use:"icon-password-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"30c3":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-example",use:"icon-example-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"47f1":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-table",use:"icon-table-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"4cdc":function(e,t,n){},"4df5":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-eye",use:"icon-eye-usage",viewBox:"0 0 128 64",content:''});c.a.add(r);t["default"]=r},"51ff":function(e,t,n){var a={"./dashboard.svg":"f782","./deviceManage.svg":"c504","./deviceStatus.svg":"b37b","./example.svg":"30c3","./eye-open.svg":"d7ec","./eye.svg":"4df5","./form.svg":"eb1b","./interface.svg":"1b2d","./link.svg":"18f0","./memory.svg":"14b4","./nested.svg":"dcf8","./password.svg":"2a3d","./table.svg":"47f1","./template.svg":"dcbb","./tree.svg":"93cd","./user.svg":"b3b5","./wireless.svg":"f117"};function i(e){var t=o(e);return n(t)}function o(e){var t=a[e];if(!(t+1)){var n=new Error("Cannot find module '"+e+"'");throw n.code="MODULE_NOT_FOUND",n}return t}i.keys=function(){return Object.keys(a)},i.resolve=o,e.exports=i,i.id="51ff"},"56d7":function(e,t,n){"use strict";n.r(t);n("96cf");var a=n("3b8d"),i=(n("cadf"),n("551c"),n("f751"),n("097d"),n("2b0e")),o=(n("f5df"),n("5c96")),c=n.n(o),r=(n("0fae"),n("f0d9")),s=n.n(r),l=(n("b20f"),function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{attrs:{id:"app"}},[n("router-view")],1)}),u=[],d={name:"App"},m=d,h=n("2877"),p=Object(h["a"])(m,l,u,!1,null,null,null),f=p.exports,v=n("bc3a"),b=n.n(v),g=n("2f62"),w=(n("7f7f"),{sidebar:function(e){return e.app.sidebar},device:function(e){return e.app.device},token:function(e){return e.user.token},avatar:function(e){return e.user.avatar},name:function(e){return e.user.name}}),x=w,y=n("a78e"),k=n.n(y),M={sidebar:{opened:!k.a.get("sidebarStatus")||!!+k.a.get("sidebarStatus"),withoutAnimation:!1},device:"desktop"},z={TOGGLE_SIDEBAR:function(e){e.sidebar.opened=!e.sidebar.opened,e.sidebar.withoutAnimation=!1,e.sidebar.opened?k.a.set("sidebarStatus",1):k.a.set("sidebarStatus",0)},CLOSE_SIDEBAR:function(e,t){k.a.set("sidebarStatus",0),e.sidebar.opened=!1,e.sidebar.withoutAnimation=t},TOGGLE_DEVICE:function(e,t){e.device=t}},_={toggleSideBar:function(e){var t=e.commit;t("TOGGLE_SIDEBAR")},closeSideBar:function(e,t){var n=e.commit,a=t.withoutAnimation;n("CLOSE_SIDEBAR",a)},toggleDevice:function(e,t){var n=e.commit;n("TOGGLE_DEVICE",t)}},C={namespaced:!0,state:M,mutations:z,actions:_},S=n("83d6"),H=n.n(S),E=H.a.showSettings,B=H.a.fixedHeader,O=H.a.sidebarLogo,T={showSettings:E,fixedHeader:B,sidebarLogo:O},L={CHANGE_SETTING:function(e,t){var n=t.key,a=t.value;e.hasOwnProperty(n)&&(e[n]=a)}},V={changeSetting:function(e,t){var n=e.commit;n("CHANGE_SETTING",t)}},A={namespaced:!0,state:T,mutations:L,actions:V},$="token";function j(){return k.a.get($)}function D(e){return k.a.set($,e)}function R(){return k.a.remove($)}var I=b.a.create({timeout:5e3});I.interceptors.request.use((function(e){return yt.getters.token&&(e.headers["token"]=j()),e}),(function(e){return console.log(e),Promise.reject(e)})),I.interceptors.response.use((function(e){var t=e.data;return t}),(function(e){return console.log("err"+e),Object(o["Message"])({message:e.message,type:"error",duration:5e3}),Promise.reject(e)}));var N=I;function P(e){var t="";return t="/api/v1/system/login",N({url:t,method:"post",data:e})}function q(e){var t="";return t="/api/v1/system/loginParam",N({url:t,method:"get",params:{}})}function G(){var e="";return e="/api/v1/system/reboot",N({url:e,method:"post"})}console.log("当前环境:production");n("3b2b"),n("a481");var F,U,K=n("8c4f"),J=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"app-wrapper",class:e.classObj},["mobile"===e.device&&e.sidebar.opened?n("div",{staticClass:"drawer-bg",on:{click:e.handleClickOutside}}):e._e(),e._v(" "),n("sidebar",{staticClass:"sidebar-container"}),e._v(" "),n("div",{staticClass:"main-container"},[n("div",{class:{"fixed-header":e.fixedHeader}},[n("navbar")],1),e._v(" "),n("app-main")],1)],1)},W=[],Y=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"navbar"},[a("hamburger",{staticClass:"hamburger-container",attrs:{"is-active":e.sidebar.opened},on:{toggleClick:e.toggleSideBar}}),e._v(" "),a("breadcrumb",{staticClass:"breadcrumb-container"}),e._v(" "),a("div",{staticClass:"right-menu"},[a("el-dropdown",{staticClass:"avatar-container",attrs:{trigger:"click"}},[a("div",{staticClass:"avatar-wrapper"},[a("img",{staticClass:"user-avatar",attrs:{src:n("1605")}}),e._v(" "),a("i",{staticClass:"el-icon-caret-bottom"})]),e._v(" "),a("el-dropdown-menu",{staticClass:"user-dropdown",attrs:{slot:"dropdown"},slot:"dropdown"},[a("router-link",{attrs:{to:"/"}},[a("el-dropdown-item",[e._v("\n 回到首页\n ")])],1),e._v(" "),a("el-dropdown-item",{attrs:{divided:""}},[a("span",{staticStyle:{display:"block"},on:{click:e.logout}},[e._v("重启系统")])])],1)],1)],1)],1)},Q=[],X=n("db72"),Z=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-breadcrumb",{staticClass:"app-breadcrumb",attrs:{separator:"/"}},[n("transition-group",{attrs:{name:"breadcrumb"}},e._l(e.levelList,(function(t,a){return n("el-breadcrumb-item",{key:t.path},["noRedirect"===t.redirect||a==e.levelList.length-1?n("span",{staticClass:"no-redirect"},[e._v(e._s(t.meta.title))]):n("a",{on:{click:function(n){return n.preventDefault(),e.handleLink(t)}}},[e._v(e._s(t.meta.title))])])})),1)],1)},ee=[],te=n("bd11"),ne=n.n(te),ae={data:function(){return{levelList:null}},watch:{$route:function(){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:"/dashboard",meta:{title:"首页"}}].concat(e)),this.levelList=e.filter((function(e){return e.meta&&e.meta.title&&!1!==e.meta.breadcrumb}))},isDashboard:function(e){var t=e&&e.name;return!!t&&t.trim().toLocaleLowerCase()==="Dashboard".toLocaleLowerCase()},pathCompile:function(e){var t=this.$route.params,n=ne.a.compile(e);return n(t)},handleLink:function(e){var t=e.redirect,n=e.path;t?this.$router.push(t):this.$router.push(this.pathCompile(n))}}},ie=ae,oe=(n("976b"),Object(h["a"])(ie,Z,ee,!1,null,"33d79dae",null)),ce=oe.exports,re=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticStyle:{padding:"0 15px"},on:{click:e.toggleClick}},[n("svg",{staticClass:"hamburger",class:{"is-active":e.isActive},attrs:{viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg",width:"64",height:"64"}},[n("path",{attrs:{d:"M408 442h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8zm-8 204c0 4.4 3.6 8 8 8h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56zm504-486H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 632H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM142.4 642.1L298.7 519a8.84 8.84 0 0 0 0-13.9L142.4 381.9c-5.8-4.6-14.4-.5-14.4 6.9v246.3a8.9 8.9 0 0 0 14.4 7z"}})])])},se=[],le={name:"Hamburger",props:{isActive:{type:Boolean,default:!1}},methods:{toggleClick:function(){this.$emit("toggleClick")}}},ue=le,de=(n("186a"),Object(h["a"])(ue,re,se,!1,null,"49e15297",null)),me=de.exports,he={components:{Breadcrumb:ce,Hamburger:me},computed:Object(X["a"])({},Object(g["b"])(["sidebar","avatar"])),methods:{toggleSideBar:function(){this.$store.dispatch("app/toggleSideBar")},logout:function(){var e=Object(a["a"])(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.$store.dispatch("user/logout");case 2:this.$router.push("/login");case 3:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()}},pe=he,fe=(n("2753"),Object(h["a"])(pe,Y,Q,!1,null,"d179ddf0",null)),ve=fe.exports,be=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{class:{"has-logo":e.showLogo}},[e.showLogo?n("logo",{attrs:{collapse:e.isCollapse}}):e._e(),e._v(" "),n("el-scrollbar",{attrs:{"wrap-class":"scrollbar-wrapper"}},[n("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.routes,(function(e){return n("sidebar-item",{key:e.path,attrs:{item:e,"base-path":e.path}})})),1)],1)],1)},ge=[],we=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"sidebar-logo-container",class:{collapse:e.collapse}},[n("transition",{attrs:{name:"sidebarLogoFade"}},[e.collapse?n("router-link",{key:"collapse",staticClass:"sidebar-logo-link",attrs:{to:"/"}},[e.logo?n("img",{staticClass:"sidebar-logo",attrs:{src:e.logo}}):n("h1",{staticClass:"sidebar-title"},[e._v(e._s(e.title)+" ")])]):n("router-link",{key:"expand",staticClass:"sidebar-logo-link",attrs:{to:"/"}},[e.logo?n("img",{staticClass:"sidebar-logo",attrs:{src:e.logo}}):e._e(),e._v(" "),n("h1",{staticClass:"sidebar-title"},[e._v(e._s(e.title)+" ")])])],1)],1)},xe=[],ye={name:"SidebarLogo",props:{collapse:{type:Boolean,required:!0}},data:function(){return{title:"Vue Admin Template",logo:"https://wpimg.wallstcn.com/69a1c46c-eb1c-4b46-8bd4-e9e686ef5251.png"}}},ke=ye,Me=(n("6b31"),Object(h["a"])(ke,we,xe,!1,null,"5bb1c0e2",null)),ze=Me.exports,_e=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.item.hidden?e._e():n("div",{staticClass:"menu-wrapper"},[!e.hasOneShowingChild(e.item.children,e.item)||e.onlyOneChild.children&&!e.onlyOneChild.noShowingChildren||e.item.alwaysShow?n("el-submenu",{ref:"subMenu",attrs:{index:e.resolvePath(e.item.path),"popper-append-to-body":""}},[n("template",{slot:"title"},[e.item.meta?n("item",{attrs:{icon:e.item.meta&&e.item.meta.icon,title:e.item.meta.title}}):e._e()],1),e._v(" "),e._l(e.item.children,(function(t){return n("sidebar-item",{key:t.path,staticClass:"nest-menu",attrs:{"is-nest":!0,item:t,"base-path":e.resolvePath(t.path)}})}))],2):[e.onlyOneChild.meta?n("app-link",{attrs:{to:e.resolvePath(e.onlyOneChild.path)}},[n("el-menu-item",{class:{"submenu-title-noDropdown":!e.isNest},attrs:{index:e.resolvePath(e.onlyOneChild.path)}},[n("item",{attrs:{icon:e.onlyOneChild.meta.icon||e.item.meta&&e.item.meta.icon,title:e.onlyOneChild.meta.title}})],1)],1):e._e()]],2)},Ce=[],Se=n("df7c"),He=n.n(Se),Ee=n("61f7"),Be={name:"MenuItem",functional:!0,props:{icon:{type:String,default:""},title:{type:String,default:""}},render:function(e,t){var n=t.props,a=n.icon,i=n.title,o=[];return a&&o.push(e("svg-icon",{attrs:{"icon-class":a}})),i&&o.push(e("span",{slot:"title"},[i])),o}},Oe=Be,Te=Object(h["a"])(Oe,F,U,!1,null,null,null),Le=Te.exports,Ve=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("component",e._b({},"component",e.linkProps(e.to),!1),[e._t("default")],2)},Ae=[],$e={props:{to:{type:String,required:!0}},methods:{linkProps:function(e){return Object(Ee["a"])(e)?{is:"a",href:e,target:"_blank",rel:"noopener"}:{is:"router-link",to:e}}}},je=$e,De=Object(h["a"])(je,Ve,Ae,!1,null,null,null),Re=De.exports,Ie={computed:{device:function(){return this.$store.state.app.device}},mounted:function(){this.fixBugIniOS()},methods:{fixBugIniOS:function(){var e=this,t=this.$refs.subMenu;if(t){var n=t.handleMouseleave;t.handleMouseleave=function(t){"mobile"!==e.device&&n(t)}}}}},Ne={name:"SidebarItem",components:{Item:Le,AppLink:Re},mixins:[Ie],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=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1?arguments[1]:void 0,a=t.filter((function(t){return!t.hidden&&(e.onlyOneChild=t,!0)}));return 1===a.length||0===a.length&&(this.onlyOneChild=Object(X["a"])(Object(X["a"])({},n),{},{path:"",noShowingChildren:!0}),!0)},resolvePath:function(e){return Object(Ee["a"])(e)?e:Object(Ee["a"])(this.basePath)?this.basePath:He.a.resolve(this.basePath,e)}}},Pe=Ne,qe=Object(h["a"])(Pe,_e,Ce,!1,null,null,null),Ge=qe.exports,Fe=n("cf1e"),Ue=n.n(Fe),Ke={components:{SidebarItem:Ge,Logo:ze},computed:Object(X["a"])(Object(X["a"])({},Object(g["b"])(["sidebar"])),{},{routes:function(){return this.$router.options.routes},activeMenu:function(){var e=this.$route,t=e.meta,n=e.path;return t.activeMenu?t.activeMenu:n},showLogo:function(){return this.$store.state.settings.sidebarLogo},variables:function(){return Ue.a},isCollapse:function(){return!this.sidebar.opened}})},Je=Ke,We=Object(h["a"])(Je,be,ge,!1,null,null,null),Ye=We.exports,Qe=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"app-main"},[n("transition",{attrs:{name:"fade-transform",mode:"out-in"}},[n("router-view",{key:e.key})],1)],1)},Xe=[],Ze={name:"AppMain",computed:{key:function(){return this.$route.path}}},et=Ze,tt=(n("e4de"),n("028b"),Object(h["a"])(et,Qe,Xe,!1,null,"64cf4d83",null)),nt=tt.exports,at=document,it=at.body,ot=992,ct={watch:{$route:function(e){"mobile"===this.device&&this.sidebar.opened&&yt.dispatch("app/closeSideBar",{withoutAnimation:!1})}},beforeMount:function(){window.addEventListener("resize",this.$_resizeHandler)},beforeDestroy:function(){window.removeEventListener("resize",this.$_resizeHandler)},mounted:function(){var e=this.$_isMobile();e&&(yt.dispatch("app/toggleDevice","mobile"),yt.dispatch("app/closeSideBar",{withoutAnimation:!0}))},methods:{$_isMobile:function(){var e=it.getBoundingClientRect();return e.width-1=0}function o(e){var t=["admin","111111"];return t.indexOf(e.trim())>=0}n.d(t,"a",(function(){return a})),n.d(t,"c",(function(){return i})),n.d(t,"b",(function(){return o}))},"6b31":function(e,t,n){"use strict";var a=n("4cdc"),i=n.n(a);i.a},"83d6":function(e,t){e.exports={title:"通用采集器系统",fixedHeader:!1,sidebarLogo:!1}},8902:function(e,t,n){},"93cd":function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-tree",use:"icon-tree-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},"976b":function(e,t,n){"use strict";var a=n("f14a"),i=n.n(a);i.a},"9f2b":function(e,t,n){"use strict";var a=n("bf90"),i=n.n(a);i.a},b20f:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409EFF",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},b37b:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-deviceStatus",use:"icon-deviceStatus-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},b3b5:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-user",use:"icon-user-usage",viewBox:"0 0 130 130",content:''});c.a.add(r);t["default"]=r},bf90:function(e,t,n){},c504:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-deviceManage",use:"icon-deviceManage-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},cf1e:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409EFF",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},d27f:function(e,t,n){"use strict";var a=n("e176"),i=n.n(a);i.a},d7ec:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-eye-open",use:"icon-eye-open-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},dc52:function(e,t,n){},dcbb:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-template",use:"icon-template-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},dcf8:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-nested",use:"icon-nested-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},e176:function(e,t,n){},e4de:function(e,t,n){"use strict";var a=n("8902"),i=n.n(a);i.a},eb1b:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-form",use:"icon-form-usage",viewBox:"0 0 128 128",content:''});c.a.add(r);t["default"]=r},f117:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-wireless",use:"icon-wireless-usage",viewBox:"0 0 1024 1024",content:''});c.a.add(r);t["default"]=r},f12c:function(e,t,n){},f14a:function(e,t,n){},f782:function(e,t,n){"use strict";n.r(t);var a=n("e017"),i=n.n(a),o=n("21a1"),c=n.n(o),r=new i.a({id:"icon-dashboard",use:"icon-dashboard-usage",viewBox:"0 0 128 100",content:''});c.a.add(r);t["default"]=r}},[[0,"runtime","chunk-elementUI","chunk-libs"]]]); \ No newline at end of file diff --git a/webroot/static/js/chunk-495d4d48.1f123b80.js b/webroot/static/js/chunk-495d4d48.1f123b80.js deleted file mode 100644 index 8c65ca1..0000000 --- a/webroot/static/js/chunk-495d4d48.1f123b80.js +++ /dev/null @@ -1 +0,0 @@ -(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-495d4d48"],{1006:function(e,t,r){},3846:function(e,t,r){r("9e1e")&&"g"!=/./g.flags&&r("86cc").f(RegExp.prototype,"flags",{configurable:!0,get:r("0bfb")})},"3d3b":function(e,t,r){"use strict";r.r(t);var a=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"app-container"},[r("el-row",{attrs:{gutter:20}},[r("el-col",{staticStyle:{"margin-bottom":"20px"},attrs:{xs:24,sm:12,md:6}},[r("el-row",{attrs:{gutter:10}},[r("el-col",{attrs:{xs:24,sm:24,md:24}},[r("el-input",{staticStyle:{width:"100%","margin-right":"10px"},attrs:{placeholder:"输入上报服务名称过滤"},model:{value:e.filterText,callback:function(t){e.filterText=t},expression:"filterText"}})],1)],1)],1),e._v(" "),r("el-col",{staticStyle:{"margin-bottom":"20px"},attrs:{xs:24,sm:12,md:18}},[r("el-button",{staticStyle:{float:"right","margin-left":"5px"},attrs:{type:"primary"},on:{click:function(t){e.addVisible=!0,e.form={},e.Param={},e.title="添加上报服务",e.mode="post"}}},[e._v("添加")]),e._v(" "),r("el-button",{staticStyle:{float:"right"},attrs:{type:"primary"},on:{click:e.getReportDeviceList}},[e._v("刷新")])],1)],1),e._v(" "),r("el-row",{attrs:{gutter:20}},e._l(e.filtedData,(function(t,a){return r("el-col",{key:a,staticStyle:{"margin-bottom":"10px"},attrs:{xs:24,sm:12,md:8}},[r("el-card",{staticClass:"box-card",attrs:{shadow:"hover"}},[r("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[r("span",[e._v(e._s(t.ServiceName))]),e._v(" "),r("el-button",{staticStyle:{float:"right",padding:"3px 0"},attrs:{type:"text"},on:{click:function(r){return e.handelGetDeviceListByReportService(t)}}},[e._v("上报结点")]),e._v(" "),r("el-button",{staticStyle:{float:"right",padding:"3px 0"},attrs:{type:"text"},on:{click:function(r){return e.editReportService(t)}}},[e._v("修改")]),e._v(" "),r("el-button",{staticStyle:{float:"right",padding:"3px 0"},attrs:{type:"text"},on:{click:function(r){return e.deleteReportService(t)}}},[e._v("删除")])],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("协议类型:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("el-tag",{attrs:{type:e._f("statusFilter")(t.Protocol)}},[e._v(e._s(e._f("ProtocolFilter")(t.Protocol)))])],1)],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("上报地址:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.IP))])])],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("上报端口:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Port))])])],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("上报周期:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.ReportTime))])])],1),e._v(" "),r("el-collapse",{attrs:{accordion:""},model:{value:e.activeNames,callback:function(t){e.activeNames=t},expression:"activeNames"}},[t.Param?r("el-collapse-item",{attrs:{title:"详细参数",name:t.ServiceName}},[t.Param&&"Aliyun.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("产品秘钥:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.ProductKey))])])],1):e._e(),e._v(" "),t.Param&&"Aliyun.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("设备名称:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceName))])])],1):e._e(),e._v(" "),t.Param&&"Aliyun.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("设备秘钥:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceSecret))])])],1):e._e(),e._v(" "),t.Param&&"Huawei.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("设备ID:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceID))])])],1):e._e(),e._v(" "),t.Param&&"Huawei.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("密钥:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceSecret))])])],1):e._e()],1):e._e()],1)],1)],1)})),1),e._v(" "),r("el-dialog",{attrs:{title:e.title,visible:e.addVisible,width:"30%"},on:{"update:visible":function(t){e.addVisible=t}}},[r("el-form",{ref:"form",attrs:{model:e.form,"label-width":"100px"}},[r("el-form-item",{attrs:{label:"服务名称"}},[r("el-input",{model:{value:e.form.ServiceName,callback:function(t){e.$set(e.form,"ServiceName",t)},expression:"form.ServiceName"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"上报地址"}},[r("el-input",{model:{value:e.form.IP,callback:function(t){e.$set(e.form,"IP",t)},expression:"form.IP"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"上报端口"}},[r("el-input",{attrs:{type:"number"},model:{value:e.form.Port,callback:function(t){e.$set(e.form,"Port",t)},expression:"form.Port"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"上报周期"}},[r("el-input",{attrs:{type:"number"},model:{value:e.form.ReportTime,callback:function(t){e.$set(e.form,"ReportTime",e._n(t))},expression:"form.ReportTime"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"协议类型"}},[r("el-select",{attrs:{clearable:"",placeholder:"协议类型"},model:{value:e.form.Protocol,callback:function(t){e.$set(e.form,"Protocol",t)},expression:"form.Protocol"}},e._l(e.ProtocolList,(function(e,t){return r("el-option",{key:t,attrs:{label:e.text,value:e.id}})})),1)],1),e._v(" "),"Aliyun.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入产品秘钥"}},[r("el-input",{attrs:{placeholder:"请输入ProductKey"},model:{value:e.Param.ProductKey,callback:function(t){e.$set(e.Param,"ProductKey",t)},expression:"Param.ProductKey"}})],1):e._e(),e._v(" "),"Aliyun.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入设备名称"}},[r("el-input",{attrs:{placeholder:"请输入DeviceName"},model:{value:e.Param.DeviceName,callback:function(t){e.$set(e.Param,"DeviceName",t)},expression:"Param.DeviceName"}})],1):e._e(),e._v(" "),"Aliyun.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入设备秘钥"}},[r("el-input",{attrs:{placeholder:"请输入DeviceSecret"},model:{value:e.Param.DeviceSecret,callback:function(t){e.$set(e.Param,"DeviceSecret",t)},expression:"Param.DeviceSecret"}})],1):e._e(),e._v(" "),"Huawei.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入设备ID"}},[r("el-input",{attrs:{placeholder:"请输入DeviceID"},model:{value:e.Param.DeviceID,callback:function(t){e.$set(e.Param,"DeviceID",t)},expression:"Param.DeviceID"}})],1):e._e(),e._v(" "),"Huawei.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入密钥"}},[r("el-input",{attrs:{placeholder:"请输入DeviceSecret"},model:{value:e.Param.DeviceSecret,callback:function(t){e.$set(e.Param,"DeviceSecret",t)},expression:"Param.DeviceSecret"}})],1):e._e()],1),e._v(" "),r("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[r("el-button",{on:{click:function(t){e.addVisible=!1,e.form={}}}},[e._v("取 消")]),e._v(" "),r("el-button",{attrs:{type:"primary"},on:{click:e.operatorReportService}},[e._v("确 定")])],1)],1)],1)},o=[],s=(r("6b54"),{filters:{statusFilter:function(e){var t={"Aliyun.MQTT":"success",EMQX:"gray",TcpServer:"danger","Huawei.MQTT":"warning"};return t[e]||"info"},ProtocolFilter:function(e){var t={"Aliyun.MQTT":"阿里云mqtt服务",EMQX:"EMQX服务",TcpServer:"Tcp服务端","Huawei.MQTT":"华为云mqtt服务"};return t[e]||"未知"},parityFilter:function(e){return"N"===e?"无校验":"J"===e?"奇校验":"O"===e?"偶校验":"未知"}},data:function(){return{serialList:[],listLoading:!0,form:{},filterText:"",editVisible:!1,baudRateList:[],ParityList:[],ProtocolList:[],addVisible:!1,reportSeviceMap:[],activeNames:"11",Param:{},title:"",mode:""}},computed:{filtedData:function(){var e=this;return this.reportSeviceMap.filter((function(t){if(t.ServiceName.toString().indexOf(e.filterText)>-1)return t}))}},created:function(){this.getReportDeviceList(),this.ProtocolList=[{id:"Aliyun.MQTT",text:"阿里云mqtt服务"},{id:"EMQX",text:"EMQX服务"},{id:"Huawei.MQTT",text:"华为云mqtt服务"}]},methods:{getReportDeviceList:function(){var e=this,t="";t="./api/v1/report/param",this.$axios({method:"get",url:t,headers:{token:this.$store.getters.token}}).then((function(t){var r=t.data;"0"===r.Code?(e.reportSeviceMap=r.Data,e.$message.success("获取上报服务列表成功")):"1"===r.Code?e.$message.error(r.Message):"-1"===r.Code?(e.$message.error(r.Message),e.$store.dispatch("user/resetToken"),e.$router.push("/login?redirect=".concat(e.$route.fullPath))):e.$message.error("返回未知错误,错误码:"+r.Code)})).catch((function(t){e.$message.error("出错了"+JSON.stringify(t))}))},selectProtocol:function(e){console.log(e)},handleEdit:function(e,t){this.form=t,this.editVisible=!0},operatorReportService:function(){var e="",t={};if("Aliyun.MQTT"===this.form.Protocol&&"post"===this.mode)e="param",t.ServiceName=this.form.ServiceName,t.IP=this.form.IP,t.Port=this.form.Port.toString(),t.ReportTime=this.form.ReportTime,t.Protocol=this.form.Protocol,t.Param=this.Param;else{if("Aliyun.MQTT"!==this.form.Protocol||"delete"!==this.mode)return void this.$message.error("协议或者请求模式错误");e="param",t.ServiceName=this.form.ServiceName}var r=this,a="";a="./api/v1/report/"+e,this.$axios({method:r.mode,url:a,data:t,headers:{token:this.$store.getters.token}}).then((function(e){var t=e.data;"0"===t.Code?(r.addVisible=!1,"post"===r.mode&&r.$message.success("添加(修改)上报服务成功"),"delete"===r.mode&&r.$message.success("删除上报服务成功")):"1"===t.Code?r.$message.error(t.Message):"-1"===t.Code?(r.$message.error(t.Message),r.$store.dispatch("user/resetToken"),r.$router.push("/login?redirect=".concat(r.$route.fullPath))):r.$message.error("返回未知错误,错误码:"+t.Code)})).catch((function(e){r.$message.error("出错了"+JSON.stringify(e))}))},handelGetDeviceListByReportService:function(e){this.$router.push({name:"reportDeviceManager",params:{ServiceName:e.ServiceName,Protocol:e.Protocol}})},editReportService:function(e){var t=this;this.form={},this.Param={},this.addVisible=!0,this.form=e,this.$set(t.form,"ServiceName",e.ServiceName),this.$set(t.form,"Protocol",e.Protocol),this.Param=e.Param,this.title="修改上报服务",this.mode="post"},deleteReportService:function(e){var t=this,r=this;this.$messageBox.confirm("你确定要删除上报服务吗?

"+e.ServiceName+"

","删除上报",{confirmButtonText:"确定",cancelButtonText:"取消",center:!0,dangerouslyUseHTMLString:!0,type:"info"}).then((function(a){"confirm"===a&&(t.form={},t.Param={},t.form=e,t.$set(r.form,"ServiceName",e.ServiceName),t.$set(r.form,"Protocol",e.Protocol),t.Param=e.Param,t.mode="delete",r.operatorReportService())})).catch((function(e){"cancel"===e&&console.log("cancel")}))}}}),i=s,l=(r("65cf"),r("2877")),c=Object(l["a"])(i,a,o,!1,null,"6d214a14",null);t["default"]=c.exports},"65cf":function(e,t,r){"use strict";var a=r("1006"),o=r.n(a);o.a},"6b54":function(e,t,r){"use strict";r("3846");var a=r("cb7c"),o=r("0bfb"),s=r("9e1e"),i="toString",l=/./[i],c=function(e){r("2aba")(RegExp.prototype,i,e,!0)};r("79e5")((function(){return"/a/b"!=l.call({source:"a",flags:"b"})}))?c((function(){var e=a(this);return"/".concat(e.source,"/","flags"in e?e.flags:!s&&e instanceof RegExp?o.call(e):void 0)})):l.name!=i&&c((function(){return l.call(this)}))}}]); \ No newline at end of file diff --git a/webroot/static/js/chunk-58fe3d45.b441b54a.js b/webroot/static/js/chunk-58fe3d45.b441b54a.js new file mode 100644 index 0000000..5c40f3e --- /dev/null +++ b/webroot/static/js/chunk-58fe3d45.b441b54a.js @@ -0,0 +1 @@ +(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-58fe3d45"],{3846:function(e,t,r){r("9e1e")&&"g"!=/./g.flags&&r("86cc").f(RegExp.prototype,"flags",{configurable:!0,get:r("0bfb")})},39703:function(e,t,r){"use strict";var a=r("8338"),o=r.n(a);o.a},"3d3b":function(e,t,r){"use strict";r.r(t);var a=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"app-container"},[r("el-row",{attrs:{gutter:20}},[r("el-col",{staticStyle:{"margin-bottom":"20px"},attrs:{xs:24,sm:12,md:6}},[r("el-row",{attrs:{gutter:10}},[r("el-col",{attrs:{xs:24,sm:24,md:24}},[r("el-input",{staticStyle:{width:"100%","margin-right":"10px"},attrs:{placeholder:"输入上报服务名称过滤"},model:{value:e.filterText,callback:function(t){e.filterText=t},expression:"filterText"}})],1)],1)],1),e._v(" "),r("el-col",{staticStyle:{"margin-bottom":"20px"},attrs:{xs:24,sm:12,md:18}},[r("el-button",{staticStyle:{float:"right","margin-left":"5px"},attrs:{type:"primary"},on:{click:function(t){e.addVisible=!0,e.form={},e.Param={},e.title="添加上报服务",e.mode="post"}}},[e._v("添加")]),e._v(" "),r("el-button",{staticStyle:{float:"right"},attrs:{type:"primary"},on:{click:e.getReportDeviceList}},[e._v("刷新")])],1)],1),e._v(" "),r("el-row",{attrs:{gutter:20}},e._l(e.filtedData,(function(t,a){return r("el-col",{key:a,staticStyle:{"margin-bottom":"10px"},attrs:{xs:24,sm:12,md:8}},[r("el-card",{staticClass:"box-card",attrs:{shadow:"hover"}},[r("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[r("span",[e._v(e._s(t.ServiceName))]),e._v(" "),r("el-button",{staticStyle:{float:"right",padding:"3px 0"},attrs:{type:"text"},on:{click:function(r){return e.handelGetDeviceListByReportService(t)}}},[e._v("上报结点")]),e._v(" "),r("el-button",{staticStyle:{float:"right",padding:"3px 0"},attrs:{type:"text"},on:{click:function(r){return e.editReportService(t)}}},[e._v("修改")]),e._v(" "),r("el-button",{staticStyle:{float:"right",padding:"3px 0"},attrs:{type:"text"},on:{click:function(r){return e.deleteReportService(t)}}},[e._v("删除")])],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("协议类型:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("el-tag",{attrs:{type:e._f("statusFilter")(t.Protocol)}},[e._v(e._s(e._f("ProtocolFilter")(t.Protocol)))])],1)],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("上报地址:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.IP))])])],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("上报端口:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Port))])])],1),e._v(" "),r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("上报周期:")])]),e._v(" "),r("el-col",{attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.ReportTime))])])],1),e._v(" "),r("el-collapse",{attrs:{accordion:""},model:{value:e.activeNames,callback:function(t){e.activeNames=t},expression:"activeNames"}},[t.Param?r("el-collapse-item",{attrs:{title:"详细参数",name:t.ServiceName}},[t.Param&&"Aliyun.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("产品秘钥:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.ProductKey))])])],1):e._e(),e._v(" "),t.Param&&"Aliyun.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("设备名称:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceName))])])],1):e._e(),e._v(" "),t.Param&&"Aliyun.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("设备秘钥:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceSecret))])])],1):e._e(),e._v(" "),t.Param&&"Huawei.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("设备ID:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceID))])])],1):e._e(),e._v(" "),t.Param&&"Huawei.MQTT"==t.Protocol?r("el-row",{staticClass:"text item"},[r("el-col",{staticStyle:{"align-self":"center","text-align":"right"},attrs:{xs:8,sm:8,md:8}},[r("span",[e._v("密钥:")])]),e._v(" "),r("el-col",{staticStyle:{"text-align":"left"},attrs:{xs:16,sm:16,md:16}},[r("span",[e._v(e._s(t.Param.DeviceSecret))])])],1):e._e()],1):e._e()],1)],1)],1)})),1),e._v(" "),r("el-dialog",{attrs:{title:e.title,visible:e.addVisible,width:"30%"},on:{"update:visible":function(t){e.addVisible=t}}},[r("el-form",{ref:"form",attrs:{model:e.form,"label-width":"100px"}},[r("el-form-item",{attrs:{label:"服务名称"}},[r("el-input",{model:{value:e.form.ServiceName,callback:function(t){e.$set(e.form,"ServiceName",t)},expression:"form.ServiceName"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"上报地址"}},[r("el-input",{model:{value:e.form.IP,callback:function(t){e.$set(e.form,"IP",t)},expression:"form.IP"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"上报端口"}},[r("el-input",{attrs:{type:"number"},model:{value:e.form.Port,callback:function(t){e.$set(e.form,"Port",t)},expression:"form.Port"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"上报周期"}},[r("el-input",{attrs:{type:"number"},model:{value:e.form.ReportTime,callback:function(t){e.$set(e.form,"ReportTime",e._n(t))},expression:"form.ReportTime"}})],1),e._v(" "),r("el-form-item",{attrs:{label:"协议类型"}},[r("el-select",{attrs:{clearable:"",placeholder:"协议类型"},model:{value:e.form.Protocol,callback:function(t){e.$set(e.form,"Protocol",t)},expression:"form.Protocol"}},e._l(e.ProtocolList,(function(e,t){return r("el-option",{key:t,attrs:{label:e.text,value:e.id}})})),1)],1),e._v(" "),"Aliyun.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入产品秘钥"}},[r("el-input",{attrs:{placeholder:"请输入ProductKey"},model:{value:e.Param.ProductKey,callback:function(t){e.$set(e.Param,"ProductKey",t)},expression:"Param.ProductKey"}})],1):e._e(),e._v(" "),"Aliyun.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入设备名称"}},[r("el-input",{attrs:{placeholder:"请输入DeviceName"},model:{value:e.Param.DeviceName,callback:function(t){e.$set(e.Param,"DeviceName",t)},expression:"Param.DeviceName"}})],1):e._e(),e._v(" "),"Aliyun.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入设备秘钥"}},[r("el-input",{attrs:{placeholder:"请输入DeviceSecret"},model:{value:e.Param.DeviceSecret,callback:function(t){e.$set(e.Param,"DeviceSecret",t)},expression:"Param.DeviceSecret"}})],1):e._e(),e._v(" "),"Huawei.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入设备ID"}},[r("el-input",{attrs:{placeholder:"请输入DeviceID"},model:{value:e.Param.DeviceID,callback:function(t){e.$set(e.Param,"DeviceID",t)},expression:"Param.DeviceID"}})],1):e._e(),e._v(" "),"Huawei.MQTT"==e.form.Protocol?r("el-form-item",{attrs:{label:"输入密钥"}},[r("el-input",{attrs:{placeholder:"请输入DeviceSecret"},model:{value:e.Param.DeviceSecret,callback:function(t){e.$set(e.Param,"DeviceSecret",t)},expression:"Param.DeviceSecret"}})],1):e._e()],1),e._v(" "),r("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[r("el-button",{on:{click:function(t){e.addVisible=!1,e.form={}}}},[e._v("取 消")]),e._v(" "),r("el-button",{attrs:{type:"primary"},on:{click:e.operatorReportService}},[e._v("确 定")])],1)],1)],1)},o=[],i=(r("6b54"),{filters:{statusFilter:function(e){var t={"Aliyun.MQTT":"success",EMQX:"gray",TcpServer:"danger","Huawei.MQTT":"warning"};return t[e]||"info"},ProtocolFilter:function(e){var t={"Aliyun.MQTT":"阿里云mqtt服务",EMQX:"EMQX服务",TcpServer:"Tcp服务端","Huawei.MQTT":"华为云mqtt服务"};return t[e]||"未知"},parityFilter:function(e){return"N"===e?"无校验":"J"===e?"奇校验":"O"===e?"偶校验":"未知"}},data:function(){return{serialList:[],listLoading:!0,form:{},filterText:"",editVisible:!1,baudRateList:[],ParityList:[],ProtocolList:[],addVisible:!1,reportSeviceMap:[],activeNames:"11",Param:{},title:"",mode:""}},computed:{filtedData:function(){var e=this;return this.reportSeviceMap.filter((function(t){if(t.ServiceName.toString().indexOf(e.filterText)>-1)return t}))}},created:function(){this.getReportDeviceList(),this.ProtocolList=[{id:"Aliyun.MQTT",text:"阿里云mqtt服务"},{id:"EMQX",text:"EMQX服务"},{id:"Huawei.MQTT",text:"华为云mqtt服务"}]},methods:{getReportDeviceList:function(){var e=this,t="";t="./api/v1/report/param",this.$axios({method:"get",url:t,headers:{token:this.$store.getters.token}}).then((function(t){var r=t.data;"0"===r.Code?(e.reportSeviceMap=r.Data,e.$message.success("获取上报服务列表成功")):"1"===r.Code?e.$message.error(r.Message):"-1"===r.Code?(e.$message.error(r.Message),e.$store.dispatch("user/resetToken"),e.$router.push("/login?redirect=".concat(e.$route.fullPath))):e.$message.error("返回未知错误,错误码:"+r.Code)})).catch((function(t){e.$message.error("出错了"+JSON.stringify(t))}))},selectProtocol:function(e){console.log(e)},handleEdit:function(e,t){this.form=t,this.editVisible=!0},operatorReportService:function(){var e="",t={};if("Aliyun.MQTT"===this.form.Protocol&&"post"===this.mode)e="param",t.ServiceName=this.form.ServiceName,t.IP=this.form.IP,t.Port=this.form.Port.toString(),t.ReportTime=this.form.ReportTime,t.Protocol=this.form.Protocol,t.Param=this.Param;else if("Huawei.MQTT"===this.form.Protocol&&"post"===this.mode)e="param",t.ServiceName=this.form.ServiceName,t.IP=this.form.IP,t.Port=this.form.Port.toString(),t.ReportTime=this.form.ReportTime,t.Protocol=this.form.Protocol,t.Param=this.Param;else if("Aliyun.MQTT"===this.form.Protocol&&"delete"===this.mode)e="param",t.ServiceName=this.form.ServiceName;else{if("Huawei.MQTT"!==this.form.Protocol||"delete"!==this.mode)return void this.$message.error("协议或者请求模式错误");e="param",t.ServiceName=this.form.ServiceName}var r=this,a="";a="./api/v1/report/"+e,this.$axios({method:r.mode,url:a,data:t,headers:{token:this.$store.getters.token}}).then((function(e){var t=e.data;"0"===t.Code?(r.addVisible=!1,"post"===r.mode&&r.$message.success("添加(修改)上报服务成功"),"delete"===r.mode&&r.$message.success("删除上报服务成功")):"1"===t.Code?r.$message.error(t.Message):"-1"===t.Code?(r.$message.error(t.Message),r.$store.dispatch("user/resetToken"),r.$router.push("/login?redirect=".concat(r.$route.fullPath))):r.$message.error("返回未知错误,错误码:"+t.Code)})).catch((function(e){r.$message.error("出错了"+JSON.stringify(e))}))},handelGetDeviceListByReportService:function(e){this.$router.push({name:"reportDeviceManager",params:{ServiceName:e.ServiceName,Protocol:e.Protocol}})},editReportService:function(e){var t=this;this.form={},this.Param={},this.addVisible=!0,this.form=e,this.$set(t.form,"ServiceName",e.ServiceName),this.$set(t.form,"Protocol",e.Protocol),this.Param=e.Param,this.title="修改上报服务",this.mode="post"},deleteReportService:function(e){var t=this,r=this;this.$messageBox.confirm("你确定要删除上报服务吗?

"+e.ServiceName+"

","删除上报",{confirmButtonText:"确定",cancelButtonText:"取消",center:!0,dangerouslyUseHTMLString:!0,type:"info"}).then((function(a){"confirm"===a&&(t.form={},t.Param={},t.form=e,t.$set(r.form,"ServiceName",e.ServiceName),t.$set(r.form,"Protocol",e.Protocol),t.Param=e.Param,t.mode="delete",r.operatorReportService())})).catch((function(e){"cancel"===e&&console.log("cancel")}))}}}),s=i,l=(r("39703"),r("2877")),c=Object(l["a"])(s,a,o,!1,null,"519aaf7f",null);t["default"]=c.exports},"6b54":function(e,t,r){"use strict";r("3846");var a=r("cb7c"),o=r("0bfb"),i=r("9e1e"),s="toString",l=/./[s],c=function(e){r("2aba")(RegExp.prototype,s,e,!0)};r("79e5")((function(){return"/a/b"!=l.call({source:"a",flags:"b"})}))?c((function(){var e=a(this);return"/".concat(e.source,"/","flags"in e?e.flags:!i&&e instanceof RegExp?o.call(e):void 0)})):l.name!=s&&c((function(){return l.call(this)}))},8338:function(e,t,r){}}]); \ No newline at end of file