| 12 |
- (global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/prevention/equipmentdetails"],{775:function(e,t,n){"use strict";(function(e,t){var i=n(4);n(26);i(n(25));var a=i(n(776));e.__webpack_require_UNI_MP_PLUGIN__=n,t(a.default)}).call(this,n(1)["default"],n(2)["createPage"])},776:function(e,t,n){"use strict";n.r(t);var i=n(777),a=n(779);for(var o in a)["default"].indexOf(o)<0&&function(e){n.d(t,e,(function(){return a[e]}))}(o);n(781);var r,d=n(32),s=Object(d["default"])(a["default"],i["render"],i["staticRenderFns"],!1,null,null,null,!1,i["components"],r);s.options.__file="pages/prevention/equipmentdetails.vue",t["default"]=s.exports},777:function(e,t,n){"use strict";n.r(t);var i=n(778);n.d(t,"render",(function(){return i["render"]})),n.d(t,"staticRenderFns",(function(){return i["staticRenderFns"]})),n.d(t,"recyclableRender",(function(){return i["recyclableRender"]})),n.d(t,"components",(function(){return i["components"]}))},778:function(e,t,n){"use strict";var i;n.r(t),n.d(t,"render",(function(){return a})),n.d(t,"staticRenderFns",(function(){return r})),n.d(t,"recyclableRender",(function(){return o})),n.d(t,"components",(function(){return i}));try{i={uniNavBar:function(){return n.e("components/uni-nav-bar/uni-nav-bar").then(n.bind(null,1164))}}}catch(d){if(-1===d.message.indexOf("Cannot find module")||-1===d.message.indexOf(".vue"))throw d;console.error(d.message),console.error("1. 排查组件名称拼写是否正确"),console.error("2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"),console.error("3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件")}var a=function(){var e=this,t=e.$createElement,n=(e._self._c,e._f("timeFormat")(e.eqinfo.item.addtime)),i=e.$QueryPermission(75),a=e.$QueryPermission(77),o=e.$QueryPermission(76);e.$mp.data=Object.assign({},{$root:{f0:n,m0:i,m1:a,m2:o}})},o=!1,r=[];a._withStripped=!0},779:function(e,t,n){"use strict";n.r(t);var i=n(780),a=n.n(i);for(var o in i)["default"].indexOf(o)<0&&function(e){n.d(t,e,(function(){return i[e]}))}(o);t["default"]=a.a},780:function(e,t,n){"use strict";(function(e){var i=n(4);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=i(n(41)),o=i(n(43)),r={data:function(){return{eqinfo:{item:{}},olddata:{},olddatas:[],newdatesTF:!1,dataloadingtf:!1,work:"",shujutf:!1,kongtf:!1,simtf:!1}},methods:{modification:function(){this.olddatas=[{icon:"/image/cb/icon02.png",txt:"设备开关",value:this.olddata.ds},{icon:"/image/cb/icon05.png",txt:"工作状态",value:this.work},{icon:"/image/prevention/44.png",txt:"电击次数",value:this.olddata.ct},{icon:"/image/prevention/33.png",txt:"定时时长",value:this.olddata.tt},{icon:"/image/cb/icon08.png",txt:"环境温度(℃)",value:""==this.olddata.at?"--":this.olddata.at},{icon:"/image/cb/icon07.png",txt:"环境湿度(%)",value:""==this.olddata.ah?"--":this.olddata.ah},{icon:"/image/prevention/icon16.png",txt:"信号强度",value:this.olddata.csq},{icon:"/image/prevention/100.png",txt:"清虫间隔(min)",value:this.olddata.clt_t},{icon:"/image/prevention/101.png",txt:"雨控状态",value:this.olddata.rps},{icon:"/image/prevention/102.png",txt:"温控状态",value:this.olddata.tps},{icon:"/image/prevention/105.png",txt:"充电电压",value:this.olddata.cv},{icon:"/image/prevention/106.png",txt:"电池电压",value:this.olddata.bv}]},history:function(){var e=this;return(0,o.default)(a.default.mark((function t(){var n,i,o;return a.default.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return n=+new Date/1e3,i=n-86400,e.dataloadingtf=!0,t.next=5,e.$myRequest({url:"/api/api_gateway?method=forecast.worm_lamp.device_history_data",data:{device_type_id:2,device_id:e.eqinfo.item.imei,start_time:parseInt(i),end_time:parseInt(n)}});case 5:o=t.sent,e.dataloadingtf=!1,0!=o.data.length?(e.olddata=o.data[0].d_h_t,e.newdatesTF=!0,e.work=e.olddata.ws):e.newdatesTF=!1,e.modification();case 9:case"end":return t.stop()}}),t)})))()},eqlist:function(e){var t=this;return(0,o.default)(a.default.mark((function n(){var i;return a.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return n.next=2,t.$myRequest({url:"/api/api_gateway?method=forecast.worm_lamp.lamp_list",data:{device_type_id:2,device_id:e}});case 2:i=n.sent,t.eqinfo.item=i.data[0],t.dataloadingtf=!0,t.history();case 6:case"end":return n.stop()}}),n)})))()},clickLeft:function(){e.navigateBack({delta:1})},sim:function(){e.navigateTo({url:"./sim?id="+this.eqinfo.item.d_id})},repairs:function(){console.log(this.eqinfo.item);var t=this.eqinfo.item.equip_id||this.eqinfo.item.device_id;e.navigateTo({url:"../afterSale/addafter?device_id="+t+"&device_type=2"})},control:function(){e.navigateTo({url:"./control?id="+this.eqinfo.item.d_id})},charts:function(){e.navigateTo({url:"./ucharts?d_id="+this.eqinfo.item.d_id+"&imei="+this.eqinfo.item.imei})},copy:function(t){e.setClipboardData({data:t,success:function(){console.log("success")}})},selectaddress:function(t,n){var i=this;e.request({type:"GET",url:"https://restapi.amap.com/v3/geocode/regeo?output=JSON&location="+n+","+t+"&key=27273b81090f78759e4057f94474516f&radius=1000&extensions=all",dataType:"json",complete:function(e){console.log(e.data.regeocode.formatted_address),i.city=e.data.regeocode.formatted_address}})}},onLoad:function(e){this.$forceUpdate(),this.eqinfo.item=JSON.parse(e.shebei),console.log(JSON.parse(e.shebei)),this.history(),this.selectaddress(this.eqinfo.item.lat,this.eqinfo.item.lng)}};t.default=r}).call(this,n(2)["default"])},781:function(e,t,n){"use strict";n.r(t);var i=n(782),a=n.n(i);for(var o in i)["default"].indexOf(o)<0&&function(e){n.d(t,e,(function(){return i[e]}))}(o);t["default"]=a.a},782:function(e,t,n){}},[[775,"common/runtime","common/vendor"]]]);
- //# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/prevention/equipmentdetails.js.map
|