From 60c99035760dee58a5c79d9da2c5bc13dd94b094 Mon Sep 17 00:00:00 2001 From: name Date: Mon, 17 Jan 2022 18:30:54 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=A6=81=E7=94=A8ip=E8=AE=B0?= =?UTF-8?q?=E5=BD=95=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- data/DataSource.go | 3 ++- data/forbidden.go | 16 ++++++++++++++++ data/table/forbidden.go | 10 ++++++++++ service/ForbiddenService.go | 14 ++++++++------ views/index.html | 2 +- .../js/{app.89c04615.js => app.6ca90b3c.js} | 2 +- views/static/js/chunk-06ff5938.1f67e0a8.js | 1 - views/static/js/chunk-06ff5938.8ee90bf3.js | 1 + views/static/js/chunk-51b20511.499045fc.js | 1 + ...02.40fcf23d.js => chunk-63945102.3d3ba49e.js} | 2 +- web/handler/base/DBTraceHandler.go | 2 +- 11 files changed, 42 insertions(+), 12 deletions(-) create mode 100644 data/forbidden.go create mode 100644 data/table/forbidden.go rename views/static/js/{app.89c04615.js => app.6ca90b3c.js} (60%) delete mode 100644 views/static/js/chunk-06ff5938.1f67e0a8.js create mode 100644 views/static/js/chunk-06ff5938.8ee90bf3.js create mode 100644 views/static/js/chunk-51b20511.499045fc.js rename views/static/js/{chunk-63945102.40fcf23d.js => chunk-63945102.3d3ba49e.js} (69%) diff --git a/data/DataSource.go b/data/DataSource.go index 7dcb00b..ab18997 100644 --- a/data/DataSource.go +++ b/data/DataSource.go @@ -31,7 +31,8 @@ func TableInit() { new(table.Image), new(table.Task), new(table.Config), - new(table.WhiteIp)) + new(table.WhiteIp), + new(table.Forbidden)) if err != nil { log.Println("TableInit.err:", err) } diff --git a/data/forbidden.go b/data/forbidden.go new file mode 100644 index 0000000..9caac08 --- /dev/null +++ b/data/forbidden.go @@ -0,0 +1,16 @@ +package data + +import ( + "docker-manager/data/base" + "docker-manager/data/table" +) + +func AddForbidden(e table.Forbidden) (err error) { + _, err = base.DBEngine.Table("forbidden").Insert(&e) + return +} + +func ForbiddenList() (records []table.Forbidden) { + base.DBEngine.Table("forbidden").SQL("select ip,sum(num) as num,max(create_date) as create_date from forbidden").Find(&records) + return +} diff --git a/data/table/forbidden.go b/data/table/forbidden.go new file mode 100644 index 0000000..429b244 --- /dev/null +++ b/data/table/forbidden.go @@ -0,0 +1,10 @@ +package table + +import "time" + +type Forbidden struct { + Id int `xorm:"not null pk autoincr INT"` + Ip string `xorm:"comment('ip') VARCHAR(24)"` + Num int `xorm:"default 1 comment('num') INT"` + CreateDate time.Time `xorm:"created default CURRENT_TIMESTAMP TIMESTAMP"` +} diff --git a/service/ForbiddenService.go b/service/ForbiddenService.go index 460c61f..7f68458 100644 --- a/service/ForbiddenService.go +++ b/service/ForbiddenService.go @@ -1,17 +1,19 @@ package service import ( - "docker-manager/model" + "docker-manager/data" + "docker-manager/data/table" "log" ) -var Log model.SyncMap - func AddForbiddenLog(reqIp string) { log.Println("禁止访问,IP:", reqIp) - Log.IncInt(reqIp, 1) + data.AddForbidden(table.Forbidden{ + Ip: reqIp, + Num: 1, + }) } -func ForbiddenLogMap() map[string]interface{} { - return Log.ToStrMap() +func ForbiddenLogRecord() []table.Forbidden { + return data.ForbiddenList() } diff --git a/views/index.html b/views/index.html index 68f4ac0..5888ad8 100644 --- a/views/index.html +++ b/views/index.html @@ -1 +1 @@ -Docker Manager
\ No newline at end of file +Docker Manager
\ No newline at end of file diff --git a/views/static/js/app.89c04615.js b/views/static/js/app.6ca90b3c.js similarity index 60% rename from views/static/js/app.89c04615.js rename to views/static/js/app.6ca90b3c.js index 0ff2546..be6c7c6 100644 --- a/views/static/js/app.89c04615.js +++ b/views/static/js/app.6ca90b3c.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";n("3f4d")},"186a":function(e,t,n){"use strict";n("9df4")},"18f0":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-link",use:"icon-link-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},"20ef":function(e,t,n){},"263d":function(e,t,n){},"2a3d":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-password",use:"icon-password-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},"30c3":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-example",use:"icon-example-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},3504:function(e){e.exports=JSON.parse('{"message":"hello i18n !!","hello":"你好, i18n !","首页":"首页","密码修改":"密码修改","退出":"退出","刷新容器列表":"刷新容器列表","刷新容器状态":"刷新容器状态"}')},"3f4d":function(e,t,n){},"3fbd":function(e,t,n){"use strict";n("263d")},4314:function(e,t,n){},4360:function(e,t,n){"use strict";var a=n("2b0e"),o=n("2f62"),i=(n("b0c0"),{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}}),r=i,s=n("a78e"),c=n.n(s),l={sidebar:{opened:!c.a.get("sidebarStatus")||!!+c.a.get("sidebarStatus"),withoutAnimation:!1},device:"desktop"},u={TOGGLE_SIDEBAR:function(e){e.sidebar.opened=!e.sidebar.opened,e.sidebar.withoutAnimation=!1,e.sidebar.opened?c.a.set("sidebarStatus",1):c.a.set("sidebarStatus",0)},CLOSE_SIDEBAR:function(e,t){c.a.set("sidebarStatus",0),e.sidebar.opened=!1,e.sidebar.withoutAnimation=t},TOGGLE_DEVICE:function(e,t){e.device=t}},d={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)}},f={namespaced:!0,state:l,mutations:u,actions:d},h=n("83d6"),m=n.n(h),p=m.a.showSettings,g=m.a.fixedHeader,b=m.a.sidebarLogo,v={showSettings:p,fixedHeader:g,sidebarLogo:b},w={CHANGE_SETTING:function(e,t){var n=t.key,a=t.value;e.hasOwnProperty(n)&&(e[n]=a)}},x={changeSetting:function(e,t){var n=e.commit;n("CHANGE_SETTING",t)}},k={namespaced:!0,state:v,mutations:w,actions:x},y=(n("d3b7"),n("498a"),n("c24f")),O=n("5f87"),C=n("a18c"),S=function(){return{token:Object(O["a"])(),name:"",avatar:""}},M=S(),_={RESET_STATE:function(e){Object.assign(e,S())},SET_TOKEN:function(e,t){e.token=t},SET_NAME:function(e,t){e.name=t},SET_AVATAR:function(e,t){e.avatar=t}},E={login:function(e,t){var n=e.commit,a=t.username,o=t.password;return new Promise((function(e,t){Object(y["h"])({username:a.trim(),password:o}).then((function(t){var a=t.data;n("SET_TOKEN",a),Object(O["c"])(a),e()})).catch((function(e){console.log("login.error:",e),t(e)}))}))},getInfo:function(e){var t=e.commit,n=e.state;return new Promise((function(e,a){Object(y["f"])(n.token).then((function(n){var o=n.data;if(!o)return a("Verification failed, please Login again.");var i=o.name,r=o.avatar;t("SET_NAME",i),t("SET_AVATAR",r),e(o)})).catch((function(e){a(e)}))}))},logout:function(e){var t=e.commit,n=e.state;return new Promise((function(e,a){Object(y["i"])(n.token).then((function(){Object(O["b"])(),Object(C["b"])(),t("RESET_STATE"),e()})).catch((function(e){a(e)}))}))},resetToken:function(e){var t=e.commit;return new Promise((function(e){Object(O["b"])(),t("RESET_STATE"),e()}))}},H={namespaced:!0,state:M,mutations:_,actions:E};a["default"].use(o["a"]);var z=new o["a"].Store({modules:{app:f,settings:k,user:H},getters:r});t["a"]=z},"47f1":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-table",use:"icon-table-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},"49f8":function(e,t,n){var a={"./en.json":"edd4","./zh.json":"3504"};function o(e){var t=i(e);return n(t)}function i(e){if(!n.o(a,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return a[e]}o.keys=function(){return Object.keys(a)},o.resolve=i,e.exports=o,o.id="49f8"},"4df5":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-eye",use:"icon-eye-usage",viewBox:"0 0 128 64",content:''});r.a.add(s);t["default"]=s},"51ff":function(e,t,n){var a={"./dashboard.svg":"f782","./example.svg":"30c3","./eye-open.svg":"d7ec","./eye.svg":"4df5","./form.svg":"eb1b","./link.svg":"18f0","./nested.svg":"dcf8","./password.svg":"2a3d","./table.svg":"47f1","./tree.svg":"93cd","./user.svg":"b3b5"};function o(e){var t=i(e);return n(t)}function i(e){if(!n.o(a,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return a[e]}o.keys=function(){return Object.keys(a)},o.resolve=i,e.exports=o,o.id="51ff"},"56d7":function(e,t,n){"use strict";n.r(t);n("e260"),n("e6cf"),n("cca6"),n("a79d");var a=n("2b0e"),o=(n("f5df1"),n("5c96")),i=n.n(o),r=(n("0fae"),n("b20f"),function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{attrs:{id:"app"}},[n("router-view")],1)}),s=[],c={name:"App"},l=c,u=n("2877"),d=Object(u["a"])(l,r,s,!1,null,null,null),f=d.exports,h=n("4360"),m=n("a18c"),p=(n("d81d"),n("d3b7"),n("ddb0"),function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.isExternal?n("div",e._g({staticClass:"svg-external-icon svg-icon",style:e.styleExternalIcon},e.$listeners)):n("svg",e._g({class:e.svgClass,attrs:{"aria-hidden":"true"}},e.$listeners),[n("use",{attrs:{"xlink:href":e.iconName}})])}),g=[],b=n("61f7"),v={name:"SvgIcon",props:{iconClass:{type:String,required:!0},className:{type:String,default:""}},computed:{isExternal:function(){return Object(b["c"])(this.iconClass)},iconName:function(){return"#icon-".concat(this.iconClass)},svgClass:function(){return this.className?"svg-icon "+this.className:"svg-icon"},styleExternalIcon:function(){return{mask:"url(".concat(this.iconClass,") no-repeat 50% 50%"),"-webkit-mask":"url(".concat(this.iconClass,") no-repeat 50% 50%")}}}},w=v,x=(n("68fa"),Object(u["a"])(w,p,g,!1,null,"f9f7fefc",null)),k=x.exports;a["default"].component("svg-icon",k);var y=n("51ff"),O=function(e){return e.keys().map(e)};O(y);var C=n("1da1"),S=(n("96cf"),n("b0c0"),n("323e")),M=n.n(S),_=(n("a5d8"),n("5f87")),E=(n("99af"),n("83d6")),H=n.n(E),z=H.a.title||"Docker Manager";function P(e){return e?"".concat(e," - ").concat(z):"".concat(z)}M.a.configure({showSpinner:!1});var j=["/login","/forget"];m["a"].beforeEach(function(){var e=Object(C["a"])(regeneratorRuntime.mark((function e(t,n,a){var i,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(M.a.start(),document.title=P(t.meta.title),i=Object(_["a"])(),!i){e.next=29;break}if("/login"!==t.path){e.next=9;break}a({path:"/"}),M.a.done(),e.next=27;break;case 9:if(r=h["a"].getters.name,!r){e.next=14;break}a(),e.next=27;break;case 14:return e.prev=14,e.next=17,h["a"].dispatch("user/getInfo");case 17:a(),e.next=27;break;case 20:return e.prev=20,e.t0=e["catch"](14),e.next=24,h["a"].dispatch("user/resetToken");case 24:o["Message"].error(e.t0||"Has Error"),a("/login?redirect=".concat(t.path)),M.a.done();case 27:e.next=30;break;case 29:-1!==j.indexOf(t.path)?a():(a("/login?redirect=".concat(t.path)),M.a.done());case 30:case"end":return e.stop()}}),e,null,[[14,20]])})));return function(t,n,a){return e.apply(this,arguments)}}()),m["a"].afterEach((function(){M.a.done()}));n("159b"),n("ac1f"),n("466d"),n("1276");var T=n("a925");function $(){var e=n("49f8"),t={};return e.keys().forEach((function(n){var a=n.match(/([A-Za-z0-9-_]+)\./i);if(a&&a.length>1){var o=a[1];t[o]=e(n)}})),t}function L(){return localStorage&&localStorage.locale?localStorage.locale:(navigator.language||navigator.userLanguage).split("-")[0]}a["default"].use(T["a"]);var B=new T["a"]({locale:L(),fallbackLocale:"zh",silentTranslationWarn:!0,messages:$()});a["default"].use(i.a),a["default"].config.productionTip=!1,new a["default"]({el:"#app",i18n:B,router:m["a"],store:h["a"],render:function(e){return e(f)}})},"5f87":function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"c",(function(){return s})),n.d(t,"b",(function(){return c}));var a=n("a78e"),o=n.n(a),i="c-token";function r(){return o.a.get(i)}function s(e){return o.a.set(i,e)}function c(){return o.a.remove(i)}},"60de":function(e,t,n){"use strict";n("4314")},"61f7":function(e,t,n){"use strict";n.d(t,"c",(function(){return a})),n.d(t,"d",(function(){return o})),n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return r}));n("498a");function a(e){return/^(https?:|mailto:|tel:)/.test(e)}function o(e){var t=["admin","editor"];return t.indexOf(e.trim())>=0}function i(e,t,n){var a=/^1[3|4|5|6|7|8|9]\d{9}$/;return t?a.test(t)?void n():n(new Error("请填写正确的手机号码!")):n(new Error("请填写手机号码!"))}function r(e,t,n){var a=/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;return t?a.test(t)?void n():n(new Error("证件号码不正确")):n(new Error("证件号码不能为空"))}},"68fa":function(e,t,n){"use strict";n("eae4")},"83d6":function(e,t){e.exports={title:"Docker Manager",fixedHeader:!1,sidebarLogo:!1}},"8e1d":function(e,t,n){},"93cd":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-tree",use:"icon-tree-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},9874:function(e,t,n){},"9df4":function(e,t,n){},a18c:function(e,t,n){"use strict";n.d(t,"b",(function(){return Be}));n("d3b7"),n("3ca3"),n("ddb0");var a=n("2b0e"),o=n("8c4f"),i=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(),n("sidebar",{staticClass:"sidebar-container"}),n("div",{staticClass:"main-container"},[n("div",{class:{"fixed-header":e.fixedHeader}},[n("navbar")],1),n("app-main")],1)],1)},r=[],s=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"navbar"},[n("hamburger",{staticClass:"hamburger-container",attrs:{"is-active":e.sidebar.opened},on:{toggleClick:e.toggleSideBar}}),n("breadcrumb",{staticClass:"breadcrumb-container"}),n("div",{staticClass:"right-menu"},[n("a",{attrs:{href:"https://hub.docker.com/r/xiaojun207/docker-manager/tags",target:"_blank"}},[n("div",{staticStyle:{float:"left","margin-right":"40px",color:"#3f3e3e"}},[n("el-badge",{staticClass:"item",staticStyle:{"line-height":"30px"},attrs:{value:e.version.upgrade?"new":""}},[e._v(e._s(e.$t("当前版本"))+" : "+e._s(e.version.current))])],1)]),n("lang"),n("el-dropdown",{staticClass:"avatar-container",attrs:{trigger:"click"}},[n("div",{staticClass:"avatar-wrapper"},[n("el-avatar",{attrs:{src:e.avatar}},[n("img",{attrs:{src:"https://cube.elemecdn.com/e/fd/0fc7d20532fdaf769a25683617711png.png"}})]),n("i",{staticClass:"el-icon-caret-bottom"})],1),n("el-dropdown-menu",{staticClass:"user-dropdown",attrs:{slot:"dropdown"},slot:"dropdown"},[n("router-link",{attrs:{to:"/"}},[n("el-dropdown-item",[e._v(" "+e._s(e.$t("首页"))+" ")])],1),n("el-button",{attrs:{type:"text"},on:{click:function(t){e.dialogVisible=!0}}},[n("el-dropdown-item",[e._v(" "+e._s(e.$t("密码修改"))+" ")])],1),n("el-dropdown-item",{attrs:{divided:""},nativeOn:{click:function(t){return e.logout(t)}}},[n("span",{staticStyle:{display:"block"}},[e._v(e._s(e.$t("退出")))])])],1)],1)],1),n("el-dialog",{attrs:{title:"添加用户",visible:e.dialogVisible,width:"30%"},on:{"update:visible":function(t){e.dialogVisible=t}}},[n("el-form",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],ref:"form",attrs:{"label-position":"right",model:e.form,"label-width":"80px"}},[n("el-form-item",{attrs:{label:e.$t("旧密码")}},[n("el-input",{attrs:{placeholder:e.$t("请输入旧密码"),"show-password":""},model:{value:e.form.OldPassword,callback:function(t){e.$set(e.form,"OldPassword",t)},expression:"form.OldPassword"}})],1),n("el-form-item",{attrs:{label:e.$t("新密码")}},[n("el-input",{attrs:{placeholder:e.$t("输入新密码"),"show-password":""},model:{value:e.form.NewPassword,callback:function(t){e.$set(e.form,"NewPassword",t)},expression:"form.NewPassword"}})],1)],1),n("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{on:{click:function(t){e.dialogVisible=!1,e.loading=!1}}},[e._v("取 消")]),n("el-button",{attrs:{type:"primary"},on:{click:e.onSubmit}},[e._v(e._s(e.$t("修改密码")))])],1)],1)],1)},c=[],l=n("1da1"),u=n("5530"),d=(n("96cf"),n("2f62")),f=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(e.$t(t.meta.title)))]):n("a",{on:{click:function(n){return n.preventDefault(),e.handleLink(t)}}},[e._v(e._s(e.$t(t.meta.title)))])])})),1)],1)},h=[],m=(n("4de4"),n("99af"),n("b0c0"),n("498a"),n("bd11")),p=n.n(m),g={data:function(){return{levelList:null}},watch:{$route:function(){this.getBreadcrumb()}},created:function(){this.getBreadcrumb()},methods:{t:function(e){return e},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:"Dashboard"}}].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=p.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))}}},b=g,v=(n("60de"),n("2877")),w=Object(v["a"])(b,f,h,!1,null,"2edef819",null),x=w.exports,k=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"}})])])},y=[],O={name:"Hamburger",props:{isActive:{type:Boolean,default:!1}},methods:{toggleClick:function(){this.$emit("toggleClick")}}},C=O,S=(n("186a"),Object(v["a"])(C,k,y,!1,null,"49e15297",null)),M=S.exports,_=n("e579"),E=n("c24f"),H=n("b775");function z(){return Object(H["a"])({url:"/base/version",method:"get"})}var P,j,T=n("ed08"),$={data:function(){return{dialogVisible:!1,loading:!1,version:{current:"1.0.0",latest:"1.0.0",upgrade:!0},form:{OldPassword:"",NewPassword:""}}},components:{Breadcrumb:x,Hamburger:M,Lang:_["a"]},computed:Object(u["a"])({},Object(d["b"])(["sidebar","avatar"])),created:function(){this.fetchData()},methods:{toggleSideBar:function(){this.$store.dispatch("app/toggleSideBar")},logout:function(){var e=this;return Object(l["a"])(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)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)})))()},onSubmit:function(){var e=this;this.loading=!0,console.log("this.form:",this.form),Object(E["b"])(this.form).then((function(t){e.$message(e.$t("修改成功")),e.loading=!1,e.dialogVisible=!1})).catch((function(t){e.loading=!1}))},fetchData:function(){var e=this;z().then((function(t){e.version=t.data,e.version.upgrade=Object(T["a"])(e.version.current,e.version.latest)<0}))}}},L=$,B=(n("e72f"),Object(v["a"])(L,s,c,!1,null,"48282632",null)),A=B.exports,D=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(),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)},V=[],I=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(),n("h1",{staticClass:"sidebar-title"},[e._v(e._s(e.title)+" ")])])],1)],1)},N=[],R={name:"SidebarLogo",props:{collapse:{type:Boolean,required:!0}},data:function(){return{title:"Docker Manager",logo:"https://wpimg.wallstcn.com/69a1c46c-eb1c-4b46-8bd4-e9e686ef5251.png"}}},q=R,G=(n("d977"),Object(v["a"])(q,I,N,!1,null,"2c1ebc72",null)),U=G.exports,F=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.item.hidden?e._e():n("div",[!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.$t(e.item.meta.title)}}):e._e()],1),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.$t(e.onlyOneChild.meta.title)}})],1)],1):e._e()]],2)},K=[],J=n("df7c"),W=n.n(J),Y=n("61f7"),X=(n("caad"),n("2532"),{name:"MenuItem",functional:!0,props:{icon:{type:String,default:""},title:{type:String,default:""}},render:function(e,t){var n=t.props,a=n.icon,o=n.title,i=[];return a&&(a.includes("el-icon")?i.push(e("i",{class:[a,"sub-el-icon"]})):i.push(e("svg-icon",{attrs:{"icon-class":a}}))),o&&i.push(e("span",{slot:"title"},[o])),i}}),Z=X,Q=(n("bf4f"),Object(v["a"])(Z,P,j,!1,null,"18eeea00",null)),ee=Q.exports,te=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n(e.type,e._b({tag:"component"},"component",e.linkProps(e.to),!1),[e._t("default")],2)},ne=[],ae={props:{to:{type:String,required:!0}},computed:{isExternal:function(){return Object(Y["c"])(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}}}},oe=ae,ie=Object(v["a"])(oe,te,ne,!1,null,null,null),re=ie.exports,se={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)}}}}},ce={name:"SidebarItem",components:{Item:ee,AppLink:re},mixins:[se],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(u["a"])(Object(u["a"])({},n),{},{path:"",noShowingChildren:!0}),!0)},resolvePath:function(e){return Object(Y["c"])(e)?e:Object(Y["c"])(this.basePath)?this.basePath:W.a.resolve(this.basePath,e)}}},le=ce,ue=Object(v["a"])(le,F,K,!1,null,null,null),de=ue.exports,fe=n("cf1e"),he=n.n(fe),me={components:{SidebarItem:de,Logo:U},computed:Object(u["a"])(Object(u["a"])({},Object(d["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 he.a},isCollapse:function(){return!this.sidebar.opened}})},pe=me,ge=Object(v["a"])(pe,D,V,!1,null,null,null),be=ge.exports,ve=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)},we=[],xe={name:"AppMain",computed:{key:function(){return this.$route.path}}},ke=xe,ye=(n("e4de"),n("028b"),Object(v["a"])(ke,ve,we,!1,null,"64cf4d83",null)),Oe=ye.exports,Ce=n("4360"),Se=document,Me=Se.body,_e=992,Ee={watch:{$route:function(e){"mobile"===this.device&&this.sidebar.opened&&Ce["a"].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&&(Ce["a"].dispatch("app/toggleDevice","mobile"),Ce["a"].dispatch("app/closeSideBar",{withoutAnimation:!0}))},methods:{$_isMobile:function(){var e=Me.getBoundingClientRect();return e.width-1<_e},$_resizeHandler:function(){if(!document.hidden){var e=this.$_isMobile();Ce["a"].dispatch("app/toggleDevice",e?"mobile":"desktop"),e&&Ce["a"].dispatch("app/closeSideBar",{withoutAnimation:!0})}}}},He={name:"Layout",components:{Navbar:A,Sidebar:be,AppMain:Oe},mixins:[Ee],computed:{sidebar:function(){return this.$store.state.app.sidebar},device:function(){return this.$store.state.app.device},fixedHeader:function(){return this.$store.state.settings.fixedHeader},classObj:function(){return{hideSidebar:!this.sidebar.opened,openSidebar:this.sidebar.opened,withoutAnimation:this.sidebar.withoutAnimation,mobile:"mobile"===this.device}}},methods:{handleClickOutside:function(){this.$store.dispatch("app/closeSideBar",{withoutAnimation:!1})}}},ze=He,Pe=(n("3fbd"),Object(v["a"])(ze,i,r,!1,null,"81617ce2",null)),je=Pe.exports;a["default"].use(o["a"]);var Te=[{path:"/login",component:function(){return Promise.all([n.e("chunk-4794904a"),n.e("chunk-b415acce")]).then(n.bind(null,"9ed6"))},hidden:!0},{path:"/forget",component:function(){return n.e("chunk-20b64ef3").then(n.bind(null,"d794"))},hidden:!0},{path:"/404",component:function(){return n.e("chunk-76cea4de").then(n.bind(null,"8cdb"))},hidden:!0},{path:"/",component:je,redirect:"/dashboard",children:[{path:"dashboard",name:"Dashboard",component:function(){return n.e("chunk-3465ad58").then(n.bind(null,"9406"))},meta:{title:"Dashboard",icon:"dashboard"}}]},{path:"/user",component:je,redirect:"/user/index",name:"User",meta:{title:"用户管理",icon:"el-icon-user"},children:[{path:"index",name:"UserIndex",component:function(){return n.e("chunk-be12e77a").then(n.bind(null,"e382"))},meta:{title:"用户列表",icon:"el-icon-user"}}]},{path:"/app",component:je,redirect:"/app/index",name:"App",meta:{title:"应用管理",icon:"el-icon-cherry"},children:[{path:"index",name:"AppIndex",component:function(){return n.e("chunk-8c1e49a2").then(n.bind(null,"f82c"))},meta:{title:"应用列表",icon:"el-icon-notebook-2"}},{path:"group",name:"Group",component:function(){return n.e("chunk-d57827a0").then(n.bind(null,"84f2"))},meta:{title:"应用组",icon:"el-icon-copy-document"}},{path:"taskList",name:"TaskList",component:function(){return n.e("chunk-04efd970").then(n.bind(null,"c430b"))},meta:{title:"任务列表",icon:"el-icon-bank-card"}},{path:"publish",name:"Publish",component:function(){return Promise.all([n.e("chunk-0c0c47bd"),n.e("chunk-093f04d7")]).then(n.bind(null,"1e63"))},meta:{title:"发布容器",icon:"form"}}]},{path:"/server",component:je,redirect:"/server/docker",name:"Server",meta:{title:"主机管理",icon:"el-icon-s-help"},children:[{path:"docker",name:"Docker",component:function(){return n.e("chunk-b73ad414").then(n.bind(null,"58b2"))},meta:{title:"主机管理",icon:"table"}}]},{path:"/container",component:je,redirect:"/container/container",name:"Container",meta:{title:"容器管理",icon:"el-icon-s-help"},children:[{path:"container",name:"ContainerList",component:function(){return n.e("chunk-4e661b5c").then(n.bind(null,"a352"))},meta:{title:"容器",icon:"tree"}},{path:"stats",name:"Stats",component:function(){return n.e("chunk-a7fcc1ea").then(n.bind(null,"5bc5"))},meta:{title:"最新状态",icon:"el-icon-date"}},{path:"tailLog",name:"tailLog",component:function(){return n.e("chunk-350622dd").then(n.bind(null,"be69"))},meta:{title:"实时日志",icon:"el-icon-s-order"}},{path:"connect",name:"connect",component:function(){return Promise.all([n.e("chunk-65f486c0"),n.e("chunk-bd5fa1ce")]).then(n.bind(null,"0faa"))},meta:{title:"连接容器",icon:"el-icon-s-order"}}]},{path:"/image",component:je,redirect:"/image/list",name:"Image",meta:{title:"镜像管理",icon:"el-icon-document-copy"},children:[{path:"list",name:"List",component:function(){return n.e("chunk-784647d6").then(n.bind(null,"e036"))},meta:{title:"镜像管理",icon:"el-icon-document-copy"}}]},{path:"/config",component:je,redirect:"/config/agent",name:"Config",meta:{title:"配置管理",icon:"el-icon-setting"},children:[{path:"agent",name:"Agent",component:function(){return n.e("chunk-06ff5938").then(n.bind(null,"eb43"))},meta:{title:"客户端配置",icon:"el-icon-setting"}},{path:"white",name:"white",component:function(){return n.e("chunk-63945102").then(n.bind(null,"45ee"))},meta:{title:"白名单IP",icon:"el-icon-guide"}}]},{path:"*",redirect:"/404",hidden:!0}],$e=function(){return new o["a"]({scrollBehavior:function(){return{y:0}},routes:Te})},Le=$e();function Be(){var e=$e();Le.matcher=e.matcher}t["a"]=Le},b20f:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409eff",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},b3b5:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-user",use:"icon-user-usage",viewBox:"0 0 130 130",content:''});r.a.add(s);t["default"]=s},b775:function(e,t,n){"use strict";n("d3b7");var a=n("bc3a"),o=n.n(a),i=n("5c96"),r=n("4360"),s=n("5f87"),c=o.a.create({baseURL:"/dockerMgrApi",timeout:3e4,headers:{"Content-Type":"application/json"}});c.interceptors.request.use((function(e){return r["a"].getters.token&&(e.headers["authorization"]=Object(s["a"])()),e}),(function(e){return console.log("error:",e),Promise.reject(e)})),c.interceptors.response.use((function(e){var t=e.data;return"100200"!==t.code?("105101"===t.code?i["MessageBox"].confirm("你已经离线,请重新登录","登录检查",{confirmButtonText:"重新登录",cancelButtonText:"取消",type:"warning"}).then((function(){r["a"].dispatch("user/resetToken").then((function(){location.reload()}))})):Object(i["Message"])({message:t.msg||"Error",type:"error",duration:5e3}),Promise.reject(new Error(t.msg||"Error"))):t}),(function(e){return Object(i["Message"])({message:e+"",type:"error",duration:5e3}),Promise.reject(e)})),t["a"]=c},bf4f:function(e,t,n){"use strict";n("9874")},c24f:function(e,t,n){"use strict";n.d(t,"h",(function(){return o})),n.d(t,"f",(function(){return i})),n.d(t,"g",(function(){return r})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return c})),n.d(t,"d",(function(){return l})),n.d(t,"b",(function(){return u})),n.d(t,"j",(function(){return d})),n.d(t,"i",(function(){return f})),n.d(t,"e",(function(){return h}));var a=n("b775");function o(e){return Object(a["a"])({url:"/user/login",method:"post",data:e})}function i(e){return Object(a["a"])({url:"/user/info",method:"get"})}function r(){return Object(a["a"])({url:"/user/userList",method:"get"})}function s(e){return Object(a["a"])({url:"/user/changeStatus",method:"post",data:e})}function c(e){return Object(a["a"])({url:"/user/addUser",method:"post",data:e})}function l(e){return Object(a["a"])({url:"/user/deleteUser",method:"post",data:e})}function u(e){return Object(a["a"])({url:"/user/alterPassword",method:"post",data:e})}function d(e){return Object(a["a"])({url:"/user/resetPassword",method:"post",data:e})}function f(){return Object(a["a"])({url:"/user/logout",method:"post"})}function h(e){return Object(a["a"])({url:"/user/forgetPassword",method:"post",data:e})}},c763:function(e,t,n){},cf1e:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409eff",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},d7ec:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-eye-open",use:"icon-eye-open-usage",viewBox:"0 0 1024 1024",content:''});r.a.add(s);t["default"]=s},d977:function(e,t,n){"use strict";n("20ef")},dcf8:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-nested",use:"icon-nested-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},e4de:function(e,t,n){"use strict";n("c763")},e579:function(e,t,n){"use strict";var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticStyle:{float:"left"}},[n("el-select",{staticStyle:{width:"90px",height:"30px","margin-right":"10px",border:"none"},attrs:{size:"mini"},on:{change:e.changeLanguage},model:{value:e.lang,callback:function(t){e.lang=t},expression:"lang"}},e._l(e.langs,(function(e){return n("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)],1)},o=[],i={name:"Lang",data:function(){return{langs:[{label:"English",value:"en"},{label:"中文",value:"zh"}],lang:"zh"}},created:function(){this.lang=this.$i18n.locale},methods:{changeLanguage:function(e){localStorage.setItem("locale",e),localStorage.locale=e,this.$i18n.locale=e}}},r=i,s=n("2877"),c=Object(s["a"])(r,a,o,!1,null,null,null);t["a"]=c.exports},e72f:function(e,t,n){"use strict";n("8e1d")},eae4:function(e,t,n){},eb1b:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-form",use:"icon-form-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},ed08:function(e,t,n){"use strict";n.d(t,"b",(function(){return o})),n.d(t,"d",(function(){return r})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return c}));var a=n("53ca");n("ac1f"),n("5319"),n("4d63"),n("25f0"),n("d3b7"),n("4d90"),n("a15b"),n("d81d"),n("b64b"),n("1276"),n("159b");function o(){return("http:"===location.protocol?"ws:":"wss:")+location.host}function i(e,t){if(0===arguments.length||!e)return null;var n,o=t||"{y}-{m}-{d} {h}:{i}:{s}";"object"===Object(a["a"])(e)?n=e:("string"===typeof e&&(e=/^[0-9]+$/.test(e)?parseInt(e):e.replace(new RegExp(/-/gm),"/")),"number"===typeof e&&10===e.toString().length&&(e*=1e3),n=new Date(e));var i={y:n.getFullYear(),m:n.getMonth()+1,d:n.getDate(),h:n.getHours(),i:n.getMinutes(),s:n.getSeconds(),a:n.getDay()},r=o.replace(/{([ymdhisa])+}/g,(function(e,t){var n=i[t];return"a"===t?["日","一","二","三","四","五","六"][n]:n.toString().padStart(2,"0")}));return r}function r(e,t){if(0===e)return"-";e=10===(""+e).length?1e3*parseInt(e):+e;var n=new Date(e),a=Date.now(),o=(a-n)/1e3;return o<30?"刚刚":o<3600?Math.ceil(o/60)+"分钟前":o<86400?Math.ceil(o/3600)+"小时前":o<172800?"1天前":t?i(e,t):n.getMonth()+1+"月"+n.getDate()+"日"+n.getHours()+"时"+n.getMinutes()+"分"}function s(e){if(!e)return"";e=e>0xee09da7916?e:1e3*e;var t=new Date(e),n=t.getFullYear()+"-",a=(t.getMonth()+1<10?"0"+(t.getMonth()+1):t.getMonth()+1)+"-",o=t.getDate()<10?"0"+t.getDate():t.getDate(),i=(t.getHours()<10?"0"+t.getHours():t.getHours())+":",r=(t.getMinutes()<10?"0"+t.getMinutes():t.getMinutes())+":",s=(t.getSeconds()<10?"0"+t.getSeconds():t.getSeconds())+".",c="";return c=t.getMilliseconds()<10?"00"+t.getMilliseconds():t.getMilliseconds()<100?"0"+t.getMilliseconds():t.getMilliseconds(),n+a+o+" "+i+r+s+c}function c(e,t){for(var n=e.split("."),a=t.split("."),o=0;or)return 1;if(i=6","首页":"Home","密码修改":"Alter Password","退出":"Logout","刷新容器列表":"Refresh container list","刷新容器状态":"Refresh container status","刷新成功":"Refresh Success","主机":"Server","主机管理":"Host Manager","容器":"Container","运行中":"Running","已停止":"Stop","任务":"Task","镜像":"Image","应用":"App","实时日志开启数量":"Num of open log tail","目标主机":"Dest Server","正在进行":"Doing","完成":"Finish","失败":"Fail","仪表盘":"Dashboard","用户管理":"User Manager","用户列表":"User List","应用管理":"App Manager","发布管理":"Publish Manager","应用列表":"App List","应用组":"App Group","任务列表":"Task List","发布容器":"Publish Container","客户端配置":"Agent Config","容器管理":"Container Manager","最新状态":"Last Status","实时日志":"Live Log","状态":"Status","操作":"Operation","禁用":"Disable","恢复":"Enable","密码重置":"Reset Password","正常":"Normal","密码仅显示一次,请备份:":"Password only show once, please back up:","密码重置成功":"Password reset success","确定":"OK","取消":"Cancel","旧密码":"Old password","请输入旧密码":"Please input old password","新密码":"New password","输入新密码":"Please input new password","修改密码":"Alter password","删除":"Delete","更新":"Update","命令":"Command","信息":"Info","发布时间":"Publish Time","成功":"Success","停止":"Stop","重启":"Restart","详情":"Detail","命令下发成功":"Send command success","容器名称":"Container Name","是":"Yes","否":"No","是否开启日志":"Is open tail log","未开启":"Not open","已开启":"Open","开启日志":"Open log","关闭日志":"Close log","命令已下发":"Command issued","配置管理":"Config Manager","目标容器":"Dest Container","显示日志系统时间":"Show log system time","连接日志":"Connect log","断开连接":"Disconnect log","必须选择容器":"Must select a container","正在连接...":"Connecting ...","连接成功.":"Connected.","连接发生错误.":"Connect error.","连接已关闭.":"Disconnect.","字段名称":"Key","值":"Value","备注":"Memo","临时记录区域":"Temporary recording area","添加":"Add","内存(M)":"Memory(M)","端口映射":"Port Mapping","卷映射":"Volume Mapping","Bind模式相当于docker -v参数。如何挂载卷?":"The bind mode is equivalent to the \'docker -v\'. How do I mount a volume?","源地址(宿主机地址)":"Src path (Host server path)","绑定方式":"Bind type","容器内地址":"Path in container","读写":"Read and write","只读":"Read only","环境变量":"Environment val","变量key":"Key","变量值":"Value","日志驱动":"Log driver","请选择":"Please select","如何选择日志驱动?":"How to select a log driver?","日志配置参数":"Config log param","发布":"Publish","添加用户":"Add user","昵称":"Nickname","邮箱":"Email","手机":"Mobile","角色":"Role","超级管理员":"Super Admin","客户端代理":"Docker Agent","请输入邮箱地址":"Please input email","请输入正确的邮箱地址":"Please input correct email","请输入昵称":"Please input nickname","请输入正确的昵称":"Please input correct nickname","请输入用户名":"Please input username","请输入手机号码":"Please input mobile number","请输入正确的手机号码":"Please input correct mobile number","请输入密码":"Please input password","请输入正确密码":"Please input correct password","当前版本":"Current version","功能开发中...":"Function development","镜像管理":"Image Manage","镜像名称":"Image Name","输入关键字过滤":"Please input keyword to filter","在线":"Online","总计":"Total","运行容器":"ContainerRunning","过滤关键字":"filter key word","忘记密码":"Forget password","管理员找回密码":"Forget admin password","非管理员找回密码":"Non administrator retrieve password","用户名或邮箱":"Username or email","重置密码":"Reset password","请输入用户名或邮箱":"Please input username or email","控制台验证码":"Console verification code","邮箱验证码":"Mail verification code","获取验证码":"Get verification code","请输入验证码":"Please input verification code","验证码将会打印到docker-manager的控制台日志":"The verification code will be printed to the docker-manager\'s console log","请输入":"Please input ","提示":"Tip","格式不正确":"Incorrect format","白名单IP":"IP White list","请联系管理员,重置密码":"Please contact the administrator to reset the password"}')},f782:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-dashboard",use:"icon-dashboard-usage",viewBox:"0 0 128 100",content:''});r.a.add(s);t["default"]=s}},[[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";n("3f4d")},"186a":function(e,t,n){"use strict";n("9df4")},"18f0":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-link",use:"icon-link-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},"20ef":function(e,t,n){},"263d":function(e,t,n){},"2a3d":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-password",use:"icon-password-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},"30c3":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-example",use:"icon-example-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},3504:function(e){e.exports=JSON.parse('{"message":"hello i18n !!","hello":"你好, i18n !","首页":"首页","密码修改":"密码修改","退出":"退出","刷新容器列表":"刷新容器列表","刷新容器状态":"刷新容器状态"}')},"3f4d":function(e,t,n){},"3fbd":function(e,t,n){"use strict";n("263d")},4314:function(e,t,n){},4360:function(e,t,n){"use strict";var a=n("2b0e"),o=n("2f62"),i=(n("b0c0"),{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}}),r=i,s=n("a78e"),c=n.n(s),l={sidebar:{opened:!c.a.get("sidebarStatus")||!!+c.a.get("sidebarStatus"),withoutAnimation:!1},device:"desktop"},u={TOGGLE_SIDEBAR:function(e){e.sidebar.opened=!e.sidebar.opened,e.sidebar.withoutAnimation=!1,e.sidebar.opened?c.a.set("sidebarStatus",1):c.a.set("sidebarStatus",0)},CLOSE_SIDEBAR:function(e,t){c.a.set("sidebarStatus",0),e.sidebar.opened=!1,e.sidebar.withoutAnimation=t},TOGGLE_DEVICE:function(e,t){e.device=t}},d={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)}},f={namespaced:!0,state:l,mutations:u,actions:d},m=n("83d6"),h=n.n(m),p=h.a.showSettings,g=h.a.fixedHeader,b=h.a.sidebarLogo,v={showSettings:p,fixedHeader:g,sidebarLogo:b},w={CHANGE_SETTING:function(e,t){var n=t.key,a=t.value;e.hasOwnProperty(n)&&(e[n]=a)}},x={changeSetting:function(e,t){var n=e.commit;n("CHANGE_SETTING",t)}},k={namespaced:!0,state:v,mutations:w,actions:x},y=(n("d3b7"),n("498a"),n("c24f")),O=n("5f87"),C=n("a18c"),S=function(){return{token:Object(O["a"])(),name:"",avatar:""}},M=S(),_={RESET_STATE:function(e){Object.assign(e,S())},SET_TOKEN:function(e,t){e.token=t},SET_NAME:function(e,t){e.name=t},SET_AVATAR:function(e,t){e.avatar=t}},E={login:function(e,t){var n=e.commit,a=t.username,o=t.password;return new Promise((function(e,t){Object(y["h"])({username:a.trim(),password:o}).then((function(t){var a=t.data;n("SET_TOKEN",a),Object(O["c"])(a),e()})).catch((function(e){console.log("login.error:",e),t(e)}))}))},getInfo:function(e){var t=e.commit,n=e.state;return new Promise((function(e,a){Object(y["f"])(n.token).then((function(n){var o=n.data;if(!o)return a("Verification failed, please Login again.");var i=o.name,r=o.avatar;t("SET_NAME",i),t("SET_AVATAR",r),e(o)})).catch((function(e){a(e)}))}))},logout:function(e){var t=e.commit,n=e.state;return new Promise((function(e,a){Object(y["i"])(n.token).then((function(){Object(O["b"])(),Object(C["b"])(),t("RESET_STATE"),e()})).catch((function(e){a(e)}))}))},resetToken:function(e){var t=e.commit;return new Promise((function(e){Object(O["b"])(),t("RESET_STATE"),e()}))}},H={namespaced:!0,state:M,mutations:_,actions:E};a["default"].use(o["a"]);var z=new o["a"].Store({modules:{app:f,settings:k,user:H},getters:r});t["a"]=z},"47f1":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-table",use:"icon-table-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},"49f8":function(e,t,n){var a={"./en.json":"edd4","./zh.json":"3504"};function o(e){var t=i(e);return n(t)}function i(e){if(!n.o(a,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return a[e]}o.keys=function(){return Object.keys(a)},o.resolve=i,e.exports=o,o.id="49f8"},"4df5":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-eye",use:"icon-eye-usage",viewBox:"0 0 128 64",content:''});r.a.add(s);t["default"]=s},"51ff":function(e,t,n){var a={"./dashboard.svg":"f782","./example.svg":"30c3","./eye-open.svg":"d7ec","./eye.svg":"4df5","./form.svg":"eb1b","./link.svg":"18f0","./nested.svg":"dcf8","./password.svg":"2a3d","./table.svg":"47f1","./tree.svg":"93cd","./user.svg":"b3b5"};function o(e){var t=i(e);return n(t)}function i(e){if(!n.o(a,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return a[e]}o.keys=function(){return Object.keys(a)},o.resolve=i,e.exports=o,o.id="51ff"},"56d7":function(e,t,n){"use strict";n.r(t);n("e260"),n("e6cf"),n("cca6"),n("a79d");var a=n("2b0e"),o=(n("f5df1"),n("5c96")),i=n.n(o),r=(n("0fae"),n("b20f"),function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{attrs:{id:"app"}},[n("router-view")],1)}),s=[],c={name:"App"},l=c,u=n("2877"),d=Object(u["a"])(l,r,s,!1,null,null,null),f=d.exports,m=n("4360"),h=n("a18c"),p=(n("d81d"),n("d3b7"),n("ddb0"),function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.isExternal?n("div",e._g({staticClass:"svg-external-icon svg-icon",style:e.styleExternalIcon},e.$listeners)):n("svg",e._g({class:e.svgClass,attrs:{"aria-hidden":"true"}},e.$listeners),[n("use",{attrs:{"xlink:href":e.iconName}})])}),g=[],b=n("61f7"),v={name:"SvgIcon",props:{iconClass:{type:String,required:!0},className:{type:String,default:""}},computed:{isExternal:function(){return Object(b["c"])(this.iconClass)},iconName:function(){return"#icon-".concat(this.iconClass)},svgClass:function(){return this.className?"svg-icon "+this.className:"svg-icon"},styleExternalIcon:function(){return{mask:"url(".concat(this.iconClass,") no-repeat 50% 50%"),"-webkit-mask":"url(".concat(this.iconClass,") no-repeat 50% 50%")}}}},w=v,x=(n("68fa"),Object(u["a"])(w,p,g,!1,null,"f9f7fefc",null)),k=x.exports;a["default"].component("svg-icon",k);var y=n("51ff"),O=function(e){return e.keys().map(e)};O(y);var C=n("1da1"),S=(n("96cf"),n("b0c0"),n("323e")),M=n.n(S),_=(n("a5d8"),n("5f87")),E=(n("99af"),n("83d6")),H=n.n(E),z=H.a.title||"Docker Manager";function P(e){return e?"".concat(e," - ").concat(z):"".concat(z)}M.a.configure({showSpinner:!1});var j=["/login","/forget"];h["a"].beforeEach(function(){var e=Object(C["a"])(regeneratorRuntime.mark((function e(t,n,a){var i,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(M.a.start(),document.title=P(t.meta.title),i=Object(_["a"])(),!i){e.next=29;break}if("/login"!==t.path){e.next=9;break}a({path:"/"}),M.a.done(),e.next=27;break;case 9:if(r=m["a"].getters.name,!r){e.next=14;break}a(),e.next=27;break;case 14:return e.prev=14,e.next=17,m["a"].dispatch("user/getInfo");case 17:a(),e.next=27;break;case 20:return e.prev=20,e.t0=e["catch"](14),e.next=24,m["a"].dispatch("user/resetToken");case 24:o["Message"].error(e.t0||"Has Error"),a("/login?redirect=".concat(t.path)),M.a.done();case 27:e.next=30;break;case 29:-1!==j.indexOf(t.path)?a():(a("/login?redirect=".concat(t.path)),M.a.done());case 30:case"end":return e.stop()}}),e,null,[[14,20]])})));return function(t,n,a){return e.apply(this,arguments)}}()),h["a"].afterEach((function(){M.a.done()}));n("159b"),n("ac1f"),n("466d"),n("1276");var T=n("a925");function $(){var e=n("49f8"),t={};return e.keys().forEach((function(n){var a=n.match(/([A-Za-z0-9-_]+)\./i);if(a&&a.length>1){var o=a[1];t[o]=e(n)}})),t}function L(){return localStorage&&localStorage.locale?localStorage.locale:(navigator.language||navigator.userLanguage).split("-")[0]}a["default"].use(T["a"]);var B=new T["a"]({locale:L(),fallbackLocale:"zh",silentTranslationWarn:!0,messages:$()});a["default"].use(i.a),a["default"].config.productionTip=!1,new a["default"]({el:"#app",i18n:B,router:h["a"],store:m["a"],render:function(e){return e(f)}})},"5f87":function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"c",(function(){return s})),n.d(t,"b",(function(){return c}));var a=n("a78e"),o=n.n(a),i="c-token";function r(){return o.a.get(i)}function s(e){return o.a.set(i,e)}function c(){return o.a.remove(i)}},"60de":function(e,t,n){"use strict";n("4314")},"61f7":function(e,t,n){"use strict";n.d(t,"c",(function(){return a})),n.d(t,"d",(function(){return o})),n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return r}));n("498a");function a(e){return/^(https?:|mailto:|tel:)/.test(e)}function o(e){var t=["admin","editor"];return t.indexOf(e.trim())>=0}function i(e,t,n){var a=/^1[3|4|5|6|7|8|9]\d{9}$/;return t?a.test(t)?void n():n(new Error("请填写正确的手机号码!")):n(new Error("请填写手机号码!"))}function r(e,t,n){var a=/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;return t?a.test(t)?void n():n(new Error("证件号码不正确")):n(new Error("证件号码不能为空"))}},"68fa":function(e,t,n){"use strict";n("eae4")},"83d6":function(e,t){e.exports={title:"Docker Manager",fixedHeader:!1,sidebarLogo:!1}},"8e1d":function(e,t,n){},"93cd":function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-tree",use:"icon-tree-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},9874:function(e,t,n){},"9df4":function(e,t,n){},a18c:function(e,t,n){"use strict";n.d(t,"b",(function(){return Be}));n("d3b7"),n("3ca3"),n("ddb0");var a=n("2b0e"),o=n("8c4f"),i=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(),n("sidebar",{staticClass:"sidebar-container"}),n("div",{staticClass:"main-container"},[n("div",{class:{"fixed-header":e.fixedHeader}},[n("navbar")],1),n("app-main")],1)],1)},r=[],s=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"navbar"},[n("hamburger",{staticClass:"hamburger-container",attrs:{"is-active":e.sidebar.opened},on:{toggleClick:e.toggleSideBar}}),n("breadcrumb",{staticClass:"breadcrumb-container"}),n("div",{staticClass:"right-menu"},[n("a",{attrs:{href:"https://hub.docker.com/r/xiaojun207/docker-manager/tags",target:"_blank"}},[n("div",{staticStyle:{float:"left","margin-right":"40px",color:"#3f3e3e"}},[n("el-badge",{staticClass:"item",staticStyle:{"line-height":"30px"},attrs:{value:e.version.upgrade?"new":""}},[e._v(e._s(e.$t("当前版本"))+" : "+e._s(e.version.current))])],1)]),n("lang"),n("el-dropdown",{staticClass:"avatar-container",attrs:{trigger:"click"}},[n("div",{staticClass:"avatar-wrapper"},[n("el-avatar",{attrs:{src:e.avatar}},[n("img",{attrs:{src:"https://cube.elemecdn.com/e/fd/0fc7d20532fdaf769a25683617711png.png"}})]),n("i",{staticClass:"el-icon-caret-bottom"})],1),n("el-dropdown-menu",{staticClass:"user-dropdown",attrs:{slot:"dropdown"},slot:"dropdown"},[n("router-link",{attrs:{to:"/"}},[n("el-dropdown-item",[e._v(" "+e._s(e.$t("首页"))+" ")])],1),n("el-button",{attrs:{type:"text"},on:{click:function(t){e.dialogVisible=!0}}},[n("el-dropdown-item",[e._v(" "+e._s(e.$t("密码修改"))+" ")])],1),n("el-dropdown-item",{attrs:{divided:""},nativeOn:{click:function(t){return e.logout(t)}}},[n("span",{staticStyle:{display:"block"}},[e._v(e._s(e.$t("退出")))])])],1)],1)],1),n("el-dialog",{attrs:{title:"添加用户",visible:e.dialogVisible,width:"30%"},on:{"update:visible":function(t){e.dialogVisible=t}}},[n("el-form",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],ref:"form",attrs:{"label-position":"right",model:e.form,"label-width":"80px"}},[n("el-form-item",{attrs:{label:e.$t("旧密码")}},[n("el-input",{attrs:{placeholder:e.$t("请输入旧密码"),"show-password":""},model:{value:e.form.OldPassword,callback:function(t){e.$set(e.form,"OldPassword",t)},expression:"form.OldPassword"}})],1),n("el-form-item",{attrs:{label:e.$t("新密码")}},[n("el-input",{attrs:{placeholder:e.$t("输入新密码"),"show-password":""},model:{value:e.form.NewPassword,callback:function(t){e.$set(e.form,"NewPassword",t)},expression:"form.NewPassword"}})],1)],1),n("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{on:{click:function(t){e.dialogVisible=!1,e.loading=!1}}},[e._v("取 消")]),n("el-button",{attrs:{type:"primary"},on:{click:e.onSubmit}},[e._v(e._s(e.$t("修改密码")))])],1)],1)],1)},c=[],l=n("1da1"),u=n("5530"),d=(n("96cf"),n("2f62")),f=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(e.$t(t.meta.title)))]):n("a",{on:{click:function(n){return n.preventDefault(),e.handleLink(t)}}},[e._v(e._s(e.$t(t.meta.title)))])])})),1)],1)},m=[],h=(n("4de4"),n("99af"),n("b0c0"),n("498a"),n("bd11")),p=n.n(h),g={data:function(){return{levelList:null}},watch:{$route:function(){this.getBreadcrumb()}},created:function(){this.getBreadcrumb()},methods:{t:function(e){return e},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:"Dashboard"}}].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=p.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))}}},b=g,v=(n("60de"),n("2877")),w=Object(v["a"])(b,f,m,!1,null,"2edef819",null),x=w.exports,k=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"}})])])},y=[],O={name:"Hamburger",props:{isActive:{type:Boolean,default:!1}},methods:{toggleClick:function(){this.$emit("toggleClick")}}},C=O,S=(n("186a"),Object(v["a"])(C,k,y,!1,null,"49e15297",null)),M=S.exports,_=n("e579"),E=n("c24f"),H=n("b775");function z(){return Object(H["a"])({url:"/base/version",method:"get"})}var P,j,T=n("ed08"),$={data:function(){return{dialogVisible:!1,loading:!1,version:{current:"1.0.0",latest:"1.0.0",upgrade:!0},form:{OldPassword:"",NewPassword:""}}},components:{Breadcrumb:x,Hamburger:M,Lang:_["a"]},computed:Object(u["a"])({},Object(d["b"])(["sidebar","avatar"])),created:function(){this.fetchData()},methods:{toggleSideBar:function(){this.$store.dispatch("app/toggleSideBar")},logout:function(){var e=this;return Object(l["a"])(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)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)})))()},onSubmit:function(){var e=this;this.loading=!0,console.log("this.form:",this.form),Object(E["b"])(this.form).then((function(t){e.$message(e.$t("修改成功")),e.loading=!1,e.dialogVisible=!1})).catch((function(t){e.loading=!1}))},fetchData:function(){var e=this;z().then((function(t){e.version=t.data,e.version.upgrade=Object(T["a"])(e.version.current,e.version.latest)<0}))}}},L=$,B=(n("e72f"),Object(v["a"])(L,s,c,!1,null,"48282632",null)),A=B.exports,D=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(),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)},V=[],I=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(),n("h1",{staticClass:"sidebar-title"},[e._v(e._s(e.title)+" ")])])],1)],1)},N=[],R={name:"SidebarLogo",props:{collapse:{type:Boolean,required:!0}},data:function(){return{title:"Docker Manager",logo:"https://wpimg.wallstcn.com/69a1c46c-eb1c-4b46-8bd4-e9e686ef5251.png"}}},q=R,G=(n("d977"),Object(v["a"])(q,I,N,!1,null,"2c1ebc72",null)),U=G.exports,F=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.item.hidden?e._e():n("div",[!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.$t(e.item.meta.title)}}):e._e()],1),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.$t(e.onlyOneChild.meta.title)}})],1)],1):e._e()]],2)},K=[],J=n("df7c"),W=n.n(J),Y=n("61f7"),X=(n("caad"),n("2532"),{name:"MenuItem",functional:!0,props:{icon:{type:String,default:""},title:{type:String,default:""}},render:function(e,t){var n=t.props,a=n.icon,o=n.title,i=[];return a&&(a.includes("el-icon")?i.push(e("i",{class:[a,"sub-el-icon"]})):i.push(e("svg-icon",{attrs:{"icon-class":a}}))),o&&i.push(e("span",{slot:"title"},[o])),i}}),Z=X,Q=(n("bf4f"),Object(v["a"])(Z,P,j,!1,null,"18eeea00",null)),ee=Q.exports,te=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n(e.type,e._b({tag:"component"},"component",e.linkProps(e.to),!1),[e._t("default")],2)},ne=[],ae={props:{to:{type:String,required:!0}},computed:{isExternal:function(){return Object(Y["c"])(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}}}},oe=ae,ie=Object(v["a"])(oe,te,ne,!1,null,null,null),re=ie.exports,se={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)}}}}},ce={name:"SidebarItem",components:{Item:ee,AppLink:re},mixins:[se],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(u["a"])(Object(u["a"])({},n),{},{path:"",noShowingChildren:!0}),!0)},resolvePath:function(e){return Object(Y["c"])(e)?e:Object(Y["c"])(this.basePath)?this.basePath:W.a.resolve(this.basePath,e)}}},le=ce,ue=Object(v["a"])(le,F,K,!1,null,null,null),de=ue.exports,fe=n("cf1e"),me=n.n(fe),he={components:{SidebarItem:de,Logo:U},computed:Object(u["a"])(Object(u["a"])({},Object(d["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 me.a},isCollapse:function(){return!this.sidebar.opened}})},pe=he,ge=Object(v["a"])(pe,D,V,!1,null,null,null),be=ge.exports,ve=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)},we=[],xe={name:"AppMain",computed:{key:function(){return this.$route.path}}},ke=xe,ye=(n("e4de"),n("028b"),Object(v["a"])(ke,ve,we,!1,null,"64cf4d83",null)),Oe=ye.exports,Ce=n("4360"),Se=document,Me=Se.body,_e=992,Ee={watch:{$route:function(e){"mobile"===this.device&&this.sidebar.opened&&Ce["a"].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&&(Ce["a"].dispatch("app/toggleDevice","mobile"),Ce["a"].dispatch("app/closeSideBar",{withoutAnimation:!0}))},methods:{$_isMobile:function(){var e=Me.getBoundingClientRect();return e.width-1<_e},$_resizeHandler:function(){if(!document.hidden){var e=this.$_isMobile();Ce["a"].dispatch("app/toggleDevice",e?"mobile":"desktop"),e&&Ce["a"].dispatch("app/closeSideBar",{withoutAnimation:!0})}}}},He={name:"Layout",components:{Navbar:A,Sidebar:be,AppMain:Oe},mixins:[Ee],computed:{sidebar:function(){return this.$store.state.app.sidebar},device:function(){return this.$store.state.app.device},fixedHeader:function(){return this.$store.state.settings.fixedHeader},classObj:function(){return{hideSidebar:!this.sidebar.opened,openSidebar:this.sidebar.opened,withoutAnimation:this.sidebar.withoutAnimation,mobile:"mobile"===this.device}}},methods:{handleClickOutside:function(){this.$store.dispatch("app/closeSideBar",{withoutAnimation:!1})}}},ze=He,Pe=(n("3fbd"),Object(v["a"])(ze,i,r,!1,null,"81617ce2",null)),je=Pe.exports;a["default"].use(o["a"]);var Te=[{path:"/login",component:function(){return Promise.all([n.e("chunk-4794904a"),n.e("chunk-b415acce")]).then(n.bind(null,"9ed6"))},hidden:!0},{path:"/forget",component:function(){return n.e("chunk-20b64ef3").then(n.bind(null,"d794"))},hidden:!0},{path:"/404",component:function(){return n.e("chunk-76cea4de").then(n.bind(null,"8cdb"))},hidden:!0},{path:"/",component:je,redirect:"/dashboard",children:[{path:"dashboard",name:"Dashboard",component:function(){return n.e("chunk-3465ad58").then(n.bind(null,"9406"))},meta:{title:"Dashboard",icon:"dashboard"}}]},{path:"/user",component:je,redirect:"/user/index",name:"User",meta:{title:"用户管理",icon:"el-icon-user"},children:[{path:"index",name:"UserIndex",component:function(){return n.e("chunk-be12e77a").then(n.bind(null,"e382"))},meta:{title:"用户列表",icon:"el-icon-user"}}]},{path:"/app",component:je,redirect:"/app/index",name:"App",meta:{title:"应用管理",icon:"el-icon-cherry"},children:[{path:"index",name:"AppIndex",component:function(){return n.e("chunk-8c1e49a2").then(n.bind(null,"f82c"))},meta:{title:"应用列表",icon:"el-icon-notebook-2"}},{path:"group",name:"Group",component:function(){return n.e("chunk-d57827a0").then(n.bind(null,"84f2"))},meta:{title:"应用组",icon:"el-icon-copy-document"}},{path:"taskList",name:"TaskList",component:function(){return n.e("chunk-04efd970").then(n.bind(null,"c430b"))},meta:{title:"任务列表",icon:"el-icon-bank-card"}},{path:"publish",name:"Publish",component:function(){return Promise.all([n.e("chunk-0c0c47bd"),n.e("chunk-093f04d7")]).then(n.bind(null,"1e63"))},meta:{title:"发布容器",icon:"form"}}]},{path:"/server",component:je,redirect:"/server/docker",name:"Server",meta:{title:"主机管理",icon:"el-icon-s-help"},children:[{path:"docker",name:"Docker",component:function(){return n.e("chunk-b73ad414").then(n.bind(null,"58b2"))},meta:{title:"主机管理",icon:"table"}}]},{path:"/container",component:je,redirect:"/container/container",name:"Container",meta:{title:"容器管理",icon:"el-icon-s-help"},children:[{path:"container",name:"ContainerList",component:function(){return n.e("chunk-4e661b5c").then(n.bind(null,"a352"))},meta:{title:"容器",icon:"tree"}},{path:"stats",name:"Stats",component:function(){return n.e("chunk-a7fcc1ea").then(n.bind(null,"5bc5"))},meta:{title:"最新状态",icon:"el-icon-date"}},{path:"tailLog",name:"tailLog",component:function(){return n.e("chunk-350622dd").then(n.bind(null,"be69"))},meta:{title:"实时日志",icon:"el-icon-s-order"}},{path:"connect",name:"connect",component:function(){return Promise.all([n.e("chunk-65f486c0"),n.e("chunk-bd5fa1ce")]).then(n.bind(null,"0faa"))},meta:{title:"连接容器",icon:"el-icon-s-order"}}]},{path:"/image",component:je,redirect:"/image/list",name:"Image",meta:{title:"镜像管理",icon:"el-icon-document-copy"},children:[{path:"list",name:"List",component:function(){return n.e("chunk-784647d6").then(n.bind(null,"e036"))},meta:{title:"镜像管理",icon:"el-icon-document-copy"}}]},{path:"/config",component:je,redirect:"/config/agent",name:"Config",meta:{title:"配置管理",icon:"el-icon-setting"},children:[{path:"agent",name:"Agent",component:function(){return n.e("chunk-06ff5938").then(n.bind(null,"eb43"))},meta:{title:"客户端配置",icon:"el-icon-setting"}},{path:"white",name:"white",component:function(){return n.e("chunk-63945102").then(n.bind(null,"45ee"))},meta:{title:"白名单IP",icon:"el-icon-guide"}},{path:"forbidden",name:"forbidden",component:function(){return n.e("chunk-51b20511").then(n.bind(null,"01d2"))},meta:{title:"禁用记录IP",icon:"el-icon-document"}}]},{path:"*",redirect:"/404",hidden:!0}],$e=function(){return new o["a"]({scrollBehavior:function(){return{y:0}},routes:Te})},Le=$e();function Be(){var e=$e();Le.matcher=e.matcher}t["a"]=Le},b20f:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409eff",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},b3b5:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-user",use:"icon-user-usage",viewBox:"0 0 130 130",content:''});r.a.add(s);t["default"]=s},b775:function(e,t,n){"use strict";n("d3b7");var a=n("bc3a"),o=n.n(a),i=n("5c96"),r=n("4360"),s=n("5f87"),c=o.a.create({baseURL:"/dockerMgrApi",timeout:3e4,headers:{"Content-Type":"application/json"}});c.interceptors.request.use((function(e){return r["a"].getters.token&&(e.headers["authorization"]=Object(s["a"])()),e}),(function(e){return console.log("error:",e),Promise.reject(e)})),c.interceptors.response.use((function(e){var t=e.data;return"100200"!==t.code?("105101"===t.code?i["MessageBox"].confirm("你已经离线,请重新登录","登录检查",{confirmButtonText:"重新登录",cancelButtonText:"取消",type:"warning"}).then((function(){r["a"].dispatch("user/resetToken").then((function(){location.reload()}))})):Object(i["Message"])({message:t.msg||"Error",type:"error",duration:5e3}),Promise.reject(new Error(t.msg||"Error"))):t}),(function(e){return Object(i["Message"])({message:e+"",type:"error",duration:5e3}),Promise.reject(e)})),t["a"]=c},bf4f:function(e,t,n){"use strict";n("9874")},c24f:function(e,t,n){"use strict";n.d(t,"h",(function(){return o})),n.d(t,"f",(function(){return i})),n.d(t,"g",(function(){return r})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return c})),n.d(t,"d",(function(){return l})),n.d(t,"b",(function(){return u})),n.d(t,"j",(function(){return d})),n.d(t,"i",(function(){return f})),n.d(t,"e",(function(){return m}));var a=n("b775");function o(e){return Object(a["a"])({url:"/user/login",method:"post",data:e})}function i(e){return Object(a["a"])({url:"/user/info",method:"get"})}function r(){return Object(a["a"])({url:"/user/userList",method:"get"})}function s(e){return Object(a["a"])({url:"/user/changeStatus",method:"post",data:e})}function c(e){return Object(a["a"])({url:"/user/addUser",method:"post",data:e})}function l(e){return Object(a["a"])({url:"/user/deleteUser",method:"post",data:e})}function u(e){return Object(a["a"])({url:"/user/alterPassword",method:"post",data:e})}function d(e){return Object(a["a"])({url:"/user/resetPassword",method:"post",data:e})}function f(){return Object(a["a"])({url:"/user/logout",method:"post"})}function m(e){return Object(a["a"])({url:"/user/forgetPassword",method:"post",data:e})}},c763:function(e,t,n){},cf1e:function(e,t,n){e.exports={menuText:"#bfcbd9",menuActiveText:"#409eff",subMenuActiveText:"#f4f4f5",menuBg:"#304156",menuHover:"#263445",subMenuBg:"#1f2d3d",subMenuHover:"#001528",sideBarWidth:"210px"}},d7ec:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-eye-open",use:"icon-eye-open-usage",viewBox:"0 0 1024 1024",content:''});r.a.add(s);t["default"]=s},d977:function(e,t,n){"use strict";n("20ef")},dcf8:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-nested",use:"icon-nested-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},e4de:function(e,t,n){"use strict";n("c763")},e579:function(e,t,n){"use strict";var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticStyle:{float:"left"}},[n("el-select",{staticStyle:{width:"90px",height:"30px","margin-right":"10px",border:"none"},attrs:{size:"mini"},on:{change:e.changeLanguage},model:{value:e.lang,callback:function(t){e.lang=t},expression:"lang"}},e._l(e.langs,(function(e){return n("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)],1)},o=[],i={name:"Lang",data:function(){return{langs:[{label:"English",value:"en"},{label:"中文",value:"zh"}],lang:"zh"}},created:function(){this.lang=this.$i18n.locale},methods:{changeLanguage:function(e){localStorage.setItem("locale",e),localStorage.locale=e,this.$i18n.locale=e}}},r=i,s=n("2877"),c=Object(s["a"])(r,a,o,!1,null,null,null);t["a"]=c.exports},e72f:function(e,t,n){"use strict";n("8e1d")},eae4:function(e,t,n){},eb1b:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-form",use:"icon-form-usage",viewBox:"0 0 128 128",content:''});r.a.add(s);t["default"]=s},ed08:function(e,t,n){"use strict";n.d(t,"b",(function(){return o})),n.d(t,"d",(function(){return r})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return c}));var a=n("53ca");n("ac1f"),n("5319"),n("4d63"),n("25f0"),n("d3b7"),n("4d90"),n("a15b"),n("d81d"),n("b64b"),n("1276"),n("159b");function o(){return("http:"===location.protocol?"ws:":"wss:")+location.host}function i(e,t){if(0===arguments.length||!e)return null;var n,o=t||"{y}-{m}-{d} {h}:{i}:{s}";"object"===Object(a["a"])(e)?n=e:("string"===typeof e&&(e=/^[0-9]+$/.test(e)?parseInt(e):e.replace(new RegExp(/-/gm),"/")),"number"===typeof e&&10===e.toString().length&&(e*=1e3),n=new Date(e));var i={y:n.getFullYear(),m:n.getMonth()+1,d:n.getDate(),h:n.getHours(),i:n.getMinutes(),s:n.getSeconds(),a:n.getDay()},r=o.replace(/{([ymdhisa])+}/g,(function(e,t){var n=i[t];return"a"===t?["日","一","二","三","四","五","六"][n]:n.toString().padStart(2,"0")}));return r}function r(e,t){if(0===e)return"-";e=10===(""+e).length?1e3*parseInt(e):+e;var n=new Date(e),a=Date.now(),o=(a-n)/1e3;return o<30?"刚刚":o<3600?Math.ceil(o/60)+"分钟前":o<86400?Math.ceil(o/3600)+"小时前":o<172800?"1天前":t?i(e,t):n.getMonth()+1+"月"+n.getDate()+"日"+n.getHours()+"时"+n.getMinutes()+"分"}function s(e){if(!e)return"";e=e>0xee09da7916?e:1e3*e;var t=new Date(e),n=t.getFullYear()+"-",a=(t.getMonth()+1<10?"0"+(t.getMonth()+1):t.getMonth()+1)+"-",o=t.getDate()<10?"0"+t.getDate():t.getDate(),i=(t.getHours()<10?"0"+t.getHours():t.getHours())+":",r=(t.getMinutes()<10?"0"+t.getMinutes():t.getMinutes())+":",s=(t.getSeconds()<10?"0"+t.getSeconds():t.getSeconds())+".",c="";return c=t.getMilliseconds()<10?"00"+t.getMilliseconds():t.getMilliseconds()<100?"0"+t.getMilliseconds():t.getMilliseconds(),n+a+o+" "+i+r+s+c}function c(e,t){for(var n=e.split("."),a=t.split("."),o=0;or)return 1;if(i=6","首页":"Home","密码修改":"Alter Password","退出":"Logout","刷新容器列表":"Refresh container list","刷新容器状态":"Refresh container status","刷新成功":"Refresh Success","主机":"Server","主机管理":"Host Manager","容器":"Container","运行中":"Running","已停止":"Stop","任务":"Task","镜像":"Image","应用":"App","实时日志开启数量":"Num of open log tail","目标主机":"Dest Server","正在进行":"Doing","完成":"Finish","失败":"Fail","仪表盘":"Dashboard","用户管理":"User Manager","用户列表":"User List","应用管理":"App Manager","发布管理":"Publish Manager","应用列表":"App List","应用组":"App Group","任务列表":"Task List","发布容器":"Publish Container","客户端配置":"Agent Config","容器管理":"Container Manager","最新状态":"Last Status","实时日志":"Live Log","状态":"Status","操作":"Operation","禁用":"Disable","恢复":"Enable","密码重置":"Reset Password","正常":"Normal","密码仅显示一次,请备份:":"Password only show once, please back up:","密码重置成功":"Password reset success","确定":"OK","取消":"Cancel","旧密码":"Old password","请输入旧密码":"Please input old password","新密码":"New password","输入新密码":"Please input new password","修改密码":"Alter password","删除":"Delete","更新":"Update","命令":"Command","信息":"Info","发布时间":"Publish Time","成功":"Success","停止":"Stop","重启":"Restart","详情":"Detail","命令下发成功":"Send command success","容器名称":"Container Name","是":"Yes","否":"No","是否开启日志":"Is open tail log","未开启":"Not open","已开启":"Open","开启日志":"Open log","关闭日志":"Close log","命令已下发":"Command issued","配置管理":"Config Manager","目标容器":"Dest Container","显示日志系统时间":"Show log system time","连接日志":"Connect log","断开连接":"Disconnect log","必须选择容器":"Must select a container","正在连接...":"Connecting ...","连接成功.":"Connected.","连接发生错误.":"Connect error.","连接已关闭.":"Disconnect.","字段名称":"Key","值":"Value","备注":"Memo","临时记录区域":"Temporary recording area","添加":"Add","内存(M)":"Memory(M)","端口映射":"Port Mapping","卷映射":"Volume Mapping","Bind模式相当于docker -v参数。如何挂载卷?":"The bind mode is equivalent to the \'docker -v\'. How do I mount a volume?","源地址(宿主机地址)":"Src path (Host server path)","绑定方式":"Bind type","容器内地址":"Path in container","读写":"Read and write","只读":"Read only","环境变量":"Environment val","变量key":"Key","变量值":"Value","日志驱动":"Log driver","请选择":"Please select","如何选择日志驱动?":"How to select a log driver?","日志配置参数":"Config log param","发布":"Publish","添加用户":"Add user","昵称":"Nickname","邮箱":"Email","手机":"Mobile","角色":"Role","超级管理员":"Super Admin","客户端代理":"Docker Agent","请输入邮箱地址":"Please input email","请输入正确的邮箱地址":"Please input correct email","请输入昵称":"Please input nickname","请输入正确的昵称":"Please input correct nickname","请输入用户名":"Please input username","请输入手机号码":"Please input mobile number","请输入正确的手机号码":"Please input correct mobile number","请输入密码":"Please input password","请输入正确密码":"Please input correct password","当前版本":"Current version","功能开发中...":"Function development","镜像管理":"Image Manage","镜像名称":"Image Name","输入关键字过滤":"Please input keyword to filter","在线":"Online","总计":"Total","运行容器":"ContainerRunning","过滤关键字":"filter key word","忘记密码":"Forget password","管理员找回密码":"Forget admin password","非管理员找回密码":"Non administrator retrieve password","用户名或邮箱":"Username or email","重置密码":"Reset password","请输入用户名或邮箱":"Please input username or email","控制台验证码":"Console verification code","邮箱验证码":"Mail verification code","获取验证码":"Get verification code","请输入验证码":"Please input verification code","验证码将会打印到docker-manager的控制台日志":"The verification code will be printed to the docker-manager\'s console log","请输入":"Please input ","提示":"Tip","格式不正确":"Incorrect format","白名单IP":"IP White list","请联系管理员,重置密码":"Please contact the administrator to reset the password"}')},f782:function(e,t,n){"use strict";n.r(t);var a=n("e017"),o=n.n(a),i=n("21a1"),r=n.n(i),s=new o.a({id:"icon-dashboard",use:"icon-dashboard-usage",viewBox:"0 0 128 100",content:''});r.a.add(s);t["default"]=s}},[[0,"runtime","chunk-elementUI","chunk-libs"]]]); \ No newline at end of file diff --git a/views/static/js/chunk-06ff5938.1f67e0a8.js b/views/static/js/chunk-06ff5938.1f67e0a8.js deleted file mode 100644 index 9571c7b..0000000 --- a/views/static/js/chunk-06ff5938.1f67e0a8.js +++ /dev/null @@ -1 +0,0 @@ -(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-06ff5938"],{da71:function(t,e,n){"use strict";n.d(e,"c",(function(){return a})),n.d(e,"e",(function(){return l})),n.d(e,"d",(function(){return o})),n.d(e,"b",(function(){return r})),n.d(e,"a",(function(){return c}));var i=n("b775");function a(){return Object(i["a"])({url:"/mgr/config",method:"get"})}function l(t){return Object(i["a"])({url:"/mgr/config/update",method:"post",data:t})}function o(){return Object(i["a"])({url:"/mgr/config/whiteList",method:"get"})}function r(t){return Object(i["a"])({url:"/mgr/config/deleteWhiteIp",method:"post",data:t})}function c(t){return Object(i["a"])({url:"/mgr/config/addWhiteIp",method:"post",data:t})}},eb43:function(t,e,n){"use strict";n.r(e);var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"app-container"},[n("div",{staticStyle:{"margin-bottom":"15px"}}),n("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],attrs:{data:t.list,"element-loading-text":"Loading",border:"",fit:"","highlight-current-row":""}},[n("el-table-column",{attrs:{align:"center",label:"ID",width:"95"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.$index+1)+" ")]}}])}),n("el-table-column",{attrs:{label:t.$t("字段名称"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){return[n("el-button",{attrs:{type:"text"}},[t._v(t._s(e.row.Name))])]}}])}),n("el-table-column",{attrs:{"min-width":"270px",label:t.$t("值")},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[i.edit?[n("el-input",{staticClass:"edit-input",attrs:{size:"small"},model:{value:i.Value,callback:function(e){t.$set(i,"Value",e)},expression:"row.Value"}})]:n("span",[t._v(t._s(i.Value))])]}}])}),n("el-table-column",{attrs:{label:t.$t("备注"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[i.edit?[n("el-input",{staticClass:"edit-input",attrs:{size:"small"},model:{value:i.Memo,callback:function(e){t.$set(i,"Memo",e)},expression:"row.Memo"}})]:n("span",[t._v(t._s(i.Memo))])]}}])}),n("el-table-column",{attrs:{align:"center",label:t.$t("操作"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[i.edit?t._e():n("el-button",{attrs:{type:"primary",size:"small",icon:"el-icon-edit"},on:{click:function(t){i.edit=!i.edit}}},[t._v("Edit")]),i.edit?n("el-button",{attrs:{type:"success",size:"small",icon:"el-icon-circle-check-outline"},on:{click:function(e){return t.confirmEdit(i)}}},[t._v("OK")]):t._e(),i.edit?n("el-button",{attrs:{type:"warning",size:"small",icon:"el-icon-refresh"},on:{click:function(e){return t.cancelEdit(i)}}},[t._v("Cancel")]):t._e()]}}])})],1)],1)},a=[],l=(n("d81d"),n("da71")),o={data:function(){return{listLoading:!1,list:[]}},created:function(){this.fetchData()},methods:{fetchData:function(){var t=this;this.listLoading=!0,Object(l["c"])().then((function(e){t.list=e.data.map((function(e){return t.$set(e,"edit",!1),e.originalValue=e.Value,e.originalMemo=e.Memo,e})),t.listLoading=!1}))},cancelEdit:function(t){t.Value=t.originalValue,t.Memo=t.originalMemo,t.edit=!1},confirmEdit:function(t){var e=this;t.edit=!1,t.originalValue=t.Value,t.originalMemo=t.Memo,this.listLoading=!0,Object(l["e"])(t).then((function(t){e.$message(e.$t("发布成功")),e.listLoading=!1,e.fetchData()}))}}},r=o,c=n("2877"),u=Object(c["a"])(r,i,a,!1,null,null,null);e["default"]=u.exports}}]); \ No newline at end of file diff --git a/views/static/js/chunk-06ff5938.8ee90bf3.js b/views/static/js/chunk-06ff5938.8ee90bf3.js new file mode 100644 index 0000000..eb42aa2 --- /dev/null +++ b/views/static/js/chunk-06ff5938.8ee90bf3.js @@ -0,0 +1 @@ +(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-06ff5938"],{da71:function(t,e,n){"use strict";n.d(e,"c",(function(){return a})),n.d(e,"f",(function(){return o})),n.d(e,"e",(function(){return l})),n.d(e,"b",(function(){return r})),n.d(e,"a",(function(){return u})),n.d(e,"d",(function(){return c}));var i=n("b775");function a(){return Object(i["a"])({url:"/mgr/config",method:"get"})}function o(t){return Object(i["a"])({url:"/mgr/config/update",method:"post",data:t})}function l(){return Object(i["a"])({url:"/mgr/config/whiteList",method:"get"})}function r(t){return Object(i["a"])({url:"/mgr/config/deleteWhiteIp",method:"post",data:t})}function u(t){return Object(i["a"])({url:"/mgr/config/addWhiteIp",method:"post",data:t})}function c(){return Object(i["a"])({url:"/base/forbidden/log",method:"get"})}},eb43:function(t,e,n){"use strict";n.r(e);var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"app-container"},[n("div",{staticStyle:{"margin-bottom":"15px"}}),n("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],attrs:{data:t.list,"element-loading-text":"Loading",border:"",fit:"","highlight-current-row":""}},[n("el-table-column",{attrs:{align:"center",label:"ID",width:"95"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.$index+1)+" ")]}}])}),n("el-table-column",{attrs:{label:t.$t("字段名称"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){return[n("el-button",{attrs:{type:"text"}},[t._v(t._s(e.row.Name))])]}}])}),n("el-table-column",{attrs:{"min-width":"270px",label:t.$t("值")},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[i.edit?[n("el-input",{staticClass:"edit-input",attrs:{size:"small"},model:{value:i.Value,callback:function(e){t.$set(i,"Value",e)},expression:"row.Value"}})]:n("span",[t._v(t._s(i.Value))])]}}])}),n("el-table-column",{attrs:{label:t.$t("备注"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[i.edit?[n("el-input",{staticClass:"edit-input",attrs:{size:"small"},model:{value:i.Memo,callback:function(e){t.$set(i,"Memo",e)},expression:"row.Memo"}})]:n("span",[t._v(t._s(i.Memo))])]}}])}),n("el-table-column",{attrs:{align:"center",label:t.$t("操作"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[i.edit?t._e():n("el-button",{attrs:{type:"primary",size:"small",icon:"el-icon-edit"},on:{click:function(t){i.edit=!i.edit}}},[t._v("Edit")]),i.edit?n("el-button",{attrs:{type:"success",size:"small",icon:"el-icon-circle-check-outline"},on:{click:function(e){return t.confirmEdit(i)}}},[t._v("OK")]):t._e(),i.edit?n("el-button",{attrs:{type:"warning",size:"small",icon:"el-icon-refresh"},on:{click:function(e){return t.cancelEdit(i)}}},[t._v("Cancel")]):t._e()]}}])})],1)],1)},a=[],o=(n("d81d"),n("da71")),l={data:function(){return{listLoading:!1,list:[]}},created:function(){this.fetchData()},methods:{fetchData:function(){var t=this;this.listLoading=!0,Object(o["c"])().then((function(e){t.list=e.data.map((function(e){return t.$set(e,"edit",!1),e.originalValue=e.Value,e.originalMemo=e.Memo,e})),t.listLoading=!1}))},cancelEdit:function(t){t.Value=t.originalValue,t.Memo=t.originalMemo,t.edit=!1},confirmEdit:function(t){var e=this;t.edit=!1,t.originalValue=t.Value,t.originalMemo=t.Memo,this.listLoading=!0,Object(o["f"])(t).then((function(t){e.$message(e.$t("发布成功")),e.listLoading=!1,e.fetchData()}))}}},r=l,u=n("2877"),c=Object(u["a"])(r,i,a,!1,null,null,null);e["default"]=c.exports}}]); \ No newline at end of file diff --git a/views/static/js/chunk-51b20511.499045fc.js b/views/static/js/chunk-51b20511.499045fc.js new file mode 100644 index 0000000..a4140b9 --- /dev/null +++ b/views/static/js/chunk-51b20511.499045fc.js @@ -0,0 +1 @@ +(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-51b20511"],{"01d2":function(t,n,e){"use strict";e.r(n);var r=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("div",{staticClass:"app-container"},[e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],attrs:{data:t.list,"element-loading-text":"Loading",border:"",fit:"","highlight-current-row":""}},[e("el-table-column",{attrs:{align:"center",label:"ID",width:"95"},scopedSlots:t._u([{key:"default",fn:function(n){return[t._v(" "+t._s(n.$index+1)+" ")]}}])}),e("el-table-column",{attrs:{label:"IP",align:"center"},scopedSlots:t._u([{key:"default",fn:function(n){return[t._v(" "+t._s(n.row.Ip)+" ")]}}])}),e("el-table-column",{attrs:{label:"NUM",align:"center"},scopedSlots:t._u([{key:"default",fn:function(n){return[t._v(" "+t._s(n.row.Num)+" ")]}}])})],1)],1)},a=[],i=e("da71"),o={data:function(){return{listLoading:!1,list:[]}},created:function(){this.fetchData()},methods:{fetchData:function(){var t=this;this.listLoading=!0,Object(i["d"])().then((function(n){t.list=n.data,t.listLoading=!1}))}}},u=o,c=e("2877"),l=Object(c["a"])(u,r,a,!1,null,null,null);n["default"]=l.exports},da71:function(t,n,e){"use strict";e.d(n,"c",(function(){return a})),e.d(n,"f",(function(){return i})),e.d(n,"e",(function(){return o})),e.d(n,"b",(function(){return u})),e.d(n,"a",(function(){return c})),e.d(n,"d",(function(){return l}));var r=e("b775");function a(){return Object(r["a"])({url:"/mgr/config",method:"get"})}function i(t){return Object(r["a"])({url:"/mgr/config/update",method:"post",data:t})}function o(){return Object(r["a"])({url:"/mgr/config/whiteList",method:"get"})}function u(t){return Object(r["a"])({url:"/mgr/config/deleteWhiteIp",method:"post",data:t})}function c(t){return Object(r["a"])({url:"/mgr/config/addWhiteIp",method:"post",data:t})}function l(){return Object(r["a"])({url:"/base/forbidden/log",method:"get"})}}}]); \ No newline at end of file diff --git a/views/static/js/chunk-63945102.40fcf23d.js b/views/static/js/chunk-63945102.3d3ba49e.js similarity index 69% rename from views/static/js/chunk-63945102.40fcf23d.js rename to views/static/js/chunk-63945102.3d3ba49e.js index 14d2668..03b6799 100644 --- a/views/static/js/chunk-63945102.40fcf23d.js +++ b/views/static/js/chunk-63945102.3d3ba49e.js @@ -1 +1 @@ -(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-63945102"],{"45ee":function(t,e,n){"use strict";n.r(e);var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"app-container"},[n("div",{staticStyle:{"padding-bottom":"10px"}},[n("el-button",{attrs:{type:"primary"},on:{click:t.addWhiteIp}},[t._v(t._s(t.$t("添加"))+" IP")])],1),n("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],attrs:{data:t.list,"element-loading-text":"Loading",border:"",fit:"","highlight-current-row":""}},[n("el-table-column",{attrs:{align:"center",label:"ID",width:"95"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.$index+1)+" ")]}}])}),n("el-table-column",{attrs:{label:"IP",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.IP)+" ")]}}])}),n("el-table-column",{attrs:{align:"center",label:t.$t("操作"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[n("el-button",{attrs:{type:"danger",size:"small",icon:"el-icon-delete"},on:{click:function(e){return t.deleteWhiteIp(i)}}},[t._v(t._s(t.$t("删除")))])]}}])})],1)],1)},a=[],r=n("da71"),o={data:function(){return{listLoading:!1,list:[]}},created:function(){this.fetchData()},methods:{fetchData:function(){var t=this;this.listLoading=!0,Object(r["d"])().then((function(e){t.list=e.data,t.listLoading=!1}))},addWhiteIp:function(){var t=this;this.$prompt(this.$t("请输入")+"IP",this.$t("提示"),{confirmButtonText:this.$t("确定"),cancelButtonText:this.$t("取消"),inputPattern:/^((25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))\.){3}(25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d))|\*)((\/([012]\d|3[012]|\d))?)(,((25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))\.){3}(25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d))|\*)((\/([012]\d|3[012]|\d))?))*$/,inputErrorMessage:"IP"+this.$t("格式不正确")}).then((function(e){var n=e.value;Object(r["a"])({IP:n}).then((function(e){t.$message(t.$t("添加成功"))}))}))},deleteWhiteIp:function(t){var e=this;this.listLoading=!0,Object(r["b"])(t).then((function(t){e.$message(e.$t("删除成功")),e.listLoading=!1,e.fetchData()}))}}},d=o,c=n("2877"),u=Object(c["a"])(d,i,a,!1,null,null,null);e["default"]=u.exports},da71:function(t,e,n){"use strict";n.d(e,"c",(function(){return a})),n.d(e,"e",(function(){return r})),n.d(e,"d",(function(){return o})),n.d(e,"b",(function(){return d})),n.d(e,"a",(function(){return c}));var i=n("b775");function a(){return Object(i["a"])({url:"/mgr/config",method:"get"})}function r(t){return Object(i["a"])({url:"/mgr/config/update",method:"post",data:t})}function o(){return Object(i["a"])({url:"/mgr/config/whiteList",method:"get"})}function d(t){return Object(i["a"])({url:"/mgr/config/deleteWhiteIp",method:"post",data:t})}function c(t){return Object(i["a"])({url:"/mgr/config/addWhiteIp",method:"post",data:t})}}}]); \ No newline at end of file +(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-63945102"],{"45ee":function(t,e,n){"use strict";n.r(e);var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"app-container"},[n("div",{staticStyle:{"padding-bottom":"10px"}},[n("el-button",{attrs:{type:"primary"},on:{click:t.addWhiteIp}},[t._v(t._s(t.$t("添加"))+" IP")])],1),n("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],attrs:{data:t.list,"element-loading-text":"Loading",border:"",fit:"","highlight-current-row":""}},[n("el-table-column",{attrs:{align:"center",label:"ID",width:"95"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.$index+1)+" ")]}}])}),n("el-table-column",{attrs:{label:"IP",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.IP)+" ")]}}])}),n("el-table-column",{attrs:{align:"center",label:t.$t("操作"),width:"270"},scopedSlots:t._u([{key:"default",fn:function(e){var i=e.row;return[n("el-button",{attrs:{type:"danger",size:"small",icon:"el-icon-delete"},on:{click:function(e){return t.deleteWhiteIp(i)}}},[t._v(t._s(t.$t("删除")))])]}}])})],1)],1)},a=[],r=n("da71"),o={data:function(){return{listLoading:!1,list:[]}},created:function(){this.fetchData()},methods:{fetchData:function(){var t=this;this.listLoading=!0,Object(r["e"])().then((function(e){t.list=e.data,t.listLoading=!1}))},addWhiteIp:function(){var t=this;this.$prompt(this.$t("请输入")+"IP",this.$t("提示"),{confirmButtonText:this.$t("确定"),cancelButtonText:this.$t("取消"),inputPattern:/^((25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))\.){3}(25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d))|\*)((\/([012]\d|3[012]|\d))?)(,((25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d)))\.){3}(25[0-5]|2[0-4]\d|((1\d{2})|([1-9]?\d))|\*)((\/([012]\d|3[012]|\d))?))*$/,inputErrorMessage:"IP"+this.$t("格式不正确")}).then((function(e){var n=e.value;Object(r["a"])({IP:n}).then((function(e){t.$message(t.$t("添加成功"))}))}))},deleteWhiteIp:function(t){var e=this;this.listLoading=!0,Object(r["b"])(t).then((function(t){e.$message(e.$t("删除成功")),e.listLoading=!1,e.fetchData()}))}}},d=o,u=n("2877"),c=Object(u["a"])(d,i,a,!1,null,null,null);e["default"]=c.exports},da71:function(t,e,n){"use strict";n.d(e,"c",(function(){return a})),n.d(e,"f",(function(){return r})),n.d(e,"e",(function(){return o})),n.d(e,"b",(function(){return d})),n.d(e,"a",(function(){return u})),n.d(e,"d",(function(){return c}));var i=n("b775");function a(){return Object(i["a"])({url:"/mgr/config",method:"get"})}function r(t){return Object(i["a"])({url:"/mgr/config/update",method:"post",data:t})}function o(){return Object(i["a"])({url:"/mgr/config/whiteList",method:"get"})}function d(t){return Object(i["a"])({url:"/mgr/config/deleteWhiteIp",method:"post",data:t})}function u(t){return Object(i["a"])({url:"/mgr/config/addWhiteIp",method:"post",data:t})}function c(){return Object(i["a"])({url:"/base/forbidden/log",method:"get"})}}}]); \ No newline at end of file diff --git a/web/handler/base/DBTraceHandler.go b/web/handler/base/DBTraceHandler.go index 52a9fd5..2b14588 100644 --- a/web/handler/base/DBTraceHandler.go +++ b/web/handler/base/DBTraceHandler.go @@ -25,5 +25,5 @@ func DBTraceHandler(c *gin.Context) interface{} { } func ForbiddenLogHandler(c *gin.Context) interface{} { - return service.ForbiddenLogMap() + return service.ForbiddenLogRecord() }