1 line
6.5 KiB
JavaScript
1 line
6.5 KiB
JavaScript
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-1bce2bcf"],{"304c":function(t,e,n){"use strict";n.r(e);var a=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.connectLoading,expression:"connectLoading"}],staticStyle:{width:"100%"},attrs:{border:"","max-height":"700",data:t.filterList}},[n("el-table-column",{attrs:{label:"序号",align:"center",fixed:"",width:"50"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.$index+1)+"\n ")]}}])}),t._v(" "),n("el-table-column",{attrs:{label:"采样日期",width:"180",align:"center",prop:"year",sortable:""}}),t._v(" "),n("el-table-column",{attrs:{label:"采样时间",width:"180",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.start_minute)+"-"+t._s(e.row.end_minute)+"\n ")]}}])}),t._v(" "),n("el-table-column",{attrs:{label:"错误条数",width:"180",align:"center",prop:"count",sortable:""}}),t._v(" "),n("el-table-column",{attrs:{label:"错误处理",width:"180",align:"center",prop:"error_handling"}}),t._v(" "),n("el-table-column",{attrs:{label:"错误类型",width:"180",align:"center",prop:"report_type"}}),t._v(" "),n("el-table-column",{attrs:{label:"错误原因",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[n("div",[n("a",{staticStyle:{color:"#6bb8ff"},on:{click:function(n){return t.lookData(e.row)}}},[t._v(t._s(e.row.error_reason))])])]}}])})],1),t._v(" "),t.pageshow?n("el-pagination",{staticClass:"pagination-container",attrs:{"current-page":t.page,"page-sizes":[5,10,20,30,50,100,150,200,500,1e3],"page-size":t.limit,layout:"total, sizes, prev, pager, next, jumper",total:t.total},on:{"size-change":t.handleSizeChange,"current-change":t.handlePageChange}}):t._e(),t._v(" "),n("el-drawer",{ref:"drawer",attrs:{title:"抽样数据","before-close":t.drawerHandleClose,visible:t.drawerShow,direction:"rtl","close-on-press-escape":"","destroy-on-close":"",size:"50%"},on:{"update:visible":function(e){t.drawerShow=e}}},[t.drawerShow?n("json-editor",{attrs:{"font-size":"15",height:"800",styles:"width: 100%",read:!0,title:"抽样数据"},model:{value:t.descData,callback:function(e){t.descData=e},expression:"descData"}}):t._e()],1)],1)},r=[],i=n("2d63"),s=n("c80c"),o=(n("96cf"),n("3b8d")),c=(n("c5f6"),n("e817")),l=n("cc06"),u={name:"RealData2Es",components:{JsonEditor:function(){return Promise.all([n.e("chunk-16372f25"),n.e("chunk-1303a6c7")]).then(n.bind(null,"fa7e"))}},props:{input:{type:String,default:""},timeSecend:{type:Number,default:5},pause:{type:Boolean,default:!1}},data:function(){return{descData:"{}",drawerShow:!1,connectLoading:!1,time:null,total:0,limit:10,page:1,pageshow:!0,list:[],trueList:[]}},computed:{filterList:function(){var t=this.list.slice((this.page-1)*this.limit,this.page*this.limit);return this.refreshPage(),t}},watch:{pause:function(t,e){1==t&&this.cleanTimer()},input:function(t,e){var n=this.trueList;n=Object(l["a"])(n,t.trim()),this.total=n.length,this.list=n}},beforeDestroy:function(){clearInterval(this.time),this.time=null},mounted:function(){this.searchData(),this.pause?(clearInterval(this.time),this.time=null):this.startLoop()},methods:{cleanTimer:function(){clearInterval(this.time),this.time=null},lookData:function(){var t=Object(o["a"])(Object(s["a"])().mark((function t(e){var n,a;return Object(s["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:return n={start_time:"".concat(e["year"]," ").concat(e["start_minute"],":00"),end_time:"".concat(e["year"]," ").concat(e["end_minute"],":00"),appid:this.$store.state.baseData.EsConnectID,error_reason:e["error_reason"],error_handling:e["error_handling"],report_type:e["report_type"]},t.next=3,Object(c["e"])(n);case 3:if(a=t.sent,0==a.code){t.next=9;break}return this.$message({offset:60,type:"error",message:a.msg}),t.abrupt("return");case 9:this.descData=JSON.stringify(JSON.parse(a.data.data),null,"\t"),this.drawerShow=!0;case 11:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}(),handleSizeChange:function(t){this.limit=t,this.refreshPage()},handlePageChange:function(t){this.page=t,this.refreshPage()},refreshPage:function(){var t=this;this.pageshow=!1,this.total=this.list.length,this.$nextTick((function(){t.pageshow=!0}))},searchData:function(){var t=Object(o["a"])(Object(s["a"])().mark((function t(){var e,n,a,r,o,u;return Object(s["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:return this.connectLoading=!0,t.next=3,Object(c["f"])({appid:this.$store.state.baseData.EsConnectID});case 3:if(e=t.sent,this.connectLoading=!1,0==e.code){t.next=10;break}return this.$message({offset:60,type:"error",message:e.msg}),t.abrupt("return");case 10:n=[],a=0,r=Object(i["a"])(e.data.list);try{for(r.s();!(o=r.n()).done;)u=o.value,u["index"]=a,n.push(u),a++}catch(s){r.e(s)}finally{r.f()}n=Object(l["a"])(n,this.input.trim()),this.total=n.length,this.list=n,this.trueList=n;case 18:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}(),startLoop:function(){var t=this;this.time=setInterval((function(){t.searchData()}),1e3*this.timeSecend)},drawerHandleClose:function(){this.drawerShow=!1}}},d=u,h=n("2877"),f=Object(h["a"])(d,a,r,!1,null,"0f98f064",null);e["default"]=f.exports},cc06:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));n("4917"),n("ac6a"),n("456d");function a(t,e){var n,a=e.toLowerCase(),r=t;return n=a?r.filter((function(t){return Object.keys(t).some((function(e){return String(t[e]).toLowerCase().match(a)}))})):r,n}},e817:function(t,e,n){"use strict";n.d(e,"g",(function(){return i})),n.d(e,"f",(function(){return s})),n.d(e,"e",(function(){return o})),n.d(e,"h",(function(){return c})),n.d(e,"d",(function(){return l})),n.d(e,"c",(function(){return u})),n.d(e,"b",(function(){return d})),n.d(e,"a",(function(){return h}));var a=n("b775"),r="/api/realdata/";function i(t){return Object(a["a"])({url:r+"List",method:"post",data:t})}function s(t){return Object(a["a"])({url:r+"FailDataList",method:"post",data:t})}function o(t){return Object(a["a"])({url:r+"FailDataDesc",method:"post",data:t})}function c(t){return Object(a["a"])({url:r+"ReportCount",method:"post",data:t})}function l(t){return Object(a["a"])({url:r+"EventFailDesc",method:"post",data:t})}function u(t){return Object(a["a"])({url:r+"DelDebugDeviceID",method:"post",data:t})}function d(t){return Object(a["a"])({url:r+"DebugDeviceIDList",method:"post",data:t})}function h(t){return Object(a["a"])({url:r+"AddDebugDeviceID",method:"post",data:t})}}}]); |