Skip to content

Commit 5e17d07

Browse files
committed
Change default extent to Indonesia.
1 parent 33b14e7 commit 5e17d07

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

users/static/js/user-map.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -233,8 +233,6 @@ function editUser() {
233233
* @name map Global variable of the map.
234234
* @property openPopup Method of a popup to open it.
235235
* @property closePopup Method of a popup to close it.
236-
* @property fitWorld Method from the L.map.
237-
* @property zoomIn Method from fitWorld.
238236
*/
239237
function cancelEditUser() {
240238
// Set back the marker
@@ -247,8 +245,7 @@ function cancelEditUser() {
247245
edited_user_marker.bindPopup(edited_user_popup).openPopup();
248246
// Activate Default State
249247
activateDefaultState();
250-
// Fit map to world extent
251-
map.fitWorld().zoomIn();
248+
map.setView(new L.LatLng(-3, 120), 5);
252249
}
253250

254251
/**

users/templates/html/base.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,10 @@
6262

6363
//Create Map with prepared base_map
6464
map = L.map('map', {
65+
center: [-3, 120],
66+
zoom: 5,
6567
layers: [base_map]
6668
});
67-
map.fitWorld().zoomIn();
6869

6970
// Initialize all icons for marker
7071
var icons = createAllIcons(

0 commit comments

Comments
 (0)