449137bf by ex

获取定位

1 parent b124e651
......@@ -113,10 +113,17 @@ angular.module('myApp')
// return;
// }
$rootScope.openScan = false;
console.log(appClient)
if(appClient){
appClient.getERCode('getERCode', function (res) {
alert(JSON.parse(res))
}, '')
} else {
layer.open({
content: 'JSBridge 初始化失败',
time:2
});
}
// wx.scanQRCode({
// needResult: 1, // 默认为1,扫描结果由微信处理,1则直接返回扫描结果,
// scanType: ["qrCode","barCode"], // 可以指定扫二维码还是一维码,默认二者都有
......
......@@ -297,14 +297,17 @@ angular.module('myApp')
// onSuccess(res)
// }
// });
// appClient.getERCode('getGPS', function (res) {
// alert(JSON.parse(res))
// onSuccess({
// latitude:30.2741500000,
// longitude:120.1551500000
// })
//
// }, '')
if(appClient){
appClient.getERCode('getGPS', function (res) {
alert(JSON.parse(res))
onSuccess({
latitude:30.2741500000,
longitude:120.1551500000
})
}, '')
}
// onSuccess({latitude:30.2741500000,longitude:120.1551500000})
}
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!