Commit 6075f684 authored by Muhamad's avatar Muhamad

tooltip, managemen point

parent 0fe38c34
......@@ -1341,19 +1341,21 @@ mapss_p = L.tileLayer('https://mt1.google.com/vt/lyrs=m&x={x}&y={y}&z={z}&s=Gal&
minZoom: 4,
}).addTo(map_edit_p);
var mark_l = null
var mark_p = null
function modal_detail_point_pengaturan(id, db) {
$("#modal_detail_point_pengaturan").modal("show")
if (map_poin_det.hasLayer(marker)) {
marker.clearLayers()
marker.remove()
if (map_poin_det.hasLayer(mark_l)) {
// marker.clearLayers()
mark_l.remove()
}
if (map_edit_p.hasLayer(marker)) {
poinin.clearLayers()
poinin.remove()
if (map_edit_p.hasLayer(mark_p)) {
// poinin.clearLayers()
mark_p.remove()
}
$.ajax({
......@@ -1387,9 +1389,12 @@ function modal_detail_point_pengaturan(id, db) {
var marker = L.marker([data['result'][0][0]['geometry']['coordinates'][1], data['result'][0][0]['geometry']['coordinates'][0]]).addTo(map_poin_det);
map_poin_det.setView([data['result'][0][0]['geometry']['coordinates'][1], data['result'][0][0]['geometry']['coordinates'][0]], 17)
mark_l = marker
map_edit_p.setView([data['result'][0][0]['geometry']['coordinates'][1], data['result'][0][0]['geometry']['coordinates'][0]], 17);
let dapoin = [data['result'][0][0]['geometry']['coordinates'][1], data['result'][0][0]['geometry']['coordinates'][0]]
var poinin = L.marker(dapoin).addTo(map_edit_p)
mark_p = poinin
poinin.enableEdit();
$('#saveedit_p').click(function() {
var hasil = (JSON.stringify(poinin.toGeoJSON()))
......
......@@ -11150,6 +11150,16 @@ map.on("movestart", function() {
geo_bangunan.clearLayers();
});
let cookieLat =$.cookie("lat");
let cookieLng =$.cookie("lng");
let cookieZoom =$.cookie("zoom");
if(cookieLat){
console.log(cookieLat);
map.setView([cookieLat, cookieLng], cookieZoom)
// map_result.setView([data.polbang[0][0][0][1], data.polbang[0][0][0][0]], 17);
}
map.on("moveend", function() {
var wetan = map.getBounds().getEast();
var kulon = map.getBounds().getWest();
......@@ -11159,6 +11169,10 @@ map.on("moveend", function() {
var zoom = map.getZoom();
var dist = measure(wetan, lor, kulon, kidul)
$.cookie('lat', center.lat)
$.cookie('lng', center.lng)
$.cookie('zoom', zoom)
var checkBox_building = document.getElementById("geo_building");
if (checkBox_building.checked == true) {
......@@ -11841,3 +11855,18 @@ function getdetailperbang(id) {
}
});
};
function tooltipOver(x){
$(".label-tooltip").html(x)
$(".label-tooltip").css("visibility", "visible")
}
function tooltipOut(x){
$(".label-tooltip").css("visibility", "hidden")
// $(".label-tooltip").val(x.val())
}
\ No newline at end of file
......@@ -17,7 +17,9 @@ $('#search_spes li a').on('click', function() {
var res_in = null;
var res_id = null;
$('#input_search').on('input', function() {
var inp = $('#input_search').val()
console.log(inp)
$.ajax({
url: "api/search_spes",
......
......@@ -2313,7 +2313,7 @@
</div>
</div>
<div id="modal_detail_point_pengaturan" class="modal fade mymodal">
<div id="modal_detail_point_pengaturan" class="modal fade mymodal" style="z-index: 9999;">
<div class="modal-dialog modal-md" style="top: 10%;">
<div class="modal-content" style="border-radius:10px;">
<div class="modal-body" style="padding: 0px;">
......@@ -2427,7 +2427,7 @@
</div>
</div>
<div class="modal fade" id="modal_edit_p_point">
<div class="modal fade" id="modal_edit_p_point" style="z-index: 9999;">
<div class="modal-dialog md">
<div class="modal-content" style="border-radius:10px;">
<div class="modal-header bg-info" style=" border-top-left-radius: 10px;
......
......@@ -51,7 +51,7 @@
<img src="{% static 'img/maps/mapbox.PNG' %}" alt="" style="min-width: 180px; max-height: 130px;
min-height: 130px">
<span class="menu-heading">
World Imagery</span>
MapBox Light</span>
</a>
</ul>
</div>
......
......@@ -8,6 +8,14 @@
margin-top: 20px;
border-bottom: 0.5pt solid #313649;
}
.label-tooltip{
position: absolute;
color: white;
z-index: 999;
background-color: #1B1F2D;
visibility: hidden;
}
</style>
<!-- <div class="navbar navbar-inverse" style="z-index: 1;
......@@ -29,13 +37,13 @@ background: none;border-color: transparent;">
<ul class="navigation navigation-main navigation-accordion" style="margin-bottom: 40vh;">
<!-- Main -->
<li id="button_keterangan">
<li id="button_keterangan" onmouseover="tooltipOver('Keterangan & POI')" onmouseout="tooltipOut('')" value="Keterangan & POI">
<a href="#panel-sm" data-toggle="tab" aria-expanded="false" class="side-bar-but" id="keterangan_button">
<i class="icon-stack2"></i>
</a>
</li>
{% if user.is_authenticated %}
<li id="manage_perbaikan">
<li id="manage_perbaikan" onmouseover="tooltipOver('Managemen Perbaikan')" onmouseout="tooltipOut('')">
<a href="#panel-sm2" data-toggle="tab" aria-expanded="false" class="side-bar-but" id="perbaikan_manage">
<i class="icon-pie-chart5"></i>
</a>
......@@ -50,13 +58,13 @@ background: none;border-color: transparent;">
<ul class="navigation navigation-main navigation-accordion" style="height: 100px;">
<li>
<li onmouseover="tooltipOver('Help & Support')" onmouseout="tooltipOut('')">
<a href="#" class="side-bar-but" data-toggle="modal" data-target="#modal_help" data-backdrop="static" data-keyboard="false">
<img src="{% static 'img/icon-1/Vectoriconwarning.svg' %}" alt="" style="height: 17.875003814697266px;width: 17.875003814697266px;margin-left: -8px;">
</a>
</li>
{% if user.is_authenticated %}
<li>
<li onmouseover="tooltipOver('LOGOUT')" onmouseout="tooltipOut('')">
<a href="{% url 'logout' %}" class="side-bar-but">
<img src="{% static 'img/icon-1/Vectoriconlogout.svg' %}" alt="" style="height: 17.875003814697266px;width: 17.875003814697266px;margin-left: -8px;">
</a>
......@@ -74,6 +82,10 @@ background: none;border-color: transparent;">
</div>
</div>
<div class="label-tooltip">
ghjkl
</div>
<div id="panel-sm" class="sidebar-2" style="display:block; background: #1B1F2D; position: absolute; z-index: 9; width:330px; height:100vh; left: 0%; transition: all 0.5s ease;">
<div style="margin-left: 50px;background: #1B1F2D;">
......
......@@ -69,6 +69,10 @@
.invisible-marker {
display: none;
}
table{
font-size: 14px!important;
}
/* end hide fitur modal */
</style>
......@@ -148,6 +152,7 @@
<div id="progress-bar"></div>
</div>
<div id="map">
<div style="position: absolute;z-index: 999;bottom: 0px;left: 0px;background: white;font-size: 14px;"> Klik kanan untuk create Bangunan, Jalan, Point, dsb </div>
<div class="help_bangunan" style="position: absolute;z-index: 999;top: 0px;right: 60px;"></div>
<div class="row" style="margin-top: 20px;">
......@@ -462,6 +467,7 @@
var res_id = null;
$('#input_search').on('input', function() {
var inp = $('#input_search').val()
console.log(inp)
$.ajax({
url: "{% url 'api:search_spes' %}",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment