"BMap"in window||alert("LBS 需要依赖 BaiduMap");var LBS=function(){this.process=function(t,e){(new BMap.Geolocation).getCurrentPosition(function(i){if(this.getStatus()==BMAP_STATUS_SUCCESS){var n=i.point;(new BMap.Geocoder).getLocation(n,function(e){var i=e.addressComponents,o={lng:n.lng,lat:n.lat},r={city:i.city,district:i.district,street:i.street,streetNumber:i.streetNumber};t&&t(o,r)})}else e&&e("定位失败")},{enableHighAccuracy:!0})}};module.exports=LBS;