25 changed files with 221 additions and 3666 deletions
-
1abonapp/admin.py
-
87abonapp/forms.py
-
29abonapp/models.py
-
4abonapp/urls_abon.py
-
58abonapp/views.py
-
2accounts_app/models.py
-
2agent/netflow/to_mysql.py
-
2djing/utils/load_dot_from_nodeny.py
-
2djing/utils/load_from_nodeny.py
-
2djing/utils/save_dot_from_nodeny.py
-
2djing/utils/save_from_nodeny.py
-
22static/css/custom.css
-
8static/js/bootstrap-datetimepicker.min.js
-
91static/js/gmap.js
-
3386static/js/moment-with-locales.min.js
-
29templates/abonapp/addAbon.html
-
2templates/abonapp/buy_tariff.html
-
72templates/abonapp/editAbon.html
-
44templates/abonapp/ext.htm
-
26templates/abonapp/peoples.html
-
2templates/accounts/ext.htm
-
2templates/accounts/settings/ext.htm
-
2templates/devapp/ext.htm
-
8templates/taskapp/add_edit_task.html
-
2templates/taskapp/ext.htm
8
static/js/bootstrap-datetimepicker.min.js
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -1,91 +0,0 @@ |
|||
function toggleCategory(category) { |
|||
$.each(gmap_markers, function (key, marker) { |
|||
if (marker.category == category) { |
|||
if (marker.getVisible() == true) { |
|||
marker.setVisible(false) |
|||
} else { |
|||
marker.setVisible(true) |
|||
} |
|||
} |
|||
}) |
|||
} |
|||
|
|||
function toggleTag(tag) { |
|||
$.each(gmap_markers, function (key, marker) { |
|||
$.each(marker.tags, function (key, this_tag) { |
|||
if (this_tag == tag) { |
|||
if (marker.getVisible() == true) { |
|||
marker.setVisible(false) |
|||
} else { |
|||
marker.setVisible(true) |
|||
} |
|||
} |
|||
}) |
|||
}) |
|||
} |
|||
|
|||
$(document).ready(function () { |
|||
|
|||
var myLatlng = new Array(); |
|||
var open_marker = ''; |
|||
|
|||
myLatlng[0] = new google.maps.LatLng(28.5000, -81.4500); |
|||
|
|||
var map = new google.maps.Map(document.getElementById("gmap_canvas"), { |
|||
zoom: 1, |
|||
center: myLatlng[0], |
|||
mapTypeId: google.maps.MapTypeId.ROADMAP |
|||
}); |
|||
|
|||
$.getJSON('/map/markers.json', function (data) { |
|||
var categories = new Array(); |
|||
var tags = new Array(); |
|||
var infowindow = new google.maps.InfoWindow({content: ''}) |
|||
gmap_markers = [] |
|||
$.each(data, function (key, item) { |
|||
var content = '<span class="name">' + item.fields.name + '</span><br/><span class="phone">' + item.fields.phone + '</span><br/><span class="email">' + item.fields.email + '</span><br/><span class="url">' + item.fields.url + '</span><br/>' |
|||
var latLng = new google.maps.LatLng(item.fields.latitude, item.fields.longitude) |
|||
var marker = new google.maps.Marker({ |
|||
position: latLng, |
|||
map: map, |
|||
title: item.fields.name, |
|||
category: item.fields.category, |
|||
tags: item.fields.sub_categories, |
|||
}) |
|||
google.maps.event.addListener(marker, "click", function () { |
|||
infowindow.content = content |
|||
infowindow.open(map, marker); |
|||
}); |
|||
gmap_markers.push(marker) |
|||
|
|||
if ($.inArray(item.fields.category, categories) == -1) { |
|||
categories.push(item.fields.category) |
|||
} |
|||
$.each(item.fields.sub_categories, function (key, item) { |
|||
if ($.inArray(item, tags) == -1) { |
|||
tags.push(item) |
|||
} |
|||
}) |
|||
}) |
|||
$.each(categories, function (key, category) { |
|||
var $button = $(' <a href="#category_' + category + '">' + category + '</a> ').bind('click', function () { |
|||
toggleCategory(category) |
|||
}) |
|||
$('#gmap_categories').append($button) |
|||
}) |
|||
|
|||
$.each(tags, function (key, tag) { |
|||
var $button = $(' <a href="#tag_' + tag + '">' + tag + '</a> ').bind('click', function () { |
|||
toggleTag(tag) |
|||
}) |
|||
$('#gmap_sub_categories').append($button) |
|||
}) |
|||
}) |
|||
google.maps.event.addListener(map, 'click', function () { |
|||
if (open_marker != '') { |
|||
open_marker.close(); |
|||
} |
|||
open_marker = ''; |
|||
}); |
|||
|
|||
}) |
|||
3386
static/js/moment-with-locales.min.js
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
Write
Preview
Loading…
Cancel
Save
Reference in new issue