All Downloads are FREE. Search and download functionalities are using the official Maven repository.

netty-server-ui.v1.js.637.47868b42.js Maven / Gradle / Ivy

The newest version!
"use strict";(self.webpackChunkwu_smart_agent_network=self.webpackChunkwu_smart_agent_network||[]).push([[637],{94637:(e,l,t)=>{t.r(l),t.d(l,{default:()=>d});var r=t(83986),n=t(35145),a=t(93540),u=(t(50886),t(66252)),o=t(2262),i=t(3577),c={style:{float:"left"}};const d={__name:"NetWorkMappingEdit",props:{showDialog:{type:Boolean,default:!0},title:{type:String,default:"添加"},rowData:{type:Object,default:null}},emits:["closeDialog"],setup:function(e,l){var t=l.emit,d={clientId:[{required:!0,message:"请输入选择客户端",trigger:"blur"}],clientTargetIp:[{required:!0,message:"请输入客户端目标IP",trigger:"blur"}],clientTargetPort:[{required:!0,message:"请输入客户端目标端口",trigger:"blur"}],visitorPort:[{required:!0,message:"请选择访客端口",trigger:"blur"}]},p=e,s=t,f=(0,o.BK)(p),v=f.title,m=f.rowData,w=function(){s("closeDialog",!1)},b=(0,o.iH)(null),g=(0,o.iH)(null),k=(0,o.iH)(null),_=(0,o.qj)({clientId:"",clientTargetIp:"0.0.0.0",clientTargetPort:"",visitorPort:"",describe:""}),h=(0,o.BK)(_),I=h.clientId,V=h.clientTargetIp,P=h.clientTargetPort,x=h.visitorPort,U=h.describe;m.value&&(I.value=m.value.clientId,V.value=m.value.clientTargetIp,P.value=m.value.clientTargetPort,x.value=m.value.visitorPort,U.value=m.value.describe);(0,u.bv)((0,a.Z)((0,r.Z)().mark((function e(){return(0,r.Z)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:VE_API.cloudNetwork.cloudClientFindList().then((function(e){e.data.map((function(e){e.label=e.clientId,e.value=e.clientId})),g.value=e.data?e.data:[]})),W();case 2:case"end":return e.stop()}}),e)}))));var W=function(){var e=(0,a.Z)((0,r.Z)().mark((function e(){var l;return(0,r.Z)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,VE_API.cloudNetwork.visitorList();case 2:l=e.sent,0===l.code&&(l.data.map((function(e){e.label=e.describe,e.value=e.visitorPort})),k.value=l.data?l.data:[]);case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return function(l,t){var p=(0,u.up)("el-option"),s=(0,u.up)("el-select"),f=(0,u.up)("el-form-item"),h=(0,u.up)("el-input"),W=(0,u.up)("el-form"),y=(0,u.up)("el-button"),T=(0,u.up)("el-dialog");return(0,u.wg)(),(0,u.j4)(T,{title:(0,o.SU)(v),"append-to-body":"","destroy-on-close":"","model-value":e.showDialog,onClose:t[7]||(t[7]=function(e){return w()})},{footer:(0,u.w5)((function(){return[(0,u._)("span",null,[(0,u.Wm)(y,{onClick:t[5]||(t[5]=function(e){return w()})},{default:(0,u.w5)((function(){return[(0,u.Uk)("取消")]})),_:1}),(0,u.Wm)(y,{type:"primary",onClick:t[6]||(t[6]=function(e){b.value.validate(function(){var e=(0,a.Z)((0,r.Z)().mark((function e(l){var t;return(0,r.Z)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!l){e.next=14;break}if("添加"!==v.value){e.next=7;break}return e.next=4,VE_API.cloudNetwork.networkMappingSave(_);case 4:t=e.sent,e.next=10;break;case 7:return e.next=9,VE_API.cloudNetwork.networkMappingUpdate((0,n.Z)({clientTargetPort:m.value.clientTargetPort},_));case 9:t=e.sent;case 10:0===t.code&&w(),e.next=16;break;case 14:return console.log("error submit!!"),e.abrupt("return",!1);case 16:case"end":return e.stop()}}),e)})));return function(l){return e.apply(this,arguments)}}())})},{default:(0,u.w5)((function(){return[(0,u.Uk)("确定")]})),_:1})])]})),default:(0,u.w5)((function(){return[(0,u.Wm)(W,{model:_,ref_key:"formRef",ref:b,rules:d,"label-width":"80px",inline:!1},{default:(0,u.w5)((function(){return[(0,u.Wm)(f,{label:"客户端ID","label-width":"140px",prop:"clientId"},{default:(0,u.w5)((function(){return[(0,u.Wm)(s,{modelValue:(0,o.SU)(I),"onUpdate:modelValue":t[0]||(t[0]=function(e){return(0,o.dq)(I)?I.value=e:null}),placeholder:"客户端ID",clearable:""},{default:(0,u.w5)((function(){return[((0,u.wg)(!0),(0,u.iD)(u.HY,null,(0,u.Ko)(g.value,(function(e){return(0,u.wg)(),(0,u.j4)(p,{key:e.value,label:e.label,value:e.value,serverId:e},null,8,["label","value","serverId"])})),128))]})),_:1},8,["modelValue"])]})),_:1}),(0,u.Wm)(f,{label:"访问端口","label-width":"140px",prop:"visitorPort"},{default:(0,u.w5)((function(){return[(0,u.Wm)(s,{modelValue:(0,o.SU)(x),"onUpdate:modelValue":t[1]||(t[1]=function(e){return(0,o.dq)(x)?x.value=e:null}),placeholder:"访问端口",clearable:""},{default:(0,u.w5)((function(){return[((0,u.wg)(!0),(0,u.iD)(u.HY,null,(0,u.Ko)(k.value,(function(e){return(0,u.wg)(),(0,u.j4)(p,{key:e.value,label:e.label,value:e.value},{default:(0,u.w5)((function(){return[(0,u._)("span",c," 端口:【"+(0,i.zw)(e.value)+"】"+(0,i.zw)(e.label),1)]})),_:2},1032,["label","value"])})),128))]})),_:1},8,["modelValue"])]})),_:1}),(0,u.Wm)(f,{label:"客户端目标地址","label-width":"140px",prop:"clientTargetIp"},{default:(0,u.w5)((function(){return[(0,u.Wm)(h,{modelValue:(0,o.SU)(V),"onUpdate:modelValue":t[2]||(t[2]=function(e){return(0,o.dq)(V)?V.value=e:null}),placeholder:"",clearable:""},null,8,["modelValue"])]})),_:1}),(0,u.Wm)(f,{label:"客户端目标端口","label-width":"140px",prop:"clientTargetPort"},{default:(0,u.w5)((function(){return[(0,u.Wm)(h,{modelValue:(0,o.SU)(P),"onUpdate:modelValue":t[3]||(t[3]=function(e){return(0,o.dq)(P)?P.value=e:null}),placeholder:"",clearable:""},null,8,["modelValue"])]})),_:1}),(0,u.Wm)(f,{label:"描述","label-width":"140px",prop:"describe"},{default:(0,u.w5)((function(){return[(0,u.Wm)(h,{modelValue:(0,o.SU)(U),"onUpdate:modelValue":t[4]||(t[4]=function(e){return(0,o.dq)(U)?U.value=e:null}),placeholder:"",clearable:""},null,8,["modelValue"])]})),_:1})]})),_:1},8,["model"])]})),_:1},8,["title","model-value"])}}}}}]);




© 2015 - 2024 Weber Informatics LLC | Privacy Policy