Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OKU-GIS
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Muhamad
OKU-GIS
Commits
3a8f4735
Commit
3a8f4735
authored
Oct 08, 2021
by
Manggar Mahardhika
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix search, history bangunan, 3d
parent
b7b0b9a0
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
526 additions
and
597 deletions
+526
-597
templates/includes/js-m.html
templates/includes/js-m.html
+288
-234
templates/includes/modal.html
templates/includes/modal.html
+6
-2
templates/layout/layout.html
templates/layout/layout.html
+232
-361
No files found.
templates/includes/js-m.html
View file @
3a8f4735
...
@@ -625,9 +625,6 @@
...
@@ -625,9 +625,6 @@
</div>
</div>
</div>
</div>
<div>
<div>
<div>
<span>Perbaikan Terakhir</span>
</div>
<div>
<div>
<span>`
+
perbaikan_pt
+
`</span>
<span>`
+
perbaikan_pt
+
`</span>
</div>
</div>
...
@@ -7096,43 +7093,77 @@
...
@@ -7096,43 +7093,77 @@
};
};
history
=
`
history
=
`
<div>
<div style="margin-top: 150px;">
<span>Perbaikan Terakhir</span>
<span>
<a id='btn_detail_per_bang' onclick="getdetailperbang(`
+
feature
.
properties
.
f1
+
`)" data-toggle="modal" data-target="#modal_detail" style = "text-align:right; margin-right:26px;"><i>Detail</i></a>
</span>
</div>
<div>
<span>
<tr style="height: 40px;">
<tr style="height: 40px;">
<th id="history_panel">
<th id="history_panel">
<p class="text-center">
<div class="form-group" style="margin-bottom:0px;">
<img src="static/img/icon/samping_history.svg" alt="Image" style="height: 20px; width: 20px;">
<div class="row">
</p>
<label class="col-md-6">`
+
list_history
[
0
].
split
(
"
,
"
)[
1
]
+
`</label>
<p class="text-center">
<label class="col-md-6">`
+
list_history
[
0
].
split
(
"
,
"
)[
2
]
+
`</label>
<b>History Perbaikan</b>
</div>
</p>
</div>
<br>
<p class="text-center" style="margin-top: 5px;">
<label class="col-md-6"><b>Tanggal</b></label>
<a class="btn" id="btn_perbaikan_bangunan" data-toggle="modal" data-target="#input_perbaikan_bang"><i>Input Perbaikan</i></a>
<label class="col-md-6"><b>Jenis Perbaikan</b></label>
`
+
list_history_panel
+
`
<p class="text-center" style="margin-top: 15px;">
<a id='btn_detail_per_bang' onclick="getdetailperbang(`
+
feature
.
properties
.
f1
+
`)" data-toggle="modal" data-target="#modal_detail" class="btn btn-primary" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-list-ul" style="color:#ffffff"> </i><i style="margin-left: 5px;">View Detail</i></a>
<a href="#" id='btn_perbaikan_bangunan' data-toggle="modal" data-target="#input_perbaikan_bang" data-backdrop="static" data-keyboard="false" class="btn btn-primary" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-plus" style="color:#ffffff"> </i><i style="margin-left: 5px;">Tambah History Perbaikan</i></a>
</p>
</p>
</th>
</th>
</tr>`
;
</tr>
</span>
</div>
</div>
`
;
}
else
{
}
else
{
history
=
`
history
=
`
<div>
<div style="margin-top: 150px;">
<span>Perbaikan Terakhir</span>
</div>
<div>
<span>
<tr style="height: 40px;">
<tr style="height: 40px;">
<th id="history_panel">
<th id="history_panel">
<p class="text-center">
History Perbaikan
</p>
<br>
<p class="text-center" style="margin-top: 10px;"><i>Belum Ada History</i></p>
<p class="text-center" style="margin-top: 10px;"><i>Belum Ada History</i></p>
<p class="text-center" style="margin-top: 10px;">
<p class="text-center" style="margin-top: 10px;">
<a href="#" id='btn_perbaikan_bangunan' data-toggle="modal" data-target="#input_perbaikan_bang" data-backdrop="static" data-keyboard="false" class="btn btn-primary" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-plus" style="color:#ffffff"> </i><i style="margin-left: 5px;">Tambah History
Perbaikan</i></a>
<a class="btn" id="btn_perbaikan_bangunan" data-toggle="modal" data-target="#input_perbaikan_bang"><i>Input
Perbaikan</i></a>
</p>
</p>
</th>
</th>
</tr>`
;
</tr>
</span>
</div>
</div>
`
;
}
}
}
else
{
}
else
{
history
=
``
history
=
``
}
}
// if (feature.properties.f4 != null) {
// var list_history = feature.properties.f4
// console.log(list_history[0].split(",")[0])
// var perbaikan_bg = `
//
<
div
class
=
'
row
'
>
//
<
label
class
=
"
col-md-8
"
>
` + list_history[0].split(",")[1] + `
<
/label
>
//
<
a
class
=
"
col-md-4
"
onclick
=
"
getdetailper(` + list_history[0].split(
"
,
"
)[0] + `)
"
data
-
toggle
=
"
modal
"
data
-
target
=
"
#input_perbaikan_bang
"
><
i
>
Detail
<
/i></
a
>
//
<
/div
>
//
<
a
class
=
"
btn
"
id
=
"
btn_perbaikan_bangunan
"
data
-
toggle
=
"
modal
"
data
-
target
=
"
#input_perbaikan_bang
"
><
i
>
Input
Perbaikan
<
/i></
a
>
`
// } else {
// var perbaikan_bg = `
<
div
class
=
'
row
'
>
//
<
div
class
=
"
col-md-6
"
>
//
<
label
class
=
"
col-md-6
"
>-<
/label
>
//
<
/div
>
//
<
/div
>
//
<
a
class
=
"
btn
"
id
=
"
btn_perbaikan_bangunan
"
data
-
toggle
=
"
modal
"
data
-
target
=
"
#input_perbaikan_bang
"
><
i
>
Input
Perbaikan
<
/i></
a
>
// `
// }
content_edit
=
`
content_edit
=
`
<div class="modal-dialog" style="width: max-content;height: max-content;">
<div class="modal-dialog" style="width: max-content;height: max-content;">
<div class="modal-content">
<div class="modal-content">
...
@@ -7326,7 +7357,7 @@
...
@@ -7326,7 +7357,7 @@
<div class="tab-content">
<div class="tab-content">
<div class="tab-pane active" id="left-tab1-feas-upl">
<div class="tab-pane active" id="left-tab1-feas-upl">
<input type="text" class="hidden" id="poly_create_input_bang">
<input type="text" class="hidden" id="poly_create_input_bang">
<input type="text" class="hidden" id="id_bang_perbaikan"
>
<input type="text" class="hidden" id="id_bang_perbaikan" value="`
+
feature
.
properties
.
f1
+
`" disable
>
<input type="text" class="hidden" id="type_id_bang">
<input type="text" class="hidden" id="type_id_bang">
<div id="map-insert-renov-bang" style="height: 375px;width: 100%">
<div id="map-insert-renov-bang" style="height: 375px;width: 100%">
</div>
</div>
...
@@ -7413,29 +7444,91 @@
...
@@ -7413,29 +7444,91 @@
</div>
</div>
</div>`
;
</div>`
;
content
=
`
if
(
feature
.
properties
.
f4
!=
null
)
{
<table class="table tasks-list">
var
list_history
=
feature
.
properties
.
f4
<thead style="text-align: center;">
console
.
log
(
list_history
[
0
].
split
(
"
,
"
)[
0
])
<tr>
var
perbaikan_bg
=
`<div class='row'>
<th style="padding: 0 0 0 0px;">
<img src=`
+
path_img
+
` alt="Image" style="width: 100%;max-height: 368px;height:368">
<label class="col-md-8">`
+
list_history
[
0
].
split
(
"
,
"
)[
1
]
+
`</label>
</th>
</tr>
</thead>
<a class="col-md-4" onclick="getdetailper(`
+
list_history
[
0
].
split
(
"
,
"
)[
0
]
+
`)" data-toggle="modal" data-target="#input_perbaikan_bang"><i>Detail</i></a>
<tbody>
<div class= "container">
<tr style="height: 100px;">
<th>
<div>
<h1 style="font-family: Google Sans,Roboto,Arial,sans-serif;
letter-spacing: 0;
font-weight: 400;">
<span style="font-size: x-large;">
`
+
feature
.
properties
.
f2
+
`
</span>
</h1>
</div>
</div>
<a class="col-md-6" class="btn" id="btn_perbaikan_jalan"><i>Input Perbaikan</i></a>`
</th>
</tr>
}
else
{
var
perbaikan_bg
=
`<div class='row'>
<div class="col-md-6">
<label class="col-md-6">Null</label>
</div>
</div>
<div class= "container">
<tr style="height: 30px;">
<th>
<span>
`
+
feature
.
administrasi
.
f12
+
`
</span>
</th>
</tr>
</div>
</div>
<a class="btn" id="btn_perbaikan_hist" data-toggle="modal" data-target="#input_perbaikan_bang"><i>Input Perbaikan</i></a>
<div class= "container">
`
<tr style="height: 40px;">
}
<th>
<p style="text-align:center;">
<img src="static/img/icon/samping_location.svg" alt="Image" style="height: 30px; width: 30px;">
</p>
<p>
<span>
`
+
alamat
+
feature
.
administrasi
.
f1
+
`, `
+
feature
.
administrasi
.
f2
+
`, `
+
feature
.
administrasi
.
f3
+
`, `
+
feature
.
administrasi
.
f4
+
`
</span>
</p>
</th>
</tr>
</div>
<div class= "container">
<tr style="height: 40px;">
<th>
<p style="text-align:center;">
<img src="static/img/icon/samping_informasi.svg" alt="Image" style="height: 30px; width: 30px;">
</p>
<p>
<span>Luas Bangunan : `
+
feature
.
administrasi
.
f6
+
`</span>
</p>
<p>
<span>Luas Tanah : `
+
feature
.
administrasi
.
f7
+
`</span>
</p>
<p>
<span>Tinggi Bangunan : `
+
feature
.
administrasi
.
f8
+
`</span>
</p>
<p>
<span>Pemilik : `
+
feature
.
administrasi
.
f10
+
`</span>
</p>
</th>
</tr>
</div>
<div class= "container">
<tr style="height: 40px;">
<th>
<p class="text-center" style="margin-top: 5px;">
<a href="#" class="btn btn-primary" data-toggle="modal" data-target="#modal_bangunan_edit" id="btn_edit_bangunan" data-backdrop="static" data-keyboard="false" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-edit" style="color:#ffffff"> </i><i style="margin-left: 5px;">Edit Informasi Bangunan</i></a>
<a href="#" id='btn_delete_bangunan' class='btn
btn-primary btn_edit_bangunan' data-toggle="modal" data-target="#modal_bangunan_delete" data-backdrop="static" data-keyboard="false" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-trash" style="color:#ffffff"> </i><i style="margin-left: 5px;">Delete Bangunan</i></a>
</p>
</th>
</tr>
</div>
<div class="container">
`
+
history
+
`
</div>
</tbody>
</table>`
;
$
(
"
.gambar_keterangan
"
).
html
(
`<img src="`
+
path_img
+
`" alt="" style="width:100%;height:240px;border-top-left-radius: 10px;border-bottom-left-radius: 10px;">`
)
$
(
"
.gambar_keterangan
"
).
html
(
`<img src="`
+
path_img
+
`" alt="" style="width:100%;height:240px;border-top-left-radius: 10px;border-bottom-left-radius: 10px;">`
)
...
@@ -7457,60 +7550,49 @@
...
@@ -7457,60 +7550,49 @@
<div class="col-md-6">
<div class="col-md-6">
<div>
<div>
<div>
<div>
<span>Jenis Bangunan</span>
<span
style="font-family: 'gilroylight';"
>Jenis Bangunan</span>
</div>
</div>
<div>
<div>
<span>
<span style="font-family: 'gilroysemibold';">`
+
feature
.
administrasi
.
f12
+
`</span>
`
+
feature
.
administrasi
.
f12
+
`
</span>
</div>
</div>
</div>
</div>
<div>
<div>
<div>
<div
style="margin-top:5px;"
>
<span>Luas Bangunan</span>
<span
style="font-family: 'gilroylight';"
>Luas Bangunan</span>
</div>
</div>
<div>
<div>
<span style="font-family: '
Roboto
';">`
+
feature
.
administrasi
.
f6
+
` m</span>
<span style="font-family: '
gilroysemibold
';">`
+
feature
.
administrasi
.
f6
+
` m</span>
</div>
</div>
</div>
</div>
<div>
<div>
<div>
<div>
<span>Luas Tanah</span>
<span
style="font-family: 'gilroylight';"
>Luas Tanah</span>
</div>
</div>
<div>
<div>
<span style="font-family: '
Roboto
';">`
+
feature
.
administrasi
.
f7
+
` m</span>
<span style="font-family: '
gilroysemibold
';">`
+
feature
.
administrasi
.
f7
+
` m</span>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="col-md-6">
<div class="col-md-6">
<div>
<div>
<div>
<div>
<span>Tinggi Bangunan</span>
<span
style="font-family: 'gilroylight';"
>Tinggi Bangunan</span>
</div>
</div>
<div>
<div>
<span style="font-family: '
Roboto
';">`
+
feature
.
administrasi
.
f8
+
` m</span>
<span style="font-family: '
gilroysemibold
';">`
+
feature
.
administrasi
.
f8
+
` m</span>
</div>
</div>
</div>
</div>
<div>
<div>
<div>
<div
style="margin-top:5px;"
>
<span>Pemilik</span>
<span
style="font-family: 'gilroylight';"
>Pemilik</span>
</div>
</div>
<div>
<div>
<span style="font-family: 'Roboto';">`
+
feature
.
administrasi
.
f10
+
` m</span>
<span style="font-family: 'gilroysemibold';">`
+
feature
.
administrasi
.
f10
+
` m</span>
</div>
</div>
</div>
</div>
<div>
<div style="margin-top: 150px;">
<span>Perbaikan Terakhir</span>
</div>
<div>
<span>`
+
perbaikan_bg
+
`</span>
</div>
</div>
</div>
</div>
`
+
history
+
`
`
);
`
);
$
(
"
.btn_action
"
).
html
(
`<div class="tombol-edit-keterangan text-center" style="background-color: #5A9AFB;position: absolute;width: 40px;height: 40px;bottom: 2px;right: 5px;border: 1pt solid rosybrown;border-radius: 8px;">
$
(
"
.btn_action
"
).
html
(
`<div class="tombol-edit-keterangan text-center" style="background-color: #5A9AFB;position: absolute;width: 40px;height: 40px;bottom: 2px;right: 5px;border: 1pt solid rosybrown;border-radius: 8px;">
...
@@ -7522,12 +7604,7 @@
...
@@ -7522,12 +7604,7 @@
`
)
`
)
$
(
"
#isi_panel
"
).
html
(
content
);
$
(
"
#modal_bangunan_edit
"
).
html
(
content_edit
);
$
(
"
#modal_bangunan_edit
"
).
html
(
content_edit
);
$
(
"
#modal_bangunan_delete
"
).
html
(
content_delete
);
$
(
"
#modal_bangunan_delete
"
).
html
(
content_delete
);
$
(
"
#input_perbaikan_bang
"
).
html
(
content_inp_his_bang
);
$
(
"
#input_perbaikan_bang
"
).
html
(
content_inp_his_bang
);
...
@@ -7595,9 +7672,6 @@
...
@@ -7595,9 +7672,6 @@
geo_bangunan
.
addData
(
data
)
geo_bangunan
.
addData
(
data
)
}
}
var
checkBox_building
=
document
.
getElementById
(
"
geo_building
"
);
map
.
on
(
"
movestart
"
,
function
()
{
map
.
on
(
"
movestart
"
,
function
()
{
geo_bangunan
.
clearLayers
();
geo_bangunan
.
clearLayers
();
});
});
...
@@ -7610,6 +7684,8 @@
...
@@ -7610,6 +7684,8 @@
var
center
=
map
.
getBounds
().
getCenter
();
var
center
=
map
.
getBounds
().
getCenter
();
var
zoom
=
map
.
getZoom
();
var
zoom
=
map
.
getZoom
();
var
checkBox_building
=
document
.
getElementById
(
"
geo_building
"
);
if
(
checkBox_building
.
checked
==
true
)
{
if
(
checkBox_building
.
checked
==
true
)
{
if
(
zoom
>
17
)
{
if
(
zoom
>
17
)
{
...
@@ -7944,8 +8020,10 @@
...
@@ -7944,8 +8020,10 @@
});
});
$
(
document
).
on
(
"
click
"
,
"
#btn_perbaikan_bangunan
"
,
function
()
{
// $("#input_perbaikan_bang-s").css("display", "block");
var
map_bang
=
new
L
.
map
(
'
map-insert-renov-bang
'
,
{
var
map_bang
=
new
L
.
map
(
'
map-insert-renov-bang
'
,
{
editable
:
tru
e
,
editable
:
fals
e
,
zoomControl
:
false
,
zoomControl
:
false
,
drawControl
:
true
drawControl
:
true
}).
setView
([
-
2
,
118
],
5
);
}).
setView
([
-
2
,
118
],
5
);
...
@@ -7955,42 +8033,13 @@
...
@@ -7955,42 +8033,13 @@
minZoom
:
4
,
minZoom
:
4
,
}).
addTo
(
map_bang
);
}).
addTo
(
map_bang
);
var
polyxxx
=
L
.
polygon
([
// if (map_bang.hasLayer(polyxxx)) {
[
-
4.1283969
,
104.1674575
],
// polyxxx.remove()
[
-
4.128396
,
104.1674947
],
[
-
4.1284664
,
104.1674964
],
[
-
4.1284674
,
104.1674593
],
[
-
4.1283969
,
104.1674575
]
]).
addTo
(
map_bang
)
// var geo_bangunan_input = L.geoJson(null, {
// style: function(feature) {
// return {
// color: "#06FF08",
// weight: 8,
// opacity: 2,
// zIndex: 1000
// };
// }
// }
// }).addTo(map_bang);
$
(
document
).
on
(
"
click
"
,
"
#btn_perbaikan_bangunan
"
,
function
()
{
var
map_bang
=
new
L
.
map
(
'
map-insert-renov-bang
'
,
{
editable
:
true
,
zoomControl
:
false
,
drawControl
:
true
}).
setView
([
-
2
,
118
],
5
);
mapssx
=
L
.
tileLayer
(
'
https://mt1.google.com/vt/lyrs=s&x={x}&y={y}&z={z}
'
,
{
var
id_polyx
=
$
(
'
#id_bang_perbaikan
'
).
val
();
maxZoom
:
22
,
minZoom
:
4
,
}).
addTo
(
map_bang
);
$
(
"
#input_perbaikan_bang
"
).
css
(
"
display
"
,
"
block
"
);
loaderPage
(
true
);
if
(
map_bang
.
hasLayer
(
polyxxx
))
{
polyxxx
.
remove
()
}
var
id_polyx
=
$
(
'
#idbangunan
'
).
val
();
$
.
ajax
({
$
.
ajax
({
url
:
"
{% url 'apps:input-perbaikan-bang' %}
"
,
url
:
"
{% url 'apps:input-perbaikan-bang' %}
"
,
...
@@ -7999,7 +8048,12 @@
...
@@ -7999,7 +8048,12 @@
},
},
dataType
:
'
json
'
,
dataType
:
'
json
'
,
success
:
function
(
data
)
{
success
:
function
(
data
)
{
console
.
log
(
data
)
setTimeout
(
function
()
{
map_bang
.
invalidateSize
();
},
1000
);
loaderPage
(
false
);
$
(
"
#nama_bang
"
).
val
(
data
[
0
]);
$
(
"
#nama_bang
"
).
val
(
data
[
0
]);
$
(
"
#type_bang
"
).
val
(
data
[
4
]);
$
(
"
#type_bang
"
).
val
(
data
[
4
]);
$
(
"
#id_bang_perbaikan
"
).
val
(
data
[
3
]);
$
(
"
#id_bang_perbaikan
"
).
val
(
data
[
3
]);
...
@@ -8008,7 +8062,7 @@
...
@@ -8008,7 +8062,7 @@
$
(
"
#kecamatan_bang
"
).
val
(
data
[
6
]);
$
(
"
#kecamatan_bang
"
).
val
(
data
[
6
]);
var
latlngs
=
data
[
2
];
var
latlngs
=
data
[
2
];
console
.
log
(
data
[
2
])
var
lattitud
,
longitud
;
var
lattitud
,
longitud
;
map_bang
.
setView
([
data
[
2
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
1
],
data
[
2
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
0
]],
19
);
map_bang
.
setView
([
data
[
2
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
1
],
data
[
2
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
0
]],
19
);
...
@@ -8029,7 +8083,7 @@
...
@@ -8029,7 +8083,7 @@
})
})
}
}
})
})
})
})
;
$
(
document
).
on
(
"
click
"
,
"
#save-perbaikan_bang
"
,
function
(
e
)
{
$
(
document
).
on
(
"
click
"
,
"
#save-perbaikan_bang
"
,
function
(
e
)
{
var
polyginbang
=
$
(
'
#coorbangbaru
'
).
val
();
var
polyginbang
=
$
(
'
#coorbangbaru
'
).
val
();
...
@@ -8043,7 +8097,7 @@
...
@@ -8043,7 +8097,7 @@
var
anggaran
=
$
(
"
#anggaran_bang
"
).
val
();
var
anggaran
=
$
(
"
#anggaran_bang
"
).
val
();
var
proposal
=
$
(
"
#proposal_bang
"
).
val
();
var
proposal
=
$
(
"
#proposal_bang
"
).
val
();
var
bukti_selesai
=
$
(
"
#buktiselesai_bang
"
).
val
();
var
bukti_selesai
=
$
(
"
#buktiselesai_bang
"
).
val
();
console
.
log
(
bukti_selesai
)
var
pj
=
$
(
"
#pihakpengesahan_bang
"
).
val
();
var
pj
=
$
(
"
#pihakpengesahan_bang
"
).
val
();
var
pj_lapangan
=
$
(
"
#pjlapangan_bang
"
).
val
();
var
pj_lapangan
=
$
(
"
#pjlapangan_bang
"
).
val
();
var
kontraktor
=
$
(
"
#kontraktor_bang
"
).
val
();
var
kontraktor
=
$
(
"
#kontraktor_bang
"
).
val
();
...
...
templates/includes/modal.html
View file @
3a8f4735
...
@@ -268,6 +268,10 @@
...
@@ -268,6 +268,10 @@
</div>
</div>
<div
id=
"input_perbaikan_bang-s"
class=
"modal fade"
>
</div>
<!-- modal tuplah -->
<!-- modal tuplah -->
<div
id=
"modal-edit-tuplah"
class=
"modal fade"
>
<div
id=
"modal-edit-tuplah"
class=
"modal fade"
>
<div
class=
"modal-dialog"
style=
"width: max-content;height: max-content;"
>
<div
class=
"modal-dialog"
style=
"width: max-content;height: max-content;"
>
...
@@ -324,8 +328,8 @@
...
@@ -324,8 +328,8 @@
<div
class=
"modal-dialog modal-xs"
>
<div
class=
"modal-dialog modal-xs"
>
<div
class=
"modal-content"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<button
type=
"button"
class=
"close"
style=
"color: white;"
data-dismiss=
"modal"
aria-hidden=
"true"
>
×
</button>
<h4
class=
"modal-title"
>
3D Searching
</h4>
<h4
class=
"modal-title"
style=
"color: white;"
>
3D Searching
</h4>
</div>
</div>
<div
class=
"modal-body"
>
<div
class=
"modal-body"
>
<fieldset>
<fieldset>
...
...
templates/layout/layout.html
View file @
3a8f4735
...
@@ -542,61 +542,7 @@
...
@@ -542,61 +542,7 @@
//
<
option
value
=
"
cagar_budaya
"
>
Cagar
Budaya
dan
Tempat
Wisata
<
/option
>
//
<
option
value
=
"
cagar_budaya
"
>
Cagar
Budaya
dan
Tempat
Wisata
<
/option
>
//
<
option
value
=
"
gardu_listrik
"
>
Gardu
Listrik
<
/option>
`
//
<
option
value
=
"
gardu_listrik
"
>
Gardu
Listrik
<
/option>
`
// }
// }
var
history
if
(
feature
.
administrasi
.
f11
==
'
kantor_administrasi
'
||
feature
.
administrasi
.
f11
==
'
layanan_kesehatan
'
||
feature
.
administrasi
.
f11
==
'
puskesmas
'
||
feature
.
administrasi
.
f11
==
'
rumah_sakit
'
||
feature
.
administrasi
.
f11
==
'
sarana_pendidikan
'
||
feature
.
administrasi
.
f11
==
'
stasiun
'
||
feature
.
administrasi
.
f11
==
'
terminal_bus
'
||
feature
.
administrasi
.
f11
==
'
cagar_budaya
'
||
feature
.
administrasi
.
f11
==
'
gardu_listrik
'
)
{
if
(
feature
.
properties
.
f4
!=
null
)
{
var
list_history
=
feature
.
properties
.
f4
var
list_history_panel
=
``
for
(
var
i
=
0
;
i
<
list_history
.
length
;
i
++
)
{
var
dt_history
=
list_history
[
i
].
split
(
"
,
"
);
var
data_history
=
`<div class="form-group" style="margin-bottom:0px;">
<div class="row">
<label class="col-md-6">`
+
dt_history
[
1
]
+
`</label>
<label class="col-md-6">`
+
dt_history
[
2
]
+
`</label>
</div>
</div>`
;
list_history_panel
+=
data_history
};
history
=
`
<tr style="height: 40px;">
<th id="history_panel">
<p class="text-center">
<img src="static/img/icon/samping_history.svg" alt="Image" style="height: 20px; width: 20px;">
</p>
<p class="text-center">
<b>History Perbaikan</b>
</p>
<br>
<label class="col-md-6"><b>Tanggal</b></label>
<label class="col-md-6"><b>Jenis Perbaikan</b></label>
`
+
list_history_panel
+
`
<p class="text-center" style="margin-top: 15px;">
<a id='btn_detail_per_bang' onclick="getdetailperbang(`
+
feature
.
properties
.
f1
+
`)" data-toggle="modal" data-target="#modal_detail" class="btn btn-primary" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-list-ul" style="color:#ffffff"> </i><i style="margin-left: 5px;">View Detail</i></a>
<a href="#" id='btn_perbaikan_bangunan' data-toggle="modal" data-target="#input_perbaikan_bang" data-backdrop="static" data-keyboard="false" class="btn btn-primary" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-plus" style="color:#ffffff"> </i><i style="margin-left: 5px;">Tambah History Perbaikan</i></a>
</p>
</th>
</tr>`
;
}
else
{
history
=
`
<tr style="height: 40px;">
<th id="history_panel">
<p class="text-center">
History Perbaikan
</p>
<br>
<p class="text-center" style="margin-top: 10px;"><i>Belum Ada History</i></p>
<p class="text-center" style="margin-top: 10px;">
<a href="#" id='btn_perbaikan_bangunan' data-toggle="modal" data-target="#input_perbaikan_bang" data-backdrop="static" data-keyboard="false" class="btn btn-primary" style="border-radius: 200px; margin-bottom: 5px;"><i class="fa fa-plus" style="color:#ffffff"> </i><i style="margin-left: 5px;">Tambah History Perbaikan</i></a>
</p>
</th>
</tr>`
;
}
}
else
{
history
=
``
}
content_edit
=
`
content_edit
=
`
<div class="modal-dialog" style="width: max-content;height: max-content;">
<div class="modal-dialog" style="width: max-content;height: max-content;">
...
@@ -791,9 +737,9 @@
...
@@ -791,9 +737,9 @@
<div class="tab-content">
<div class="tab-content">
<div class="tab-pane active" id="left-tab1-feas-upl">
<div class="tab-pane active" id="left-tab1-feas-upl">
<input type="text" class="hidden" id="poly_create_input_bang">
<input type="text" class="hidden" id="poly_create_input_bang">
<input type="text" class="hidden" id="id_bang_perbaikan">
<input type="text" class="hidden" id="id_bang_perbaikan"
value="`
+
feature
.
properties
.
f1
+
`" disable
>
<input type="text" class="hidden" id="type_id_bang">
<input type="text" class="hidden" id="type_id_bang">
<div id="map-insert-renov-bang" style="height: 375px;width: 100%">
<div id="map-insert-renov-bang
-s
" style="height: 375px;width: 100%">
</div>
</div>
</div>
</div>
...
@@ -877,160 +823,75 @@
...
@@ -877,160 +823,75 @@
</div>
</div>
</div>
</div>
</div>`
;
</div>`
;
// content = `
var
history
//
<
table
class
=
"
table tasks-list
"
>
if
(
feature
.
administrasi
.
f11
==
'
kantor_administrasi
'
||
feature
.
administrasi
.
f11
==
'
layanan_kesehatan
'
||
feature
.
administrasi
.
f11
==
'
puskesmas
'
||
//
<
thead
style
=
"
text-align: center;
"
>
feature
.
administrasi
.
f11
==
'
rumah_sakit
'
||
feature
.
administrasi
.
f11
==
'
sarana_pendidikan
'
||
feature
.
administrasi
.
f11
==
'
stasiun
'
||
//
<
tr
>
feature
.
administrasi
.
f11
==
'
terminal_bus
'
||
feature
.
administrasi
.
f11
==
'
cagar_budaya
'
||
feature
.
administrasi
.
f11
==
'
gardu_listrik
'
)
{
//
<
th
style
=
"
padding: 0 0 0 0px;
"
>
if
(
feature
.
properties
.
f4
!=
null
)
{
//
<
img
src
=
` + path_img + `
alt
=
"
Image
"
style
=
"
width: 100%;max-height: 368px;height:368
"
>
var
list_history
=
feature
.
properties
.
f4
//
<
/th
>
var
list_history_panel
=
``
//
<
/tr
>
for
(
var
i
=
0
;
i
<
list_history
.
length
;
i
++
)
{
//
<
/thead
>
var
dt_history
=
list_history
[
i
].
split
(
"
,
"
);
//
<
tbody
>
var
data_history
=
`<div class="form-group" style="margin-bottom:0px;">
//
<
div
class
=
"
container
"
>
<div class="row">
//
<
tr
style
=
"
height: 100px;
"
>
<label class="col-md-6">`
+
dt_history
[
1
]
+
`</label>
//
<
th
>
<label class="col-md-6">`
+
dt_history
[
2
]
+
`</label>
//
<
div
>
//
<
h1
style
=
"
font-family: Google Sans,Roboto,Arial,sans-serif;
// letter-spacing: 0;
// font-weight: 400;
"
>
//
<
span
style
=
"
font-size: x-large;
"
>
// ` + feature.properties.f2 + `
//
<
/span
>
//
<
/h1
>
//
<
/div
>
//
<
/th
>
//
<
/tr
>
//
<
/div
>
//
<
div
class
=
"
container
"
>
//
<
tr
style
=
"
height: 30px;
"
>
//
<
th
>
//
<
span
>
// ` + feature.administrasi.f12 + `
//
<
/span
>
//
<
/th
>
//
<
/tr
>
//
<
/div
>
//
<
div
class
=
"
container
"
>
//
<
tr
style
=
"
height: 40px;
"
>
//
<
th
>
//
<
p
style
=
"
text-align:center;
"
>
//
<
img
src
=
"
static/img/icon/samping_location.svg
"
alt
=
"
Image
"
style
=
"
height: 30px; width: 30px;
"
>
//
<
/p
>
//
<
p
>
//
<
span
>
// ` + alamat + feature.administrasi.f1 + `, ` + feature.administrasi.f2 + `, ` + feature.administrasi.f3 + `, ` + feature.administrasi.f4 + `
//
<
/span
>
//
<
/p
>
//
<
/th
>
//
<
/tr
>
//
<
/div
>
//
<
div
class
=
"
container
"
>
//
<
tr
style
=
"
height: 40px;
"
>
//
<
th
>
//
<
p
style
=
"
text-align:center;
"
>
//
<
img
src
=
"
static/img/icon/samping_informasi.svg
"
alt
=
"
Image
"
style
=
"
height: 30px; width: 30px;
"
>
//
<
/p
>
//
<
p
>
//
<
span
>
Luas
Bangunan
:
` + feature.administrasi.f6 + `
<
/span
>
//
<
/p
>
//
<
p
>
//
<
span
>
Luas
Tanah
:
` + feature.administrasi.f7 + `
<
/span
>
//
<
/p
>
//
<
p
>
//
<
span
>
Tinggi
Bangunan
:
` + feature.administrasi.f8 + `
<
/span
>
//
<
/p
>
//
<
p
>
//
<
span
>
Pemilik
:
` + feature.administrasi.f10 + `
<
/span
>
//
<
/p
>
//
<
/th
>
//
<
/tr
>
//
<
/div
>
//
<
div
class
=
"
container
"
>
//
<
tr
style
=
"
height: 40px;
"
>
//
<
th
>
//
<
p
class
=
"
text-center
"
style
=
"
margin-top: 5px;
"
>
//
<
a
href
=
"
#
"
class
=
"
btn btn-primary
"
data
-
toggle
=
"
modal
"
data
-
target
=
"
#modal_bangunan_edit
"
id
=
"
btn_edit_bangunan
"
data
-
backdrop
=
"
static
"
data
-
keyboard
=
"
false
"
style
=
"
border-radius: 200px; margin-bottom: 5px;
"
><
i
class
=
"
fa fa-edit
"
style
=
"
color:#ffffff
"
>
<
/i><i style="margin-left: 5px;">Edit Informasi Bangunan</i
><
/a
>
//
<
a
href
=
"
#
"
id
=
'
btn_delete_bangunan
'
class
=
'
btn
// btn-primary btn_edit_bangunan
'
data
-
toggle
=
"
modal
"
data
-
target
=
"
#modal_bangunan_delete
"
data
-
backdrop
=
"
static
"
data
-
keyboard
=
"
false
"
style
=
"
border-radius: 200px; margin-bottom: 5px;
"
><
i
class
=
"
fa fa-trash
"
style
=
"
color:#ffffff
"
>
<
/i><i style="margin-left: 5px;">Delete Bangunan</i
><
/a
>
//
<
/p
>
//
<
/th
>
//
<
/tr
>
//
<
/div
>
//
<
div
class
=
"
container
"
>
// `+history+`
//
<
/div
>
//
<
/tbody
>
//
<
/table>`
;
// $("#isi_panel").html(content);
$
(
"
.gambar_keterangan
"
).
html
(
`<img src="`
+
path_img
+
`" alt="" style="width:100%;height:240px;border-top-left-radius: 10px;border-bottom-left-radius: 10px;">`
)
$
(
"
.nama_keterangan
"
).
html
(
`<div>
<span style="font-size: large;">
`
+
feature
.
properties
.
f2
+
`
</span>
</div>
<div>
<span>
`
+
alamat
+
feature
.
administrasi
.
f1
+
`, `
+
feature
.
administrasi
.
f2
+
`, `
+
feature
.
administrasi
.
f3
+
`, `
+
feature
.
administrasi
.
f4
+
`
</span>
</div>
</div>
</div>`
;
list_history_panel
+=
data_history
};
`
)
history
=
`
$
(
"
.isi_keterangan
"
).
html
(
`<input type="text" name="idjalan" id="idjalan" class="hidden" value="">
<input type="text" name="coordinatejalan" id="coordinatejalan" class="hidden" value="">
<div>
<div>
<span>Jenis Bangunan</span>
</div>
<div>
<div>
<div style="margin-top: 150px;">
<span>Perbaikan Terakhir</span>
<span>
<span>
`
+
feature
.
administrasi
.
f12
+
`
<a id='btn_detail_per_bang' onclick="getdetailperbang(`
+
feature
.
properties
.
f1
+
`)" data-toggle="modal" data-target="#modal_detail" style = "text-align:right; margin-right:26px;"><i>Detail</i></a>
</span>
</span>
</div>
</div>
</div>
<div>
<div>
<span>Luas Bangunan</span>
</div>
<div>
<span style="font-family: 'Roboto';">`
+
feature
.
administrasi
.
f6
+
` m</span>
</div>
</div>
<div>
<div>
<span>Luas Tanah</span>
</div>
<div>
<div>
<span style="font-family: 'Roboto';">`
+
feature
.
administrasi
.
f7
+
` m</span>
<span>
</div>
<tr style="height: 40px;">
<th id="history_panel">
<div class="form-group" style="margin-bottom:0px;">
<div class="row">
<label class="col-md-6">`
+
list_history
[
0
].
split
(
"
,
"
)[
1
]
+
`</label>
<label class="col-md-6">`
+
list_history
[
0
].
split
(
"
,
"
)[
2
]
+
`</label>
</div>
</div>
<div>
<div>
<span>Tinggi Bangunan</span>
</div>
</div>
<div>
<p class="text-center" style="margin-top: 5px;">
<span style="font-family: 'Roboto';">`
+
feature
.
administrasi
.
f8
+
` m</span>
<a href="#" id="btn_perbaikan_bangunan-s" data-toggle="modal" data-target="#input_perbaikan_bang-s"><i>Input Perbaikan</i></a>
</p>
</th>
</tr>
</span>
</div>
</div>
</div>
</div>
`
;
<div>
}
else
{
history
=
`
<div>
<div>
<span>Pemilik</span>
<div style="margin-top: 150px;">
<span>Perbaikan Terakhir</span>
</div>
</div>
<div>
<div>
<span style="font-family: 'Roboto';">`
+
feature
.
administrasi
.
f10
+
` m</span>
<span>
</div>
<tr style="height: 40px;">
</div>`
);
<th id="history_panel">
<p class="text-center" style="margin-top: 10px;"><i>Belum Ada History</i></p>
$
(
"
.btn_action
"
).
html
(
`<div class="tombol-edit-keterangan text-center" style="background-color: #5A9AFB;position: absolute;width: 40px;height: 40px;bottom: 2px;right: 5px;border: 1pt solid rosybrown;border-radius: 8px;">
<p class="text-center" style="margin-top: 10px;">
<a href="#" id="btn_edit_bangunan" class="btn" style="border-bottom-left-radius: 8px;border-top-right-radius: 8px;width: 100%;height: 100%;bottom: 0px;color: white;"><i class="icon-pencil5"></i></a>
<a href="#" id="btn_perbaikan_bangunan-s" data-toggle="modal" data-target="#input_perbaikan_bang-s"><i>Input Perbaikan</i></a>
</p>
</th>
</tr>
</span>
</div>
</div>
<div class="tombol-delete-keterangan text-center" style="background-color: indianred;position: absolute;width: 40px;height: 40px;bottom: 2px;right: 50px;border: 1pt solid rosybrown;border-radius: 10px;">
<a href="#" id="btn_delete_bangunan" class="btn" style="border-bottom-left-radius: 8px;border-top-right-radius: 8px;width: 100%;height: 100%;bottom: 0px;color: white;"><i class="icon-eraser2"></i></a>
</div>
</div>
`
)
`
;
}
}
else
{
history
=
``
}
content
=
`
content
=
`
<table class="table tasks-list">
<table class="table tasks-list">
...
@@ -1116,11 +977,83 @@
...
@@ -1116,11 +977,83 @@
`
+
history
+
`
`
+
history
+
`
</div>
</div>
</tbody>
</tbody>
</table>`
;
</table>
`
;
$
(
"
.gambar_keterangan
"
).
html
(
`<img src="`
+
path_img
+
`" alt="" style="width:100%;height:240px;border-top-left-radius: 10px;border-bottom-left-radius: 10px;">`
)
$
(
"
.nama_keterangan
"
).
html
(
`<div>
<span style="font-size: large;">
`
+
feature
.
properties
.
f2
+
`
</span>
</div>
<div>
<span>
`
+
alamat
+
feature
.
administrasi
.
f1
+
`, `
+
feature
.
administrasi
.
f2
+
`, `
+
feature
.
administrasi
.
f3
+
`, `
+
feature
.
administrasi
.
f4
+
`
</span>
</div>
`
)
$
(
"
.isi_keterangan
"
).
html
(
`<input type="text" name="idjalan" id="idjalan" class="hidden" value="">
<input type="text" name="coordinatejalan" id="coordinatejalan" class="hidden" value="">
<div class="col-md-6">
<div>
<div>
<span style="font-family: 'gilroylight';">Jenis Bangunan</span>
</div>
<div>
<span style="font-family: 'gilroysemibold';">`
+
feature
.
administrasi
.
f12
+
`</span>
</div>
</div>
<div>
<div style="margin-top:5px;">
<span style="font-family: 'gilroylight';">Luas Bangunan</span>
</div>
<div>
<span style="font-family: 'gilroysemibold';">`
+
feature
.
administrasi
.
f6
+
` m</span>
</div>
</div>
<div>
<div>
<span style="font-family: 'gilroylight';">Luas Tanah</span>
</div>
<div>
<span style="font-family: 'gilroysemibold';">`
+
feature
.
administrasi
.
f7
+
` m</span>
</div>
</div>
</div>
<div class="col-md-6">
<div>
<div>
<span style="font-family: 'gilroylight';">Tinggi Bangunan</span>
</div>
<div>
<span style="font-family: 'gilroysemibold';">`
+
feature
.
administrasi
.
f8
+
` m</span>
</div>
</div>
<div>
<div style="margin-top:5px;">
<span style="font-family: 'gilroylight';">Pemilik</span>
</div>
<div>
<span style="font-family: 'gilroysemibold';">`
+
feature
.
administrasi
.
f10
+
` m</span>
</div>
</div>
</div>
`
+
history
+
`
`
);
$
(
"
.btn_action
"
).
html
(
`<div class="tombol-edit-keterangan text-center" style="background-color: #5A9AFB;position: absolute;width: 40px;height: 40px;bottom: 2px;right: 5px;border: 1pt solid rosybrown;border-radius: 8px;">
<a href="#" id="btn_edit_bangunan" class="btn" style="border-bottom-left-radius: 8px;border-top-right-radius: 8px;width: 100%;height: 100%;bottom: 0px;color: white;"><i class="icon-pencil5"></i></a>
</div>
<div class="tombol-delete-keterangan text-center" style="background-color: indianred;position: absolute;width: 40px;height: 40px;bottom: 2px;right: 50px;border: 1pt solid rosybrown;border-radius: 10px;">
<a href="#" id="btn_delete_bangunan" class="btn" style="border-bottom-left-radius: 8px;border-top-right-radius: 8px;width: 100%;height: 100%;bottom: 0px;color: white;"><i class="icon-eraser2"></i></a>
</div>
`
)
$
(
"
#isi_panel
"
).
html
(
content
);
$
(
"
#isi_panel
"
).
html
(
content
);
$
(
"
#modal_bangunan_edit
"
).
html
(
content_edit
);
$
(
"
#modal_bangunan_edit
"
).
html
(
content_edit
);
$
(
"
#modal_bangunan_delete
"
).
html
(
content_delete
);
$
(
"
#modal_bangunan_delete
"
).
html
(
content_delete
);
$
(
"
#input_perbaikan_bang
"
).
html
(
content_inp_his_bang
);
$
(
"
#input_perbaikan_bang
-s
"
).
html
(
content_inp_his_bang
);
panel_samp
();
panel_samp
();
});
});
// $("#tipe_point_b_e").val('feature.administrasi.f11').change();
// $("#tipe_point_b_e").val('feature.administrasi.f11').change();
...
@@ -1220,53 +1153,10 @@
...
@@ -1220,53 +1153,10 @@
});
});
map
.
setView
([
data
[
'
gen
'
][
0
][
0
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
1
],
data
[
'
gen
'
][
0
][
0
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
0
]],
19
);
map
.
setView
([
data
[
'
gen
'
][
0
][
0
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
1
],
data
[
'
gen
'
][
0
][
0
][
'
geometry
'
][
'
coordinates
'
][
0
][
0
][
0
][
0
]],
19
);
geo_bangunan
.
addTo
(
map
)
geo_bangunan
.
addTo
(
map
);
// if (checkBox_building.checked == false) {
// geo_bangunan.clearLayers();
// geo_bangunan.remove();
// }
// map.eachLayer(function (layer) {
// if (!!geo_bangunan.toGeoJSON) {
// map.removeLayer(geo_bangunan);
// }
// geo_bangunan.clearLayers()
// map.on("movestart", function() {
// geo_bangunan.clearLayers();
// });
// function gasin(){
// $.ajax({
// url: "{% url 'api:search_lanjut' %}",
// data: {
// 'type':dar,
// 'idx':idm,
// 'db':db
// },
// dataType: 'json',
// success: function(data) {
// // if (map.hasLayer(geo_bangunan)) {
// // geo_bangunan.clearLayers()
// // geo_bangunan.remove()
// // }
// let list_poly = [];
// for (var i = 0; i
<
data
[
'
gen
'
].
length
;
i
++
)
{
// geoj = data['gen'][i][0];
// list_poly.push(geoj);
// };
// // geo_bangunan.clearLayers()
// // geo_bangunan.remove()
// geo_json_bangunan(list_poly);
// }
// });
// map.setView([data['gen'][0][0]['geometry']['coordinates'][0][0][0][1], data['gen'][0][0]['geometry']['coordinates'][0][0][0][0]], 19);
// // geo_bangunan.clearLayers()
// geo_bangunan.addTo(map)
// }
// });
$
(
document
).
on
(
"
click
"
,
"
#btn_edit_bangunan
"
,
function
()
{
$
(
document
).
on
(
"
click
"
,
"
#btn_edit_bangunan
"
,
function
()
{
$
(
"
#modal_bangunan_edit
"
).
css
(
'
display
'
,
'
block
'
);
var
tipe1
=
$
(
'
#tipe111
'
).
val
();
var
tipe1
=
$
(
'
#tipe111
'
).
val
();
$
(
'
#tipe_point_b_e option[value=
'
+
tipe1
+
'
]
'
).
attr
(
'
selected
'
,
'
selected
'
);
$
(
'
#tipe_point_b_e option[value=
'
+
tipe1
+
'
]
'
).
attr
(
'
selected
'
,
'
selected
'
);
...
@@ -1468,6 +1358,7 @@
...
@@ -1468,6 +1358,7 @@
});
});
$
(
document
).
on
(
"
click
"
,
"
#btn_delete_bangunan
"
,
function
()
{
$
(
document
).
on
(
"
click
"
,
"
#btn_delete_bangunan
"
,
function
()
{
$
(
"
#modal_bangunan_delete
"
).
css
(
'
display
'
,
'
block
'
);
var
map_delete
=
new
L
.
map
(
'
map-delete
'
,
{
var
map_delete
=
new
L
.
map
(
'
map-delete
'
,
{
editable
:
true
,
editable
:
true
,
zoomControl
:
false
,
zoomControl
:
false
,
...
@@ -1478,6 +1369,7 @@
...
@@ -1478,6 +1369,7 @@
maxZoom
:
22
,
maxZoom
:
22
,
minZoom
:
4
,
minZoom
:
4
,
}).
addTo
(
map_delete
);
}).
addTo
(
map_delete
);
var
id_polyhps
=
$
(
'
#idbangunanhps
'
).
val
();
var
id_polyhps
=
$
(
'
#idbangunanhps
'
).
val
();
// console.log(id_polyhps)
// console.log(id_polyhps)
loaderPage
(
true
);
loaderPage
(
true
);
...
@@ -1552,8 +1444,10 @@
...
@@ -1552,8 +1444,10 @@
});
});
var
map_bang
=
new
L
.
map
(
'
map-insert-renov-bang
'
,
{
$
(
document
).
on
(
"
click
"
,
"
#btn_perbaikan_bangunan-s
"
,
function
()
{
editable
:
true
,
// $("#input_perbaikan_bang-s").css("display", "block");
var
map_bang
=
new
L
.
map
(
'
map-insert-renov-bang-s
'
,
{
editable
:
false
,
zoomControl
:
false
,
zoomControl
:
false
,
drawControl
:
true
drawControl
:
true
}).
setView
([
-
2
,
118
],
5
);
}).
setView
([
-
2
,
118
],
5
);
...
@@ -1563,42 +1457,13 @@
...
@@ -1563,42 +1457,13 @@
minZoom
:
4
,
minZoom
:
4
,
}).
addTo
(
map_bang
);
}).
addTo
(
map_bang
);
var
polyxxx
=
L
.
polygon
([
// if (map_bang.hasLayer(polyxxx)) {
[
-
4.1283969
,
104.1674575
],
// polyxxx.remove()
[
-
4.128396
,
104.1674947
],
[
-
4.1284664
,
104.1674964
],
[
-
4.1284674
,
104.1674593
],
[
-
4.1283969
,
104.1674575
]
]).
addTo
(
map_bang
)
// var geo_bangunan_input = L.geoJson(null, {
// style: function(feature) {
// return {
// color: "#06FF08",
// weight: 8,
// opacity: 2,
// zIndex: 1000
// };
// }
// }
// }).addTo(map_bang);
$
(
document
).
on
(
"
click
"
,
"
#btn_perbaikan_bangunan
"
,
function
()
{
var
id_polyx
=
$
(
'
#id_bang_perbaikan
'
).
val
();
var
map_bang
=
new
L
.
map
(
'
map-insert-renov-bang
'
,
{
editable
:
true
,
zoomControl
:
false
,
drawControl
:
true
}).
setView
([
-
2
,
118
],
5
);
mapssx
=
L
.
tileLayer
(
'
https://mt1.google.com/vt/lyrs=s&x={x}&y={y}&z={z}
'
,
{
loaderPage
(
true
);
maxZoom
:
22
,
minZoom
:
4
,
}).
addTo
(
map_bang
);
$
(
"
#input_perbaikan_bang
"
).
css
(
"
display
"
,
"
block
"
);
if
(
map_bang
.
hasLayer
(
polyxxx
))
{
polyxxx
.
remove
()
}
var
id_polyx
=
$
(
'
#idbangunan
'
).
val
();
$
.
ajax
({
$
.
ajax
({
url
:
"
{% url 'apps:input-perbaikan-bang' %}
"
,
url
:
"
{% url 'apps:input-perbaikan-bang' %}
"
,
...
@@ -1607,6 +1472,12 @@
...
@@ -1607,6 +1472,12 @@
},
},
dataType
:
'
json
'
,
dataType
:
'
json
'
,
success
:
function
(
data
)
{
success
:
function
(
data
)
{
setTimeout
(
function
()
{
map_bang
.
invalidateSize
();
},
1000
);
loaderPage
(
false
);
$
(
"
#nama_bang
"
).
val
(
data
[
0
]);
$
(
"
#nama_bang
"
).
val
(
data
[
0
]);
$
(
"
#type_bang
"
).
val
(
data
[
4
]);
$
(
"
#type_bang
"
).
val
(
data
[
4
]);
$
(
"
#id_bang_perbaikan
"
).
val
(
data
[
3
]);
$
(
"
#id_bang_perbaikan
"
).
val
(
data
[
3
]);
...
@@ -1636,7 +1507,7 @@
...
@@ -1636,7 +1507,7 @@
})
})
}
}
})
})
})
})
;
$
(
document
).
on
(
"
click
"
,
"
#save-perbaikan_bang
"
,
function
(
e
)
{
$
(
document
).
on
(
"
click
"
,
"
#save-perbaikan_bang
"
,
function
(
e
)
{
var
polyginbang
=
$
(
'
#coorbangbaru
'
).
val
();
var
polyginbang
=
$
(
'
#coorbangbaru
'
).
val
();
...
@@ -1716,7 +1587,7 @@
...
@@ -1716,7 +1587,7 @@
icon
:
"
success
"
,
icon
:
"
success
"
,
confirmButtonColor
:
"
#00BCD4
"
confirmButtonColor
:
"
#00BCD4
"
},
function
()
{
},
function
()
{
$
(
"
#input_perbaikan_bang
"
).
css
(
"
display
"
,
"
none
"
);
$
(
"
#input_perbaikan_bang
-s
"
).
css
(
"
display
"
,
"
none
"
);
})
})
}
else
{
}
else
{
swal
({
swal
({
...
@@ -2104,7 +1975,7 @@
...
@@ -2104,7 +1975,7 @@
});
});
$
(
document
).
on
(
"
click
"
,
"
#btn_jalan
"
,
function
()
{
$
(
document
).
on
(
"
click
"
,
"
#btn_jalan
"
,
function
()
{
$
(
"
#modal-jalan
"
).
css
(
'
display
'
,
'
block
'
);
if
(
map_edit_jalan
.
hasLayer
(
polygon_edit_jalan
))
{
if
(
map_edit_jalan
.
hasLayer
(
polygon_edit_jalan
))
{
polygon_edit_jalan
.
remove
()
polygon_edit_jalan
.
remove
()
}
}
...
@@ -2162,7 +2033,7 @@
...
@@ -2162,7 +2033,7 @@
//tes
//tes
$
(
document
).
on
(
"
click
"
,
"
#btn_hapus_jalan
"
,
function
()
{
$
(
document
).
on
(
"
click
"
,
"
#btn_hapus_jalan
"
,
function
()
{
$
(
"
#modal-hapus-jalan
"
).
css
(
'
display
'
,
'
block
'
);
var
id_poly
=
$
(
'
#idjalan
'
).
val
();
var
id_poly
=
$
(
'
#idjalan
'
).
val
();
$
.
ajax
({
$
.
ajax
({
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment