(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/order/waimaiMap"],{182:function(e,t,n){"use strict";(function(e){n(5);r(n(4));var t=r(n(183));function r(e){return e&&e.__esModule?e:{default:e}}wx.__webpack_require_UNI_MP_PLUGIN__=n,e(t.default)}).call(this,n(1)["createPage"])},183:function(e,t,n){"use strict";n.r(t);var r=n(184),i=n(186);for(var o in i)"default"!==o&&function(e){n.d(t,e,(function(){return i[e]}))}(o);n(188);var a,d=n(11),c=Object(d["default"])(i["default"],r["render"],r["staticRenderFns"],!1,null,null,null,!1,r["components"],a);c.options.__file="pages/order/waimaiMap.vue",t["default"]=c.exports},184:function(e,t,n){"use strict";n.r(t);var r=n(185);n.d(t,"render",(function(){return r["render"]})),n.d(t,"staticRenderFns",(function(){return r["staticRenderFns"]})),n.d(t,"recyclableRender",(function(){return r["recyclableRender"]})),n.d(t,"components",(function(){return r["components"]}))},185:function(e,t,n){"use strict";var r;n.r(t),n.d(t,"render",(function(){return i})),n.d(t,"staticRenderFns",(function(){return a})),n.d(t,"recyclableRender",(function(){return o})),n.d(t,"components",(function(){return r}));var i=function(){var e=this,t=e.$createElement;e._self._c},o=!1,a=[];i._withStripped=!0},186:function(e,t,n){"use strict";n.r(t);var r=n(187),i=n.n(r);for(var o in r)"default"!==o&&function(e){n.d(t,e,(function(){return r[e]}))}(o);t["default"]=i.a},187:function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n={data:function(){return{latitude:"",longitude:"",markers:[],orderId:"",riderUserId:"",orderDetails:{},rider:{},timer:"",lat:"",lng:""}},onLoad:function(t){var n=this;n.orderId=t.orderId,e.getLocation({type:"gcj02",success:function(e){n.lat=e.latitude,n.lng=e.longitude,n.getData()},fail:function(t){e.hideLoading(),e.showModal({title:"温馨提示",content:"您的定位权限未开启，请开启后再来操作吧！",showCancel:!0,cancelText:"取消",confirmText:"确认",success:function(t){t.confirm&&e.openSetting({success:function(e){console.log(e.authSetting)}})}})}})},onShow:function(){var e=this;e.timer=setInterval((function(){e.getLocation()}),1e4)},onHide:function(){console.log(this.timer,"定时器"),clearInterval(this.timer)},onBackPress:function(e){return console.log("监听返回按钮事件",this.timer),clearInterval(this.timer),!0},methods:{getData:function(){var e=this;this.$Request.get("/app/order/selectOrderById?orderId="+this.orderId).then((function(t){console.log(t),0==t.code&&(e.orderDetails=t.data,e.riderUserId=t.data.riderUserId,e.getLocation())}))},getLocation:function(){var e=this,t={riderUserId:this.riderUserId,lat:this.lat,lng:this.lng};this.$Request.getT("/timedtask/selectRiderLocation",t).then((function(t){if(0===t.code){e.latitude=t.data.riderLocation.lat,e.longitude=t.data.riderLocation.lng,e.rider=t.data,e.rider.mDateTime=t.data.mDateTime.split(" "),e.rider.aDouble>1e3?e.rider.aDouble=Number(e.rider.aDouble/1e3).toFixed(2)+"km":0==e.rider.aDouble?e.rider.aDouble="0m":e.rider.aDouble=Number(e.rider.aDouble).toFixed(1)+"m";var n={id:2,latitude:t.data.riderLocation.lat,longitude:t.data.riderLocation.lng,iconPath:"../../static/images/order/rider.png",width:"40",height:"40"};e.markers.push(n)}}))},call:function(){e.makePhoneCall({phoneNumber:this.orderDetails.riderPhone})},goNav:function(){e.navigateTo({url:"/my/setting/chat"})}}};t.default=n}).call(this,n(1)["default"])},188:function(e,t,n){"use strict";n.r(t);var r=n(189),i=n.n(r);for(var o in r)"default"!==o&&function(e){n.d(t,e,(function(){return r[e]}))}(o);t["default"]=i.a},189:function(e,t,n){}},[[182,"common/runtime","common/vendor"]]]);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/order/waimaiMap.js.map