| 1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d0daf52"],{"6e8e":function(e,t,a){"use strict";a.r(t);var r=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"app-container"},[a("el-form",{directives:[{name:"show",rawName:"v-show",value:e.showSearch,expression:"showSearch"}],ref:"queryForm",attrs:{model:e.queryParams,size:"small",inline:!0}},[a("el-form-item",{attrs:{label:"磁盘名称",prop:"path"}},[a("el-input",{attrs:{placeholder:"请输入磁盘名称",clearable:""},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleQuery(t)}},model:{value:e.queryParams.path,callback:function(t){e.$set(e.queryParams,"path",t)},expression:"queryParams.path"}})],1),a("el-form-item",[a("el-button",{attrs:{type:"primary",icon:"el-icon-search",size:"mini"},on:{click:e.handleQuery}},[e._v("搜索")]),a("el-button",{attrs:{icon:"el-icon-refresh",size:"mini"},on:{click:e.resetQuery}},[e._v("重置")])],1)],1),a("el-row",{staticClass:"mb8",attrs:{gutter:10}},[a("right-toolbar",{attrs:{showSearch:e.showSearch},on:{"update:showSearch":function(t){e.showSearch=t},"update:show-search":function(t){e.showSearch=t},queryTable:e.getList}})],1),e.refreshTable?a("el-table",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],attrs:{data:e.alarmList,width:"120"}},[a("el-table-column",{attrs:{label:"序号",align:"center",type:"index"}}),a("el-table-column",{attrs:{label:"磁盘名称",align:"center",prop:"path"}}),a("el-table-column",{attrs:{label:"磁盘占用率",align:"center",prop:"usagePercentage"}}),a("el-table-column",{attrs:{label:"硬盘大小",align:"center",prop:"hardDiskSize"}}),a("el-table-column",{attrs:{label:"可用大小",align:"center",prop:"free"}})],1):e._e(),a("pagination",{directives:[{name:"show",rawName:"v-show",value:e.total>0,expression:"total>0"}],attrs:{total:e.total,page:e.queryParams.pageNum,limit:e.queryParams.pageSize},on:{"update:page":function(t){return e.$set(e.queryParams,"pageNum",t)},"update:limit":function(t){return e.$set(e.queryParams,"pageSize",t)},pagination:e.getList}}),a("el-dialog",{attrs:{title:e.title,visible:e.openView,width:"600px","append-to-body":""},on:{"update:visible":function(t){e.openView=t},close:e.cancel}},[a("el-descriptions",{attrs:{"label-style":{width:"120px"},"content-style":{width:"180px"},column:2,border:""}},[a("el-descriptions-item",{attrs:{label:"磁盘名称"}},[e._v(e._s(e.form.path))]),a("el-descriptions-item",{attrs:{label:"磁盘占用率"}},[e._v(e._s(e.form.usagePercentage))]),a("el-descriptions-item",{attrs:{label:"硬盘大小"}},[e._v(e._s(e.form.hardDiskSize))]),a("el-descriptions-item",{attrs:{label:"可用大小"}},[e._v(e._s(e.form.free))])],1)],1)],1)},i=[],s=a("5530"),n=(a("d81d"),a("e9c4"),a("b64b"),a("b775"));function l(e){return Object(n["a"])({url:"/sis/alarm",method:"put",data:e})}function o(e){return Object(n["a"])({url:"/sis/alarm/list",method:"get",params:e})}var c={name:"cameraEquipmentMGT",dicts:["sys_normal_disable","sys_yes_no"],data:function(){return{loading:!0,showSearch:!0,alarmList:[],total:0,title:"",open:!1,openView:!1,refreshTable:!0,queryParams:{pageNum:1,pageSize:10,path:void 0},form:{},rules:{}}},created:function(){this.getList()},methods:{getList:function(){var e=this;this.loading=!0,o(this.queryParams).then((function(t){e.alarmList=t.data.map((function(e){return Object(s["a"])(Object(s["a"])({},e),{},{free:Math.floor(100*e.free)/100+"GB",usagePercentage:Math.floor(e.use/(e.use+e.free)*100*100)/100+"%",hardDiskSize:Math.floor(e.use+e.free)+"GB"})})),e.loading=!1}))},cancel:function(){this.open=!1,this.reset()},reset:function(){this.form={},this.resetForm("form")},handleQuery:function(){this.getList()},resetQuery:function(){this.resetForm("queryForm"),this.handleQuery()},handleView:function(e){this.reset(),this.form=JSON.parse(JSON.stringify(e)),this.title="告警详情",this.openView=!0},handleSolve:function(e,t){var a=this;this.$modal.confirm('是否确认解决序号为"'+t+'"的数据项?').then((function(){return l({id:e.id,status:"1"})})).then((function(){a.getList(),a.$modal.msgSuccess("解决成功")})).catch((function(){a.$modal.msgError("解决失败")}))}}},u=c,h=a("2877"),m=Object(h["a"])(u,r,i,!1,null,null,null);t["default"]=m.exports}}]);
|