| 1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-b2235c84"],{7358:function(t,e,s){},ab82:function(t,e,s){"use strict";s.r(e);var a=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"app-container"},[s("el-row",[s("el-col",{staticClass:"card-box",attrs:{span:14}},[s("el-card",[s("div",{attrs:{slot:"header"},slot:"header"},[s("span",{staticStyle:{"font-size":"20px","font-weight":"bold"}},[s("i",{staticClass:"el-icon-monitor"}),t._v(" "+t._s(t.$t("fourgwlsz")))])]),s("div",{staticClass:"el-table el-table--enable-row-hover el-table--medium"},[[s("el-form",{ref:"form3",attrs:{model:t.form3,rules:t.rules1,"label-width":"auto"}},[s("el-form-item",{attrs:{label:this.$t("fourgwl"),prop:"czmode"}},[s("el-select",{staticStyle:{width:"100%"},attrs:{"allow-create":"",disabled:t.readOnlyQx,filterable:!1},model:{value:t.form3.czmode,callback:function(e){t.$set(t.form3,"czmode",e)},expression:"form3.czmode"}},t._l(t.czmodes,(function(e){return s("el-option",{key:e.id,attrs:{label:t.$t(e.name),value:e.id}})})),1)],1),s("el-form-item",{attrs:{label:this.$t("ljzt")}},[s("el-input",{attrs:{readonly:!0,disabled:t.readOnlyQx}},[s("template",{slot:"prefix"},[t.form3.ljzt==this.$t("wlj")?s("span",{staticStyle:{color:"red"}},[t._v(t._s(t.form3.ljzt))]):s("span",{staticStyle:{color:"green"}},[t._v(t._s(t.form3.ljzt))])])],2)],1),s("el-form-item",{attrs:{label:this.$t("xhqd"),prop:"xhqd"}},[s("el-input",{attrs:{readonly:!0,disabled:t.readOnlyQx},model:{value:t.form3.xhqd,callback:function(e){t.$set(t.form3,"xhqd",e)},expression:"form3.xhqd"}})],1),s("el-form-item",{attrs:{label:this.$t("yys"),prop:"yys"}},[s("el-input",{attrs:{readonly:!0,disabled:t.readOnlyQx},model:{value:t.form3.yys,callback:function(e){t.$set(t.form3,"yys",e)},expression:"form3.yys"}})],1),s("el-form-item",{attrs:{label:this.$t("tel"),prop:"tel"}},[s("el-input",{attrs:{readonly:!0,disabled:t.readOnlyQx},model:{value:t.form3.tel,callback:function(e){t.$set(t.form3,"tel",e)},expression:"form3.tel"}})],1),s("el-form-item",{attrs:{label:"IPv4"+this.$t("dz"),prop:"ipFourAddress"}},[s("el-input",{attrs:{readonly:!0,disabled:t.readOnlyQx},model:{value:t.form3.ipFourAddress,callback:function(e){t.$set(t.form3,"ipFourAddress",e)},expression:"form3.ipFourAddress"}})],1),s("el-form-item",{attrs:{label:"IPv6 "+this.$t("dz"),prop:"ipSixAddress"}},[s("el-input",{attrs:{readonly:!0,disabled:t.readOnlyQx},model:{value:t.form3.ipSixAddress,callback:function(e){t.$set(t.form3,"ipSixAddress",e)},expression:"form3.ipSixAddress"}})],1),s("el-form-item",{attrs:{label:this.$t("dxts"),prop:"dateRange"}},[s("el-table",{staticStyle:{width:"100%"},attrs:{data:t.form3.dateRange,border:"",size:"mini","max-height":"272"}},[s("el-table-column",{attrs:{prop:"",disabled:t.readOnlyQx,label:"","min-width":t.getStringWidth(t.$t("tel")),align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(t._s(t.$t("tel"))+t._s(e.$index+1))]}}])}),s("el-table-column",{attrs:{prop:"receiveAccount","min-width":t.getStringWidth(t.$t("tel")),label:t.$t("tel"),align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){var a=e.row;return[s("el-form-item",{staticClass:"form-item",attrs:{prop:"dateRange."+a.idx+".receiveAccount"}},[s("el-input",{staticStyle:{width:"100%"},attrs:{"controls-position":"right",disabled:t.readOnlyQx},model:{value:a.receiveAccount,callback:function(e){t.$set(a,"receiveAccount",e)},expression:"row.receiveAccount"}})],1)]}}])}),s("el-table-column",{attrs:{prop:"",label:this.$t("cz"),align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[t.form3.dateRange.length<10&&0==e.$index&&t.$store.state.user.urseRoles.includes("1")?s("el-button",{attrs:{size:"mini"},on:{click:function(e){return e.stopPropagation(),t.addTimeRange(e)}}},[s("i",{staticClass:"el-icon-plus"})]):t.$store.state.user.urseRoles.includes("1")?s("el-button",{attrs:{size:"mini"},on:{click:function(s){return s.stopPropagation(),t.deleteRange(e.$index)}}},[s("i",{staticClass:"el-icon-delete"})]):t._e()]}}])})],1)],1)],1),this.$store.state.user.urseRoles.includes("1")?s("div",{staticClass:"dialog-footer",staticStyle:{float:"right"},attrs:{slot:"footer"},slot:"footer"},[s("el-button",{attrs:{type:"primary"},on:{click:t.submitForm3}},[t._v(t._s(t.$t("sz")))])],1):t._e()]],2)])],1)],1)],1)},o=[],r=(s("caad"),s("14d9"),s("a434"),s("d3b7"),s("2532"),s("159b"),s("7ba4")),i={name:"Server",data:function(){return{isChecked:!1,server:[],totalStatus:{},channelList:[],title:"",readOnlyQx:!1,sensorStatusTitle:"",open:!1,usertoken:"",form:{},form2:{},form3:{dateRange:[{idx:0,receiveAccount:""}]},sensorStatusForm:{},czmodes:[{id:"0",name:"gb"},{id:"1",name:"qy"}],modes:[{id:"0",name:"zd"},{id:"1",name:"sd"}],types:[{id:"WIFIIPV4Save",name:"IPV4"},{id:"WIFIIPV6Save",name:"IPV6"}],activeName:"温湿度传感器",sensorStatusTabs:[],sensorStatusOpen:!1,sensorStatusList:[],showClass:!0,showClass2:!0,productParams:{},rules1:{czmode:[{required:!0,message:this.$i18n.t("fourgwl")+" "+this.$i18n.t("bnwk"),trigger:"blur"}]},rules2:{mode:[{required:!0,message:this.$i18n.t("xzms")+" "+this.$i18n.t("bnwk"),trigger:"blur"}],type:[{required:!0,message:this.$i18n.t("IPbb")+" "+this.$i18n.t("bnwk"),trigger:"blur"}]},rules3:{mode:[{required:!0,message:this.$i18n.t("xzms")+" "+this.$i18n.t("bnwk"),trigger:"blur"}]},passwordVisible:!1}},mounted:function(){this.$bus.$on("FOURG_STATUS",this.onSocketMessageTofourgStatus)},created:function(){this.$store.state.user.urseRoles.includes("1")||(this.readOnlyQx=!0),this.usertoken=this.$store.state.user.usertoken,this.productParams=this.$store.state.user.productParams,this.queryIp3()},methods:{getStringWidth:function(t){var e="14px Arial",s=document.createElement("canvas"),a=s.getContext("2d");a.font=e;var o=a.measureText(t);return o.width+40},onSocketMessageTofourgStatus:function(t){t.success&&null!=t.data&&""!=t.data.data&&null!=t.data.data&&null!=t.data&&(this.form3.ljzt=t.data.data.ljzt,this.form3.xhqd=t.data.data.xhqd,this.form3.yys=t.data.data.yys,this.form3.ipFourAddress=t.data.data.ipFourAddress,this.form3.ipSixAddress=t.data.data.ipSixAddress,this.form3.tel=t.data.data.tel)},addTimeRange:function(){10==this.form3.dateRange.length?this.$modal.msgWarning(this.$t("slts")):this.form3.dateRange.push({idx:this.form3.dateRange.length,receiveAccount:""})},deleteRange:function(t){this.form3.dateRange.splice(t,1),this.form3.dateRange.forEach((function(t,e){t.idx=e}))},togglePasswordVisibility:function(){this.passwordVisible=!this.passwordVisible},handleClick:function(t,e){console.log(t,e)},handleSelectChange:function(t){"1"==t?this.showClass=!1:(this.showClass=!0,this.form.mode=t)},handleSelectChange2:function(t){"1"==t?this.showClass2=!1:(this.showClass2=!0,this.form2={},this.form2.mode=t)},queryIp:function(){var t=this;if("1"==this.productParams.ip4sz){var e={};e.token=this.usertoken,e.type="listWIFIIPV4Query",Object(r["d"])(e).then((function(e){null!=e.data&&("1"==e.data.mode&&(t.showClass=!1),t.form=e.data)}))}},queryIp2:function(){var t=this;if("1"==this.productParams.ip6sz){var e={};e.token=this.usertoken,e.type="listWIFIIPV6Query",Object(r["d"])(e).then((function(e){null!=e.data&&("1"==e.data.mode&&(t.showClass2=!1),t.form2=e.data)}))}},queryIp3:function(){var t=this,e={};e.token=this.usertoken,e.type="listfourgPZQuery",Object(r["d"])(e).then((function(e){null!=e.data&&(t.form3=e.data,null!=e.data.receiveAccountList?t.form3.dateRange=e.data.receiveAccountList:t.form3.dateRange=[{idx:0,receiveAccount:""}])}))},submitForm:function(){var t=this;this.$refs["form"].validate((function(e){if(e){var s={};s.token=t.usertoken,s.type="WIFIIPV4Save",s.mode=t.form.mode,s.ipaddress=t.form.ipaddress,s.mask=t.form.mask,s.gateway=t.form.gateway,s.dns1=t.form.dns1,s.dns2=t.form.dns2,s.mac=t.form.mac,t.$modal.confirm(t.$t("qdybcm")).then((function(){Object(r["d"])(s)})).then((function(){t.$modal.msgSuccess(t.$t("zxcg"))})).catch((function(){}))}}))},submitForm2:function(){var t=this;this.$refs["form2"].validate((function(e){if(e){var s={};s.token=t.usertoken,s.type="WIFIIPV6Save",s.mode=t.form2.mode,s.ipaddress=t.form2.ipaddress,s.mask=t.form2.mask,s.gateway=t.form2.gateway,s.dns1=t.form2.dns1,s.dns2=t.form2.dns2,t.$modal.confirm(t.$t("qdybcm")).then((function(){Object(r["d"])(s)})).then((function(){t.$modal.msgSuccess(t.$t("zxcg"))})).catch((function(){}))}}))},submitForm3:function(){var t=this;this.$refs["form3"].validate((function(e){if(e){var s={},a=t.form3.dateRange;s.receiveAccountList=a,s.token=t.usertoken,s.type="fourgPZSave",s.czmode=t.form3.czmode,s.ipFourAddress=t.form3.ipFourAddress,s.ipSixAddress=t.form3.ipSixAddress,1==s.receiveAccountList.length&&t.form3.dateRange.forEach((function(t,e){""==t.receiveAccount&&(s.receiveAccountList=null)})),t.$modal.confirm(t.$t("qdybcm")).then((function(){Object(r["d"])(s)})).then((function(){t.$modal.msgSuccess(t.$t("zxcg"))})).catch((function(){}))}}))},openLoading:function(){this.$modal.loading(this.$t("zzjzqsh"))}}},n=i,l=(s("cfbb"),s("f498"),s("2877")),d=Object(l["a"])(n,a,o,!1,null,"35c62c86",null);e["default"]=d.exports},c0c35:function(t,e,s){},cfbb:function(t,e,s){"use strict";s("c0c35")},f498:function(t,e,s){"use strict";s("7358")}}]);
|