diff --git a/static/admin.html b/static/admin.html index 550a40c..f303f1f 100644 --- a/static/admin.html +++ b/static/admin.html @@ -83,7 +83,7 @@ socket = io({rejectUnauthorized: false, auth: {type:"Admin"}}); - setup_socket_common(); + setup_socket_common(-1); ////////////////////////////////////////////////////////////////////////////// // INTERACTION diff --git a/static/self_def.png b/static/self_def.png new file mode 100644 index 0000000..17db4b4 Binary files /dev/null and b/static/self_def.png differ diff --git a/static/self_green.png b/static/self_green.png new file mode 100644 index 0000000..dd63b0b Binary files /dev/null and b/static/self_green.png differ diff --git a/static/self_invi.png b/static/self_invi.png new file mode 100644 index 0000000..cca4764 Binary files /dev/null and b/static/self_invi.png differ diff --git a/static/self_orange.png b/static/self_orange.png new file mode 100644 index 0000000..e808a3d Binary files /dev/null and b/static/self_orange.png differ diff --git a/static/self_purple.png b/static/self_purple.png new file mode 100644 index 0000000..ab3843f Binary files /dev/null and b/static/self_purple.png differ diff --git a/static/self_track.png b/static/self_track.png new file mode 100644 index 0000000..8187087 Binary files /dev/null and b/static/self_track.png differ diff --git a/static/tracking/conscrit.html b/static/tracking/conscrit.html index 64d8127..a87c991 100644 --- a/static/tracking/conscrit.html +++ b/static/tracking/conscrit.html @@ -45,7 +45,7 @@ id = "%ID"; // %ID will be replaced by the real id. socket = io({rejectUnauthorized: false, auth: {id: id, type:"conscrit"}}); - setup_socket_common(); + setup_socket_common(id); ////////////////////////////////////////////////////////////////////////////// // SETTINGS -- CODE diff --git a/static/tracking/vieux.html b/static/tracking/vieux.html index 560e487..239ad16 100644 --- a/static/tracking/vieux.html +++ b/static/tracking/vieux.html @@ -65,7 +65,7 @@ id = "%ID"; // %ID will be replaced by the real id. socket = io({rejectUnauthorized: false, auth: {id: id, type:"vieux"}}); - setup_socket_common(); + setup_socket_common(id); ////////////////////////////////////////////////////////////////////////////// // SETTINGS -- State diff --git a/static/utils.js b/static/utils.js index da2ec2a..1cfbc15 100644 --- a/static/utils.js +++ b/static/utils.js @@ -13,6 +13,14 @@ var CircleIcon = L.Icon.extend({ } }); +var SelfIcon = L.Icon.extend({ + options: { + iconSize: [20, 30], + iconAnchor: [10, 15], + popupAnchor: [0, 0] + } +}); + var icons = [ new CircleIcon({ iconUrl: '/def.png' }), new CircleIcon({ iconUrl: '/track.png' }), @@ -22,6 +30,15 @@ var icons = [ new CircleIcon({ iconUrl: '/orange.png' }) ]; +var self_icons = [ + new SelfIcon({ iconUrl: '/self_def.png' }), + new SelfIcon({ iconUrl: '/self_track.png' }), + new SelfIcon({ iconUrl: '/self_invi.png' }), + new SelfIcon({ iconUrl: '/self_purple.png' }), + new SelfIcon({ iconUrl: '/self_green.png' }), + new SelfIcon({ iconUrl: '/self_orange.png' }) +]; + ////////////////////////////////////////////////////////////////////////////// // INIT MAP