(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d0d2c0c"],{"5a9c":function(t,e,i){"use strict";i.r(e);var a=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"new-app-container layout-vertical"},[i("YMTable",{ref:"table",attrs:{"table-key":1,index:!0,selection:!1,"table-options":t.tableOptions,"edit-form":t.editForm,"edit-config":t.editConfig,columns:t.columns,"rows-actions":t.rowsActions,"show-summary":!1,apis:t.apis,"is-page":!1,"custom-style":{height:"calc(100vh - 100px)"}}}),i("el-dialog",{attrs:{title:"设置维护时间",visible:t.dialogVisible,width:"400px"},on:{"update:visible":function(e){t.dialogVisible=e}}},[i("el-form",{staticStyle:{padding:"20px 0"},attrs:{"label-width":"100px"}},[i("el-form-item",{attrs:{label:"维护时间"}},[i("el-input",{attrs:{placeholder:"格式为：10:30-11:00",clearable:""},model:{value:t.timeVal,callback:function(e){t.timeVal=e},expression:"timeVal"}})],1)],1),i("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[i("el-button",{on:{click:function(e){t.dialogVisible=!1}}},[t._v("取 消")]),i("el-button",{attrs:{type:"primary"},on:{click:t.handleSaveTime}},[t._v("保 存")])],1)],1)],1)},l=[],n=(i("ac1f"),i("00b4"),i("7e1e")),o={data:function(){var t=this;return{loading:!1,visibleBasicDrawer:!1,renderContent:"",searchForm:[],dialogVisible:!1,timeVal:"",currentRow:null,columns:[{label:"模式",method:function(t){return 0===t.val||1===t.val?0===t.val?"PC28":"极速28":t.val}},{label:"备注",prop:"remark"}],rowsActions:[{key:"witch",label:"快速切换",vIF:function(t){return 0===t.val||1===t.val},method:function(e){Object(n["Z"])({val:1===e.val?0:1}).then((function(e){0===e.code&&(t.$message.success("设置成功"),t.onSubmit())})).catch((function(){t.$message.error("设置失败")}))}},{key:"setTime",label:"设置维护时间",vIF:function(t){return!(0===t.val||1===t.val)},method:function(e){t.currentRow=e,t.timeVal=e.val||"",t.dialogVisible=!0}}],apis:{list:{url:"config/pcConfig",dataParam:"data.data",resultParam:"data",init:!1}},tableOptions:{},editForm:[],editConfig:{addTip:"注：备注",editTip:"注：备注"}}},created:function(){},mounted:function(){this.onSubmit()},methods:{handleSubmit:function(t){console.log("提交数据:",t)},handleClickDrawer:function(t){},onValueChange:function(t){},onSubmit:function(t){this.$refs.table.getList(t)},handleSaveTime:function(){var t=this;if(this.timeVal){var e=/^([01]\d|2[0-3]):[0-5]\d-([01]\d|2[0-3]):[0-5]\d$/;if(!e.test(this.timeVal))return void this.$message.warning("时间格式错误，请输入如：10:30-11:00")}Object(n["Y"])({field:this.currentRow.field,val:this.timeVal,remark:this.currentRow.remark}).then((function(){t.$message.success("维护时间设置成功"),t.dialogVisible=!1,t.onSubmit()}))}}},s=o,r=i("2877"),c=Object(r["a"])(s,a,l,!1,null,null,null);e["default"]=c.exports}}]);