fixed broken option reset filters
This commit is contained in:
@@ -2,12 +2,7 @@ function create_map(map_div) {
|
||||
// default map center to france
|
||||
let map_center = coordinates_default;
|
||||
// map_center = {lat:-2.515748362923059, lng:32.93366215464864};
|
||||
let world_bound = {
|
||||
north: 80,
|
||||
south: -80,
|
||||
west: -180,
|
||||
east: 180,
|
||||
};
|
||||
let world_bound = g_init_bounds;
|
||||
let map_options = {
|
||||
/* map options : https://developers.google.com/maps/documentation/javascript/reference/map#MapOptions */
|
||||
disableDefaultUI: true,
|
||||
|
||||
@@ -51,6 +51,6 @@ function filter_show_only_selection(indexes, show_only = true) {
|
||||
}
|
||||
|
||||
function filter_show_all() {
|
||||
console.log("filter_show_all");
|
||||
marker_cluster.addMarkers(markers);
|
||||
g_marker_cluster.addMarkers(g_markers);
|
||||
g_map.fitBounds(g_init_bounds);
|
||||
}
|
||||
|
||||
@@ -2,6 +2,12 @@
|
||||
let g_map = {};
|
||||
let g_markers = [];
|
||||
let g_marker_cluster = {};
|
||||
const g_init_bounds = {
|
||||
north: 80,
|
||||
south: -80,
|
||||
west: -180,
|
||||
east: 180,
|
||||
};
|
||||
|
||||
function mp_init_map() {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user