我不知道,这段代码出了什么问题?
执行时,只返回一个搜索结果。
var map = new google.maps.Map(document.createElement('div'));
var request = {
query: 'Electronic City'
};
var service = new google.maps.places.PlacesService(map);
service.textSearch(request, function (results,status) {
$scope.RecievedData = results;
});
<script src="http://maps.googleapis.com/maps/api/js?libraries=places" ></script>