title: how to place marker on angular google map by auto complete?
body: <p>I want to place marker on google-angular-map by auto complete search, I am getting location in form of latitude and longitude but marker is not adding, Please check it....</p>
  
  <p><strong>Controller code is</strong>  </p>
  
  <pre><code>$timeout(function() {
  
            var input = document.getElementById('pac-input');
            var searchBox = new google.maps.places.SearchBox(input);
  
            google.maps.event.addListener(searchBox, 'places_changed', function() {
               var marker= [] ;
               var places = searchBox.getPlaces();
  
               if (places.length == 0) {
                 return;
               }
  
              var loc_data = {            
  
                coords: {
                    latitude: places[0].geometry.location.lat(),
                    longitude: places[0].geometry.location.lng()
                }
              };
              marker.push(loc_data);
              $scope.markers=marker;              
            });
  </code></pre>
  
  <p>HTMl code is </p>
  
  <pre><code>    &lt;ui-gmap-markers models="markers" idkey="markers.id" coords="'coords'" &gt;
  
      &lt;/ui-gmap-markers&gt;
  
  &lt;div class="col-md-4"&gt;
  
      &lt;input id="pac-input" class="controls" type="text" placeholder="Search Box"&gt;
  &lt;/div&gt;
  </code></pre>