edit
This commit is contained in:
@ -57,11 +57,10 @@ export class AmapService {
|
|||||||
zoomToAccuracy: true //定位成功后是否自动调整地图视野到定位点
|
zoomToAccuracy: true //定位成功后是否自动调整地图视野到定位点
|
||||||
});
|
});
|
||||||
driving.getCurrentPosition((status: string, result: any) => {
|
driving.getCurrentPosition((status: string, result: any) => {
|
||||||
console.log(status,result);
|
|
||||||
|
|
||||||
if (status == 'complete') {
|
if (status == 'complete') {
|
||||||
this.currentSub.next(result);
|
this.currentSub.next(result);
|
||||||
} else {
|
} else {
|
||||||
|
console.log('定位获取失败');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user