Silent 6 年之前
父节点
当前提交
eb5817bc5f
共有 1 个文件被更改,包括 3 次插入3 次删除
  1. 3 3
      resources/views/admin/base/locations/index.blade.php

+ 3 - 3
resources/views/admin/base/locations/index.blade.php

xqd xqd
@@ -73,7 +73,6 @@ $(function() {
                 console.log('ok');
                 var lat = position.coords.latitude;
                 var lng = position.coords.longitude;
-                console.log(lat, lng);
                 //调用地图命名空间中的转换接口   type的可选值为 1:GPS经纬度,2:搜狗经纬度,3:百度经纬度,4:mapbar经纬度,5:google经纬度,6:搜狗墨卡托
                 qq.maps.convertor.translate(new qq.maps.LatLng(lat, lng), 1, function(res){
                     //取出经纬度并且赋值
@@ -89,9 +88,10 @@ $(function() {
                         position : latlng
                     });
                 });
+            }, function (error) {
+                console.log('no');
             });
-        }
-        else {
+        } else {
             alert('浏览器不支持定位')
 		}
     });