Skip to content

Commit

Permalink
change code for the search google
Browse files Browse the repository at this point in the history
  • Loading branch information
gtsarik committed Nov 23, 2017
1 parent a97dab6 commit e4ef75f
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/templates/customers/customer_section.html
Original file line number Diff line number Diff line change
Expand Up @@ -184,9 +184,9 @@ <h4 class="margin-bottom-30" id="aoi_selected"><b>AOI selected:</b> <span>{{ sub
<!-- <script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyApoguiUJyNLI5uy0zOqU9fSDfPgkZH3R0&signed_in=true"></script> -->

{% if tab_active != 'ts' %}
<script async defer src="https://maps.googleapis.com/maps/api/js?key=AIzaSyBbGl4HfSKF1pj1j1heEdUgn1SwSQaEaNc&callback=initMap" type="text/javascript"></script>
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyBbGl4HfSKF1pj1j1heEdUgn1SwSQaEaNc&callback=initMap" type="text/javascript" async defer></script>

<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyBbGl4HfSKF1pj1j1heEdUgn1SwSQaEaNc&libraries=places"></script>
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyBbGl4HfSKF1pj1j1heEdUgn1SwSQaEaNc&libraries=places" async defer></script>

<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?libraries=geometry"></script>

Expand Down Expand Up @@ -470,18 +470,18 @@ <h4 class="margin-bottom-30" id="aoi_selected"><b>AOI selected:</b> <span>{{ sub
map.controls[google.maps.ControlPosition.RIGHT_CENTER].push(myControl.getDiv());

// Create the search box and link it to the UI element.
var input = (document.getElementById('pac-input'));
var input = document.getElementById('pac-input');
var searchBox = new google.maps.places.SearchBox(input);
// map.controls[google.maps.ControlPosition.TOP_LEFT].push(input);

// map.getBounds(0);
console.log('INPUT: ', map.getBounds());

// Bias the SearchBox results towards current map's viewport.
// map.addListener('bounds_changed', function() {
// // alert('INPUT: ');
// searchBox.setBounds(map.getBounds());
// });
map.addListener('bounds_changed', function() {
// alert('INPUT: ');
searchBox.setBounds(map.getBounds());
});

var markers = [];
// Listen for the event fired when the user selects a prediction and retrieve
Expand Down

0 comments on commit e4ef75f

Please sign in to comment.