The map don't refresh data
Hi i have this code
<div id="map_canvas"> <ui-gmap-google-map ng-if="map.center" center="map.center" zoom="map.zoom" styles="map.styles"> <ui-gmap-marker coords="map.marker.coords" idkey="map.marker.id"></ui-gmap-marker> </ui-gmap-google-map> </div>
when i open the page it s ok sho the maps with the data i charge from json in this mode:
services.getMapsStyles($scope.data.group1).then(function (data) { $scope.map = data; });
but i have also the radio button when i check call the method for change the data:
<md-radio-group ng-model="data.group1" ng-change="getMapsStyles()"> <md-radio-button value="standard_map" class="md-primary"></md-radio-button> </md-radio-group>
Call this method
`$scope.getMapsStyles = function () {
services.getMapsStyles($scope.data.group1).then(function (data) {
$scope.map = data;
});
}`
the problem is the map dont change why? what i need to call for refresh the data?
Thanks Best Regards