pages-weather-details.e6689b76.js 28 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-weather-details"],{"12a3":function(t,e,n){var a=n("5bdc");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var i=n("4f06").default;i("0174fdd4",a,!0,{sourceMap:!1,shadowMode:!1})},"311d":function(t,e,n){"use strict";var a=n("4ea4");n("a9e3"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("96cf");var i=a(n("1da1")),r={name:"w-line-charts",data:function(){return{loading:!0,opts:{color:["#317afd"],padding:[10,10,0,15],enableScroll:!0,legend:{position:"top",float:"left"},dataLabel:!1,dataPointShapeType:"hollow",xAxis:{disableGrid:!0,fontColor:"#999",fontSize:10,axisLineColor:"#F4F7F9",scrollShow:!0,itemCount:5},yAxis:{gridColor:"#F4F7F9",gridType:"solid",dashLength:2,data:[{axisLineColor:"#F4F7F9",fontColor:"#999",fontSize:10}]},extra:{line:{type:"curve",width:3},tooltip:{showArrow:!0,gridType:"dash",labelBgColor:"#66ccff",gridColor:"#317afd"},markLine:{type:"dash",dashLength:5,data:[{lineColor:"#1A6EFE"}]}}}}},props:{chartData:{type:[Array,Object],default:function(){return[]}},width:{type:[Number],default:0},height:{type:[Number],default:0}},watch:{chartData:{deep:!0,handler:function(t){}}},mounted:function(){var t=this;return(0,i.default)(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t.width){e.next=2;break}return e.abrupt("return");case 2:case"end":return e.stop()}}),e)})))()},methods:{}};e.default=r},"3a37":function(t,e,n){"use strict";n.r(e);var a=n("d170"),i=n.n(a);for(var r in a)"default"!==r&&function(t){n.d(e,t,(function(){return a[t]}))}(r);e["default"]=i.a},"44ae":function(t,e,n){"use strict";n.r(e);var a=n("6cf3"),i=n("62a4");for(var r in i)"default"!==r&&function(t){n.d(e,t,(function(){return i[t]}))}(r);var o,s=n("f0c5"),c=Object(s["a"])(i["default"],a["b"],a["c"],!1,null,"ff9fa262",null,!1,a["a"],o);e["default"]=c.exports},4519:function(t,e,n){"use strict";var a=n("4ea4");n("99af"),n("4160"),n("b64b"),n("acd8"),n("ac1f"),n("1276"),n("159b"),Object.defineProperty(e,"__esModule",{value:!0}),e.getWeatherWarning=e.getWeatherDayData=e.getWeatherChart=e.getWeatherHistory=e.getWeatherDeviceDetail=e.getWeatherDeviceList=void 0,n("96cf");var i=a(n("1da1")),r=a(n("be72")),o=n("21f4"),s=function(){var t=(0,i.default)(regeneratorRuntime.mark((function t(e,n){var a;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,r.default.post("api/api_gateway?method=weather.weather.".concat(e),n);case 2:return a=t.sent,t.abrupt("return",null===a||void 0===a?void 0:a.data);case 4:case"end":return t.stop()}}),t)})));return function(e,n){return t.apply(this,arguments)}}(),c=function(t){return s("qxz_page",t)};e.getWeatherDeviceList=c;var u=function(){var t=(0,i.default)(regeneratorRuntime.mark((function t(e){var n,a,i,r,o,c,u;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,s("qxz_status",e);case 2:for(o in n=t.sent,a=n.dat,i=n.conf,r=[],a)a[o]&&"uptime"!=o&&(console.log(a[o]),c=a[o].split("#"),u=i[o].split("#"),r.push({el:o,markId:c[1],text:"".concat(u[0]," ").concat(u[1]),value:"".concat(c[0])}));return t.abrupt("return",r);case 8:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();e.getWeatherDeviceDetail=u;var l=function(){var t=(0,i.default)(regeneratorRuntime.mark((function t(e){var n,a,i,r,c,u,l,f,d,h,p,m,v;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,s("qxz_detail",e);case 2:for(l in n=t.sent,a=n.data,i=n.nums,r=n.conf,c=n.rainFall,u=[{text:"日期",value:"date"}],r)r[l]&&(f=r[l].split("#"),u.push({text:f[0]+f[1],value:l}));for(d=[],h=0;h<a.length;h++){for(m in p={date:(0,o.timeFormat)(a[h].time,"yyyy-mm-dd hh:MM:ss")},a[h].dat)a[h].dat[m]&&(v=a[h].dat[m].split("#"),p[m]=v[0]);d.push(p)}return t.abrupt("return",{headers:u,list:d,nums:i,rainFall:c});case 12:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();e.getWeatherHistory=l;var f=function(){var t=(0,i.default)(regeneratorRuntime.mark((function t(e){var n,a,i,r,c,u,l,f,d,h;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,s("qxz_data_chart",e);case 2:if(n=t.sent,a=n.data,i=n.conf,a){t.next=7;break}return t.abrupt("return");case 7:for(r=[],c=[],u={},Object.keys(i).forEach((function(t){i[t]&&(c.push({text:i[t].split("#").join(" "),value:t}),u[t]=[])})),l=0;l<a.length;l++){for(f in u)d=a[l].dat[f],d&&(h=d.split("#")[0],u[f].push(parseFloat(h)));r.push((0,o.timeFormat)(a[l].time,"mm月dd日"))}return t.abrupt("return",{times:r,pickes:c,charts:u});case 13:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();e.getWeatherChart=f;var d=function(){var t=(0,i.default)(regeneratorRuntime.mark((function t(e){var n;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,s("qxz_day_data",e);case 2:return n=t.sent,t.abrupt("return",n);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();e.getWeatherDayData=d;var h=function(t){return s("qxz_warning",t)};e.getWeatherWarning=h},4570:function(t,e,n){"use strict";var a=n("4ea4");n("99af"),n("4160"),n("caad"),n("d3b7"),n("2532"),n("159b"),Object.defineProperty(e,"__esModule",{value:!0}),e.createAnimation=f;var i=a(n("5530")),r=a(n("d4ec")),o=a(n("bee2")),s=function(){function t(e,n){(0,r.default)(this,t),this.options=e,this.animation=uni.createAnimation(e),this.currentStepAnimates={},this.next=0,this.$=n}return(0,o.default)(t,[{key:"_nvuePushAnimates",value:function(t,e){var n=this.currentStepAnimates[this.next],a={};if(a=n||{styles:{},config:{}},c.includes(t)){a.styles.transform||(a.styles.transform="");var i="";"rotate"===t&&(i="deg"),a.styles.transform+="".concat(t,"(").concat(e+i,") ")}else a.styles[t]="".concat(e);this.currentStepAnimates[this.next]=a}},{key:"_animateRun",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.$.$refs["ani"].ref;if(n)return new Promise((function(a,r){nvueAnimation.transition(n,(0,i.default)({styles:t},e),(function(t){a()}))}))}},{key:"_nvueNextAnimate",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,a=arguments.length>2?arguments[2]:void 0,i=t[n];if(i){var r=i.styles,o=i.config;this._animateRun(r,o).then((function(){n+=1,e._nvueNextAnimate(t,n,a)}))}else this.currentStepAnimates={},"function"===typeof a&&a(),this.isEnd=!0}},{key:"step",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.animation.step(t),this}},{key:"run",value:function(t){this.$.animationData=this.animation.export(),this.$.timer=setTimeout((function(){"function"===typeof t&&t()}),this.$.durationTime)}}]),t}(),c=["matrix","matrix3d","rotate","rotate3d","rotateX","rotateY","rotateZ","scale","scale3d","scaleX","scaleY","scaleZ","skew","skewX","skewY","translate","translate3d","translateX","translateY","translateZ"],u=["opacity","backgroundColor"],l=["width","height","left","right","top","bottom"];function f(t,e){if(e)return clearTimeout(e.timer),new s(t,e)}c.concat(u,l).forEach((function(t){s.prototype[t]=function(){var e;return(e=this.animation)[t].apply(e,arguments),this}}))},"4e7d":function(t,e,n){"use strict";n("7db0"),n("caad"),n("b64b"),n("2532"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var a={name:"Keypress",props:{disable:{type:Boolean,default:!1}},mounted:function(){var t=this,e={esc:["Esc","Escape"],tab:"Tab",enter:"Enter",space:[" ","Spacebar"],up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete","Del"]},n=function(n){if(!t.disable){var a=Object.keys(e).find((function(t){var a=n.key,i=e[t];return i===a||Array.isArray(i)&&i.includes(a)}));a&&setTimeout((function(){t.$emit(a,{})}),0)}};document.addEventListener("keyup",n)},render:function(){}};e.default=a},"4fc1":function(t,e,n){"use strict";var a=n("f276"),i=n.n(a);i.a},"5bdc":function(t,e,n){var a=n("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是app内置的常用样式变量\r\n *\r\n * app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 水平间距 */\r\n/* 水平间距 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.uni-popup[data-v-cb0579da]{position:fixed;z-index:99}.uni-popup.top[data-v-cb0579da], .uni-popup.left[data-v-cb0579da], .uni-popup.right[data-v-cb0579da]{top:var(--window-top)}.uni-popup .uni-popup__wrapper[data-v-cb0579da]{display:block;position:relative\r\n /* iphonex 等安全区设置,底部安全区适配 */}.uni-popup .uni-popup__wrapper.left[data-v-cb0579da], .uni-popup .uni-popup__wrapper.right[data-v-cb0579da]{padding-top:var(--window-top);flex:1}.fixforpc-z-index[data-v-cb0579da]{z-index:999}.fixforpc-top[data-v-cb0579da]{top:0}',""]),t.exports=e},"62a4":function(t,e,n){"use strict";n.r(e);var a=n("982a"),i=n.n(a);for(var r in a)"default"!==r&&function(t){n.d(e,t,(function(){return a[t]}))}(r);e["default"]=i.a},"6cf3":function(t,e,n){"use strict";var a;n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){return a}));var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.isShow?n("v-uni-view",{ref:"ani",class:t.customClass,style:t.transformStyles,attrs:{animation:t.animationData},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.onClick.apply(void 0,arguments)}}},[t._t("default")],2):t._e()},r=[]},7211:function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){return a}));var a={uniTransition:n("44ae").default},i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.showPopup?n("v-uni-view",{staticClass:"uni-popup",class:[t.popupstyle,t.isDesktop?"fixforpc-z-index":""]},[n("v-uni-view",{on:{touchstart:function(e){arguments[0]=e=t.$handleEvent(e),t.touchstart.apply(void 0,arguments)}}},[t.maskShow?n("uni-transition",{key:"1",attrs:{name:"mask","mode-class":"fade",styles:t.maskClass,duration:t.duration,show:t.showTrans},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.onTap.apply(void 0,arguments)}}}):t._e(),n("uni-transition",{key:"2",attrs:{"mode-class":t.ani,name:"content",styles:t.transClass,duration:t.duration,show:t.showTrans},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.onTap.apply(void 0,arguments)}}},[n("v-uni-view",{staticClass:"uni-popup__wrapper",class:[t.popupstyle],style:{backgroundColor:t.bg},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.clear.apply(void 0,arguments)}}},[t._t("default")],2)],1)],1),t.maskShow?n("keypress",{on:{esc:function(e){arguments[0]=e=t.$handleEvent(e),t.onTap.apply(void 0,arguments)}}}):t._e()],1):t._e()},r=[]},"81dc":function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){return a}));var a={uiCharts:n("291c").default},i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",[n("ui-charts",{ref:"wLineCharts",attrs:{type:"line",loadingType:0,ontouch:!0,opts:t.opts,chartData:t.chartData}})],1)},r=[]},"8b39":function(t,e,n){"use strict";n.r(e);var a=n("cc79"),i=n("ec5b");for(var r in i)"default"!==r&&function(t){n.d(e,t,(function(){return i[t]}))}(r);n("4fc1");var o,s=n("f0c5"),c=Object(s["a"])(i["default"],a["b"],a["c"],!1,null,"83b838ec",null,!1,a["a"],o);e["default"]=c.exports},"982a":function(t,e,n){"use strict";var a=n("4ea4");n("99af"),n("4160"),n("a9e3"),n("ac1f"),n("5319"),n("159b"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=a(n("2909")),r=a(n("5530")),o=n("4570"),s={name:"uniTransition",emits:["click","change"],props:{show:{type:Boolean,default:!1},modeClass:{type:[Array,String],default:function(){return"fade"}},duration:{type:Number,default:300},styles:{type:Object,default:function(){return{}}},customClass:{type:String,default:""}},data:function(){return{isShow:!1,transform:"",opacity:1,animationData:{},durationTime:300,config:{}}},watch:{show:{handler:function(t){t?this.open():this.isShow&&this.close()},immediate:!0}},computed:{stylesObject:function(){var t=(0,r.default)((0,r.default)({},this.styles),{},{"transition-duration":this.duration/1e3+"s"}),e="";for(var n in t){var a=this.toLine(n);e+=a+":"+t[n]+";"}return e},transformStyles:function(){return"transform:"+this.transform+";opacity:"+this.opacity+";"+this.stylesObject}},created:function(){this.config={duration:this.duration,timingFunction:"ease",transformOrigin:"50% 50%",delay:0},this.durationTime=this.duration},methods:{init:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t.duration&&(this.durationTime=t.duration),this.animation=(0,o.createAnimation)(Object.assign(this.config,t),this)},onClick:function(){this.$emit("click",{detail:this.isShow})},step:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.animation){for(var n in t)try{var a;if("object"===typeof t[n])(a=this.animation)[n].apply(a,(0,i.default)(t[n]));else this.animation[n](t[n])}catch(r){console.error("方法 ".concat(n," 不存在"))}return this.animation.step(e),this}},run:function(t){this.animation&&this.animation.run(t)},open:function(){var t=this;clearTimeout(this.timer),this.transform="",this.isShow=!0;var e=this.styleInit(!1),n=e.opacity,a=e.transform;"undefined"!==typeof n&&(this.opacity=n),this.transform=a,this.$nextTick((function(){t.timer=setTimeout((function(){t.animation=(0,o.createAnimation)(t.config,t),t.tranfromInit(!1).step(),t.animation.run(),t.$emit("change",{detail:t.isShow})}),20)}))},close:function(t){var e=this;this.animation&&this.tranfromInit(!0).step().run((function(){e.isShow=!1,e.animationData=null,e.animation=null;var t=e.styleInit(!1),n=t.opacity,a=t.transform;e.opacity=n||1,e.transform=a,e.$emit("change",{detail:e.isShow})}))},styleInit:function(t){var e=this,n={transform:""},a=function(t,a){"fade"===a?n.opacity=e.animationType(t)[a]:n.transform+=e.animationType(t)[a]+" "};return"string"===typeof this.modeClass?a(t,this.modeClass):this.modeClass.forEach((function(e){a(t,e)})),n},tranfromInit:function(t){var e=this,n=function(t,n){var a=null;"fade"===n?a=t?0:1:(a=t?"-100%":"0","zoom-in"===n&&(a=t?.8:1),"zoom-out"===n&&(a=t?1.2:1),"slide-right"===n&&(a=t?"100%":"0"),"slide-bottom"===n&&(a=t?"100%":"0")),e.animation[e.animationMode()[n]](a)};return"string"===typeof this.modeClass?n(t,this.modeClass):this.modeClass.forEach((function(e){n(t,e)})),this.animation},animationType:function(t){return{fade:t?1:0,"slide-top":"translateY(".concat(t?"0":"-100%",")"),"slide-right":"translateX(".concat(t?"0":"100%",")"),"slide-bottom":"translateY(".concat(t?"0":"100%",")"),"slide-left":"translateX(".concat(t?"0":"-100%",")"),"zoom-in":"scaleX(".concat(t?1:.8,") scaleY(").concat(t?1:.8,")"),"zoom-out":"scaleX(".concat(t?1:1.2,") scaleY(").concat(t?1:1.2,")")}},animationMode:function(){return{fade:"opacity","slide-top":"translateY","slide-right":"translateX","slide-bottom":"translateY","slide-left":"translateX","zoom-in":"scale","zoom-out":"scale"}},toLine:function(t){return t.replace(/([A-Z])/g,"-$1").toLowerCase()}}};e.default=s},b0d8:function(t,e,n){"use strict";n.r(e);var a=n("7211"),i=n("3a37");for(var r in i)"default"!==r&&function(t){n.d(e,t,(function(){return i[t]}))}(r);n("d3b3");var o,s=n("f0c5"),c=Object(s["a"])(i["default"],a["b"],a["c"],!1,null,"cb0579da",null,!1,a["a"],o);e["default"]=c.exports},b776:function(t,e,n){"use strict";var a=n("4ea4");n("7db0"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("96cf");var i=a(n("1da1")),r=n("4519"),o=a(n("f7f1")),s={data:function(){return{deviceInfo:{},latestList:[],dayData:null,dayDatas:[],chartShowData:{categories:[],series:[]},chartData:null}},components:{lineCharts:o.default},onLoad:function(t){this.deviceInfo=JSON.parse(t.params),this.getLatestList(),this.getWeatherDayData(),this.getWeatherChart()},methods:{getLatestList:function(){var t=this;return(0,i.default)(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,(0,r.getWeatherDeviceDetail)({device_id:t.deviceInfo.equip_id});case 2:t.latestList=e.sent;case 3:case"end":return e.stop()}}),e)})))()},getWeatherDayData:function(){var t=this;return(0,i.default)(regeneratorRuntime.mark((function e(){var n,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t.$api.loading("加载中..."),e.next=3,(0,r.getWeatherDayData)({device_id:t.deviceInfo.equip_id});case 3:n=e.sent,a=n.data,t.$api.hide(),t.dayDatas=null!==a&&void 0!==a?a:[];case 7:case"end":return e.stop()}}),e)})))()},openLatestChart:function(t,e){var n;if(!this.chartData)return this.$api.msg("数据加载中,请稍后");this.dayData=this.dayDatas.find((function(e){return e.ekey==t})),this.chartShowData.series=[{name:e,data:null!==(n=this.chartData[t])&&void 0!==n?n:[]}],this.$refs["chartsPopup"].open()},closeChartsPopup:function(){this.dayData=null,this.$refs["chartsPopup"].close()},getWeatherChart:function(){var t=this;return(0,i.default)(regeneratorRuntime.mark((function e(){var n,a,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,(0,r.getWeatherChart)({device_id:t.deviceInfo.equip_id,begin:t.$util.timeFrame("start"),end:t.$util.timeFrame("end")});case 2:n=e.sent,a=n.times,i=n.charts,t.chartData=i,console.log(t.chartData),t.chartShowData.categories=a;case 8:case"end":return e.stop()}}),e)})))()}}};e.default=s},c5e1:function(t,e,n){"use strict";n.r(e);var a=n("311d"),i=n.n(a);for(var r in a)"default"!==r&&function(t){n.d(e,t,(function(){return a[t]}))}(r);e["default"]=i.a},cc79:function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){return a}));var a={uniPopup:n("b0d8").default},i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",[n("v-uni-view",{staticClass:"ui-card forecast-card"},[n("v-uni-view",{staticClass:"flex-1"},[n("v-uni-view",{staticClass:"font-16 title"},[t._v("设备名称:"+t._s(t.deviceInfo.equip_name))]),n("v-uni-view",{staticClass:"text"},[t._v("设备ID:"+t._s(t.deviceInfo.equip_id))]),n("v-uni-view",{staticClass:"text text-ellipsis"},[t._v("地址:"+t._s(t.deviceInfo.address))]),n("v-uni-view",{staticClass:"text"},[t._v("最新上报时间:"+t._s(t._f("timeFrom")(t.deviceInfo.uptime)))])],1),n("v-uni-navigator",{staticClass:"font-12 state",attrs:{url:"warn?type="+t.deviceInfo.device_type,"hover-class":"none"}},[t._v("预警")])],1),n("v-uni-view",{staticClass:"row-between m-12"},[n("v-uni-view",{staticClass:"font-16 mr"},[t._v("实时数据")]),n("v-uni-view",{staticClass:"flex-1 font-10 text-sub"},[t._v("(可点击查看24小时数据)")]),n("v-uni-navigator",{staticClass:"font-14 text-primary",attrs:{url:"history?id="+t.deviceInfo.equip_id,"hover-class":"none"}},[t._v("历史数据")])],1),n("v-uni-view",{staticClass:"latest-list"},[t._l(t.latestList,(function(e,a){return[n("v-uni-view",{key:a+"_0",staticClass:"ui-card latest-item",on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.openLatestChart(e.el,e.text)}}},[n("v-uni-view",{staticClass:"icon"},[n("v-uni-image",{attrs:{src:"/static/icon/"+e.markId+".png"}})],1),n("v-uni-view",{staticClass:"column-between text-info font-12"},[n("v-uni-view",{staticClass:"text"},[t._v(t._s(e.text))]),n("v-uni-view",{staticClass:"text"},[t._v(t._s(e.value))])],1)],1)]}))],2),n("uni-popup",{ref:"chartsPopup",attrs:{type:"bottom","mask-click":!1}},[t.dayData?n("v-uni-view",{staticClass:"column charts-popup"},[n("v-uni-view",{staticClass:"flex-1"},[n("v-uni-view",{staticClass:"charts-title"},[t._v("24小时数据")]),n("lineCharts",{attrs:{chartData:t.chartShowData,width:200,height:200}}),n("v-uni-view",{staticClass:"charts-text mt-12"},[t._v("当天最大值:"+t._s(t.dayData.max)+" "+t._s(t._f("timeFrom")(t.dayData.maxtime)))]),n("v-uni-view",{staticClass:"charts-text"},[t._v("当天最小值:"+t._s(t.dayData.min)+" "+t._s(t._f("timeFrom")(t.dayData.mintime)))])],1),n("v-uni-view",{staticClass:"row-center charts-cancel",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.closeChartsPopup.apply(void 0,arguments)}}},[t._v("取消")])],1):t._e()],1)],1)},r=[]},d170:function(t,e,n){"use strict";var a=n("4ea4");n("c975"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=a(n("4e7d")),r={name:"uniPopup",components:{keypress:i.default},emits:["change","maskClick"],props:{animation:{type:Boolean,default:!0},type:{type:String,default:"center"},isMaskClick:{type:Boolean,default:null},maskClick:{type:Boolean,default:null},backgroundColor:{type:String,default:"none"},safeArea:{type:Boolean,default:!0},maskBackgroundColor:{type:String,default:"rgba(0, 0, 0, 0.4)"}},watch:{type:{handler:function(t){this.config[t]&&this[this.config[t]](!0)},immediate:!0},isDesktop:{handler:function(t){this.config[t]&&this[this.config[this.type]](!0)},immediate:!0},maskClick:{handler:function(t){this.mkclick=t},immediate:!0},isMaskClick:{handler:function(t){this.mkclick=t},immediate:!0},showPopup:function(t){document.getElementsByTagName("body")[0].style.overflow=t?"hidden":"visible"}},data:function(){return{duration:300,ani:[],showPopup:!1,showTrans:!1,popupWidth:0,popupHeight:0,config:{top:"top",bottom:"bottom",center:"center",left:"left",right:"right",message:"top",dialog:"center",share:"bottom"},maskClass:{position:"fixed",bottom:0,top:0,left:0,right:0,backgroundColor:"rgba(0, 0, 0, 0.4)"},transClass:{position:"fixed",left:0,right:0},maskShow:!0,mkclick:!0,popupstyle:this.isDesktop?"fixforpc-top":"top"}},computed:{isDesktop:function(){return this.popupWidth>=500&&this.popupHeight>=500},bg:function(){return""===this.backgroundColor||"none"===this.backgroundColor?"transparent":this.backgroundColor}},mounted:function(){var t=this,e=function(){var e=uni.getSystemInfoSync(),n=e.windowWidth,a=e.windowHeight,i=e.windowTop,r=e.safeArea,o=(e.screenHeight,e.safeAreaInsets);t.popupWidth=n,t.popupHeight=a+(i||0),r&&t.safeArea?t.safeAreaInsets=o.bottom:t.safeAreaInsets=0};e()},destroyed:function(){this.setH5Visible()},created:function(){null===this.isMaskClick&&null===this.maskClick?this.mkclick=!0:this.mkclick=null!==this.isMaskClick?this.isMaskClick:this.maskClick,this.animation?this.duration=300:this.duration=0,this.messageChild=null,this.clearPropagation=!1,this.maskClass.backgroundColor=this.maskBackgroundColor},methods:{setH5Visible:function(){document.getElementsByTagName("body")[0].style.overflow="visible"},closeMask:function(){this.maskShow=!1},disableMask:function(){this.mkclick=!1},clear:function(t){t.stopPropagation(),this.clearPropagation=!0},open:function(t){this.showPopup&&(clearTimeout(this.timer),this.showPopup=!1);var e=["top","center","bottom","left","right","message","dialog","share"];t&&-1!==e.indexOf(t)||(t=this.type),this.config[t]?(this[this.config[t]](),this.$emit("change",{show:!0,type:t})):console.error("缺少类型:",t)},close:function(t){var e=this;this.showTrans=!1,this.$emit("change",{show:!1,type:this.type}),clearTimeout(this.timer),this.timer=setTimeout((function(){e.showPopup=!1}),300)},touchstart:function(){this.clearPropagation=!1},onTap:function(){this.clearPropagation?this.clearPropagation=!1:(this.$emit("maskClick"),this.mkclick&&this.close())},top:function(t){var e=this;this.popupstyle=this.isDesktop?"fixforpc-top":"top",this.ani=["slide-top"],this.transClass={position:"fixed",left:0,right:0,backgroundColor:this.bg},t||(this.showPopup=!0,this.showTrans=!0,this.$nextTick((function(){e.messageChild&&"message"===e.type&&e.messageChild.timerClose()})))},bottom:function(t){this.popupstyle="bottom",this.ani=["slide-bottom"],this.transClass={position:"fixed",left:0,right:0,bottom:0,paddingBottom:this.safeAreaInsets+"px",backgroundColor:this.bg},t||(this.showPopup=!0,this.showTrans=!0)},center:function(t){this.popupstyle="center",this.ani=["zoom-out","fade"],this.transClass={position:"fixed",display:"flex",flexDirection:"column",bottom:0,left:0,right:0,top:0,justifyContent:"center",alignItems:"center"},t||(this.showPopup=!0,this.showTrans=!0)},left:function(t){this.popupstyle="left",this.ani=["slide-left"],this.transClass={position:"fixed",left:0,bottom:0,top:0,backgroundColor:this.bg,display:"flex",flexDirection:"column"},t||(this.showPopup=!0,this.showTrans=!0)},right:function(t){this.popupstyle="right",this.ani=["slide-right"],this.transClass={position:"fixed",bottom:0,right:0,top:0,backgroundColor:this.bg,display:"flex",flexDirection:"column"},t||(this.showPopup=!0,this.showTrans=!0)}}};e.default=r},d3b3:function(t,e,n){"use strict";var a=n("12a3"),i=n.n(a);i.a},df1a:function(t,e,n){var a=n("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是app内置的常用样式变量\r\n *\r\n * app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 水平间距 */\r\n/* 水平间距 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.charts-popup[data-v-83b838ec]{position:relative;width:100%;background-color:#fff;padding:%?50?% %?32?% %?20?%;border-radius:%?12?% %?12?% %?0?% %?0?%;height:%?850?%}.charts-icon[data-v-83b838ec]{position:absolute;right:%?-20?%;top:%?-50?%}.charts-box[data-v-83b838ec]{width:100%;height:%?450?%;overflow:hidden}.charts-title[data-v-83b838ec]{font-size:%?32?%;color:#333;line-height:%?44?%;text-align:center}.charts-text[data-v-83b838ec]{font-size:%?24?%;color:#666;line-height:%?40?%}.charts-cancel[data-v-83b838ec]{border-top:#f5f5f5 %?26?% solid;margin-left:%?-32?%;margin-right:%?-32?%;padding:%?24?%;color:#999}',""]),t.exports=e},ec5b:function(t,e,n){"use strict";n.r(e);var a=n("b776"),i=n.n(a);for(var r in a)"default"!==r&&function(t){n.d(e,t,(function(){return a[t]}))}(r);e["default"]=i.a},f276:function(t,e,n){var a=n("df1a");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var i=n("4f06").default;i("140ea521",a,!0,{sourceMap:!1,shadowMode:!1})},f7f1:function(t,e,n){"use strict";n.r(e);var a=n("81dc"),i=n("c5e1");for(var r in i)"default"!==r&&function(t){n.d(e,t,(function(){return i[t]}))}(r);var o,s=n("f0c5"),c=Object(s["a"])(i["default"],a["b"],a["c"],!1,null,"1ec94d18",null,!1,a["a"],o);e["default"]=c.exports}}]);