张卓
2022-09-29 4ef1c909df36c48f7f040e9ec408fc15e6745e71
1
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-46d6b12c"],{"4aba":function(e,t,a){"use strict";a("8b28")},5323:function(e,t,a){"use strict";a.r(t);var o=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticStyle:{width:"100%"}},[a("div",{staticClass:"topSelect"},[a("el-cascader",{staticStyle:{width:"354px"},attrs:{options:e.options,clearable:"",placeholder:"选择设备"},model:{value:e.newMac,callback:function(t){e.newMac=t},expression:"newMac"}}),e._v(" "),a("el-select",{staticStyle:{"margin-left":"20px"},attrs:{placeholder:"选择因子"},model:{value:e.value,callback:function(t){e.value=t},expression:"value"}},e._l(e.newSensor,(function(e){return a("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1),e._v(" "),a(e.dataType,{tag:"component",staticStyle:{"padding-left":"0","margin-left":"20px",width:"160px"},on:{sendPickerChild:e.showPickerChild}}),e._v(" "),a("el-button",{staticClass:"btn1",on:{click:e.selectData}},[e._v("查询")])],1),e._v(" "),a("LineChart",{attrs:{"chart-data":e.lineChartData}})],1)},n=[],r=a("2909"),i=(a("ac6a"),a("7f7f"),a("4515")),c=a("9f16"),l=a("011f"),s=a("fe13"),u=a("c56f"),f=a("cf16"),d={newVisitis:{expectedData:[100,120,161,134,105,160,165],actualData:[120,82,91,154,162,140,145]},messages:{expectedData:[200,192,120,144,160,130,140],actualData:[180,160,151,106,145,150,130]},purchases:{expectedData:[80,100,121,104,105,90,100],actualData:[120,90,100,138,142,130,130]},shoppings:{expectedData:[130,140,141,142,145,150,160],actualData:[120,82,91,154,162,140,130]}},h={components:{LineChart:i["a"],DatePicker:c["a"],MouthPicker:l["a"],HourPicker:s["a"],CustomPicker:u["a"]},filters:{sensorFilter:function(e){return e?f[e]:""}},props:{},data:function(){return{dataType:"HourPicker",lineChartData:d.purchases,props:{multiple:!0},options:[],value:"",value1:"",newMac:"",newMac1:[],newSensor:[],radio1:"日报",unit:1,type:"select",newLineChartData:{series:[],xAxis:[],title:""},newData:"",defaultData:[],newListData:[],chartSensorName:"",middleData:[],seriesName:["平均值","最小值","最大值"]}},computed:{},watch:{newMac:function(e,t){this.newMac1=[],this.newMac1.push(e[1][1]),this.getSensor()},radio1:function(e,t){"日报"===e?(this.dataType="HourPicker",this.unit=1):"月报"===e&&(this.dataType="DatePicker",this.unit=3)}},created:function(){this.getData()},mounted:function(){},beforeCreate:function(){},beforeMount:function(){},beforeUpdate:function(){},updated:function(){},beforeDestroy:function(){},destroyed:function(){},activated:function(){},methods:{getData:function(){var e=this;this.$request({url:"/monitorPoint/queryMonitorPoints",method:"get",params:{organizationId:this.$store.state.orgId}}).then((function(t){e.defaultData=t.data.monitorPoints;for(var a=0;a<e.defaultData.length;a++)if(e.options.push({value:e.defaultData[a].name,label:e.defaultData[a].name}),e.options[a].children=[],e.defaultData[a].devices)for(var o=0;o<e.defaultData[a].devices.length;o++)e.options[a].children.push({value:[e.defaultData[a].devices[o].name,e.defaultData[a].devices[o].mac],label:e.defaultData[a].devices[o].name})})).catch((function(e){console.log(e)}))},getSensor:function(){var e=this;this.$request({url:"/deviceInfo/getMacSensors",method:"post",data:{macs:this.newMac1}}).then((function(t){e.newSensor=[];var a=t.data;for(var o in a)e.newSensor.push({value:o,label:a[o]})})).catch((function(e){console.log(e)}))},selectData:function(){var e=this,t={series:[],xAxis:[],title:[]};this.newXData=[],this.$request({url:"/historyHourly/getHourCompleteDataByMacSensorCodeDate",method:"get",params:{mac:this.newMac1[0],sensor_code:this.value,date:this.newData}}).then((function(a){for(var o=a.data,n=0;n<3;n++){t.series.push({data:[],name:"",type:"line"});for(var r=0;r<o.length;r++)t.series[n].data.push(o[r].values[n]),t.series[n].name=e.seriesName[n],t.xAxis.push(o[r].time);t.title=e.seriesName}e.lineChartData=t})).catch((function(e){console.log(e)}))},showPickerChild:function(e){this.newData=e},getMaxValue:function(e){return Math.max.apply(Math,Object(r["a"])(e))},compare:function(e,t){return function(a,o){var n=a[e],r=o[e];return!0===t?n-r:r-n}},filterSensorName:function(){this.chartSensorName=this.$options.filters.sensorFilter(this.chartSensorKey[0].sensorCode)}}},p=h,m=(a("4aba"),a("2877")),y=Object(m["a"])(p,o,n,!1,null,"28cf4e53",null);t["default"]=y.exports},"817d":function(e,t,a){var o,n,r;(function(i,c){n=[t,a("313e")],o=c,r="function"===typeof o?o.apply(t,n):o,void 0===r||(e.exports=r)})(0,(function(e,t){var a=function(e){"undefined"!==typeof console&&console&&console.error&&console.error(e)};if(t){var o=["#2ec7c9","#b6a2de","#5ab1ef","#ffb980","#d87a80","#8d98b3","#e5cf0d","#97b552","#95706d","#dc69aa","#07a2a4","#9a7fd1","#588dd5","#f5994e","#c05050","#59678c","#c9ab00","#7eb00a","#6f5553","#c14089"],n={color:o,title:{textStyle:{fontWeight:"normal",color:"#008acd"}},visualMap:{itemWidth:15,color:["#5ab1ef","#e0ffff"]},toolbox:{iconStyle:{normal:{borderColor:o[0]}}},tooltip:{backgroundColor:"rgba(50,50,50,0.5)",axisPointer:{type:"line",lineStyle:{color:"#008acd"},crossStyle:{color:"#008acd"},shadowStyle:{color:"rgba(200,200,200,0.2)"}}},dataZoom:{dataBackgroundColor:"#efefff",fillerColor:"rgba(182,162,222,0.2)",handleColor:"#008acd"},grid:{borderColor:"#eee"},categoryAxis:{axisLine:{lineStyle:{color:"#008acd"}},splitLine:{lineStyle:{color:["#eee"]}}},valueAxis:{axisLine:{lineStyle:{color:"#008acd"}},splitArea:{show:!0,areaStyle:{color:["rgba(250,250,250,0.1)","rgba(200,200,200,0.1)"]}},splitLine:{lineStyle:{color:["#eee"]}}},timeline:{lineStyle:{color:"#008acd"},controlStyle:{color:"#008acd",borderColor:"#008acd"},symbol:"emptyCircle",symbolSize:3},line:{smooth:!0,symbol:"emptyCircle",symbolSize:3},candlestick:{itemStyle:{color:"#d87a80",color0:"#2ec7c9"},lineStyle:{width:1,color:"#d87a80",color0:"#2ec7c9"},areaStyle:{color:"#2ec7c9",color0:"#b6a2de"}},scatter:{symbol:"circle",symbolSize:4},map:{itemStyle:{color:"#ddd"},areaStyle:{color:"#fe994e"},label:{color:"#d87a80"}},graph:{itemStyle:{color:"#d87a80"},linkStyle:{color:"#2ec7c9"}},gauge:{axisLine:{lineStyle:{color:[[.2,"#2ec7c9"],[.8,"#5ab1ef"],[1,"#d87a80"]],width:10}},axisTick:{splitNumber:10,length:15,lineStyle:{color:"auto"}},splitLine:{length:22,lineStyle:{color:"auto"}},pointer:{width:5}}};t.registerTheme("macarons",n)}else a("ECharts is not Loaded")}))},"8b28":function(e,t,a){},aa77:function(e,t,a){var o=a("5ca1"),n=a("be13"),r=a("79e5"),i=a("fdef"),c="["+i+"]",l="​…",s=RegExp("^"+c+c+"*"),u=RegExp(c+c+"*$"),f=function(e,t,a){var n={},c=r((function(){return!!i[e]()||l[e]()!=l})),s=n[e]=c?t(d):i[e];a&&(n[a]=s),o(o.P+o.F*c,"String",n)},d=f.trim=function(e,t){return e=String(n(e)),1&t&&(e=e.replace(s,"")),2&t&&(e=e.replace(u,"")),e};e.exports=f},c5f6:function(e,t,a){"use strict";var o=a("7726"),n=a("69a8"),r=a("2d95"),i=a("5dbc"),c=a("6a99"),l=a("79e5"),s=a("9093").f,u=a("11e9").f,f=a("86cc").f,d=a("aa77").trim,h="Number",p=o[h],m=p,y=p.prototype,b=r(a("2aeb")(y))==h,v="trim"in String.prototype,g=function(e){var t=c(e,!1);if("string"==typeof t&&t.length>2){t=v?t.trim():d(t,3);var a,o,n,r=t.charCodeAt(0);if(43===r||45===r){if(a=t.charCodeAt(2),88===a||120===a)return NaN}else if(48===r){switch(t.charCodeAt(1)){case 66:case 98:o=2,n=49;break;case 79:case 111:o=8,n=55;break;default:return+t}for(var i,l=t.slice(2),s=0,u=l.length;s<u;s++)if(i=l.charCodeAt(s),i<48||i>n)return NaN;return parseInt(l,o)}}return+t};if(!p(" 0o1")||!p("0b1")||p("+0x1")){p=function(e){var t=arguments.length<1?0:e,a=this;return a instanceof p&&(b?l((function(){y.valueOf.call(a)})):r(a)!=h)?i(new m(g(t)),a,p):g(t)};for(var S,w=a("9e1e")?s(m):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),D=0;w.length>D;D++)n(m,S=w[D])&&!n(p,S)&&f(p,S,u(m,S));p.prototype=y,y.constructor=p,a("2aba")(o,h,p)}},cf16:function(e){e.exports={flylon:"经度",a00e12:"光照强度",a00e34:"TSP",a00e13:"噪音",a21005:"一氧化碳",a21004:"二氧化氮",a21026:"二氧化硫",a21028:"硫化氢",flyhig:"高度",a21001:"氨气",a40002:"苯乙烯",a21022:"氯气",a00e19:"二氧化碳",a40001:"烟气流量",a01001:"温度",a25005:"二甲苯",a05024:"臭氧",a21024:"氯化氢",a40003:"环氧乙烷",a25003:"甲苯",a01002:"湿度",a25002:"苯",a23001:"酚类",a01007:"风速",a01006:"气压",a01008:"风向",a30001:"甲醇",a19002:"臭气浓度",a19001:"氧气",a34002:"PM10",a34004:"PM2.5",dustld:"尘负荷",PORRST:"开机标识",a00e03:"颗粒物0.3",a00e04:"颗粒物2.5",a06001:"雨量",a99054:"TVOC",a35e21:"核辐射",a01011:"烟气流速",a24088:"非甲烷总烃",flylat:"纬度",a31001:"甲醛"}},fdef:function(e,t){e.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"}}]);