chunk-10d8999b.a56d81a4.js 5.4 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-10d8999b"],{"48fb":function(e,t,a){},"6d5e":function(e,t,a){"use strict";a("48fb")},ac5c:function(e,t,a){"use strict";a.r(t);var s=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"app-container"},[a("el-row",[a("el-col",{staticClass:"card-box",attrs:{span:12}},[a("el-card",[a("div",{attrs:{slot:"header"},slot:"header"},[a("span",{staticStyle:{"font-size":"20px","font-weight":"bold"}},[a("i",{staticClass:"el-icon-monitor"}),e._v(" "+e._s(e.$t("NTPsz")))])]),a("div",{staticClass:"el-table el-table--enable-row-hover el-table--medium"},[[a("el-form",{ref:"form",attrs:{model:e.form,rules:e.rules,"label-width":"auto"}},[a("el-form-item",{attrs:{label:"NTP:",prop:"mode"}},[a("el-select",{staticStyle:{width:"100%"},attrs:{"allow-create":"",clearable:"",filterable:!1},on:{change:e.handleSelectChange},model:{value:e.form.mode,callback:function(t){e.$set(e.form,"mode",t)},expression:"form.mode"}},e._l(e.modes,(function(t){return a("el-option",{key:t.id,attrs:{label:e.$t(t.name),value:t.id}})})),1)],1),a("el-form-item",{attrs:{label:"NTP "+this.$t("fwmc"),prop:"ntpName"}},[a("el-input",{attrs:{disabled:e.isReadOnly},model:{value:e.form.ntpName,callback:function(t){e.$set(e.form,"ntpName",t)},expression:"form.ntpName"}})],1),a("el-form-item",{attrs:{label:"NTP "+this.$t("fwdz"),prop:"port"}},[a("el-input",{attrs:{disabled:e.isReadOnly},model:{value:e.form.ntpadress,callback:function(t){e.$set(e.form,"ntpadress",t)},expression:"form.ntpadress"}})],1),a("el-form-item",{attrs:{label:"NTP "+this.$t("dk2"),prop:"port"}},[a("el-input",{attrs:{disabled:e.isReadOnly,type:"number"},model:{value:e.form.port,callback:function(t){e.$set(e.form,"port",t)},expression:"form.port"}})],1),a("el-form-item",{attrs:{label:this.$t("sq"),prop:"sq"}},[a("el-select",{staticStyle:{width:"100%"},attrs:{disabled:e.isReadOnly3,"allow-create":"",clearable:"",filterable:!1},model:{value:e.form.sq,callback:function(t){e.$set(e.form,"sq",t)},expression:"form.sq"}},e._l(e.sqs,(function(e){return a("el-option",{key:e.id,attrs:{label:e.name,value:e.id}})})),1)],1),a("el-form-item",{attrs:{label:this.$t("rqsj"),prop:"time"}},[a("el-date-picker",{attrs:{clearable:"",disabled:e.isReadOnly2,type:"datetime","value-format":"yyyy-MM-dd HH:mm:ss"},model:{value:e.form.time,callback:function(t){e.$set(e.form,"time",t)},expression:"form.time"}})],1)],1),a("div",{staticClass:"dialog-footer",staticStyle:{float:"right"},attrs:{slot:"footer"},slot:"footer"},[a("el-button",{attrs:{type:"primary"},on:{click:e.submitForm}},[e._v(e._s(e.$t("qd")))])],1)]],2)])],1)],1)],1)},i=[],n=a("7ba4"),l={name:"Server",data:function(){return{rules:{mode:[{required:!0,message:"NTP "+this.$i18n.t("bnwk"),trigger:"blur"}]},server:[],totalStatus:{},channelList:[],title:"",show:"false",sensorStatusTitle:"",open:!1,usertoken:"",form:{},sensorStatusForm:{},modes:[{id:"0",name:"gb"},{id:"1",name:"kq"}],sqs:[{id:"GMT/UTC-11",name:"GMT/UTC-11"},{id:"GMT/UTC-10",name:"GMT/UTC-10"},{id:"GMT/UTC-9",name:"GMT/UTC-9"},{id:"GMT/UTC-8",name:"GMT/UTC-8"},{id:"GMT/UTC-7",name:"GMT/UTC-7"},{id:"GMT/UTC-6",name:"GMT/UTC-6"},{id:"GMT/UTC-5",name:"GMT/UTC-5"},{id:"GMT/UTC-4",name:"GMT/UTC-4"},{id:"GMT/UTC-3",name:"GMT/UTC-3"},{id:"GMT/UTC-2",name:"GMT/UTC-2"},{id:"GMT/UTC-1",name:"GMT/UTC-1"},{id:"GMT/UTC+0",name:"GMT/UTC+0"},{id:"GMT/UTC+1",name:"GMT/UTC+1"},{id:"GMT/UTC+2",name:"GMT/UTC+2"},{id:"GMT/UTC+3",name:"GMT/UTC+3"},{id:"GMT/UTC+4",name:"GMT/UTC+4"},{id:"GMT/UTC+5",name:"GMT/UTC+5"},{id:"GMT/UTC+6",name:"GMT/UTC+6"},{id:"GMT/UTC+7",name:"GMT/UTC+7"},{id:"GMT/UTC+8",name:"GMT/UTC+8"},{id:"GMT/UTC+9",name:"GMT/UTC+9"},{id:"GMT/UTC+10",name:"GMT/UTC+10"},{id:"GMT/UTC+11",name:"GMT/UTC+11"},{id:"12",name:"GMT/UTC+12"}],weeks:[{id:"1",name:"el.datepicker.weeks.mon"},{id:"2",name:"el.datepicker.weeks.tue"},{id:"3",name:"el.datepicker.weeks.wed"},{id:"4",name:"el.datepicker.weeks.thu"},{id:"5",name:"el.datepicker.weeks.fri"},{id:"6",name:"el.datepicker.weeks.sat"},{id:"7",name:"el.datepicker.weeks.sun"}],xinqs:[{id:"Asia/Shanghai",name:"bjsj"},{id:"1",name:"elssj"}],activeName:"温湿度传感器",sensorStatusTabs:[],sensorStatusOpen:!1,sensorStatusList:[],isReadOnly:!0,isReadOnly2:!0,isReadOnly3:!0}},created:function(){this.usertoken=this.$store.state.user.usertoken,this.queryIp()},methods:{editDisabled:function(){return"0"===this.form.mode},handleClick:function(e,t){console.log(e,t)},handleSelectChange:function(e){this.form.mode=e,"0"==e?(this.isReadOnly=!0,this.isReadOnly2=!1,this.isReadOnly3=!1):(this.isReadOnly=!1,this.isReadOnly2=!0,this.isReadOnly3=!1)},queryIp:function(){var e=this,t={};t.token=this.usertoken,t.type="listNtpQuery",Object(n["k"])(t).then((function(t){null!=t.data&&(e.form=t.data,"0"==t.data.mode?(e.isReadOnly=!0,e.isReadOnly2=!1,e.isReadOnly3=!1):(e.isReadOnly=!1,e.isReadOnly2=!0,e.isReadOnly3=!1))}))},submitForm:function(){var e=this;this.$refs["form"].validate((function(t){if(t){var a={};a.token=e.usertoken,a.type="NtpSave",a.mode=e.form.mode,a.port=e.form.port,a.ntpName=e.form.ntpName,a.ntpadress=e.form.ntpadress,a.time=e.form.time,a.sq=e.form.sq,a.week=e.form.week,e.$modal.confirm(e.$t("qdybcm")).then((function(){Object(n["k"])(a)})).then((function(){e.$modal.msgSuccess(e.$t("zxcg"))})).catch((function(){}))}}))},openLoading:function(){this.$modal.loading(this.$t("zzjzqsh"))}}},o=l,r=(a("6d5e"),a("2877")),d=Object(r["a"])(o,s,i,!1,null,"670737b8",null);t["default"]=d.exports}}]);