62 lines
1.9 KiB
Plaintext
62 lines
1.9 KiB
Plaintext
@{
|
|
ViewData["Title"] = "Wilayah Kecamatan";
|
|
}
|
|
|
|
<div class="flex flex-col gap-2 md:flex-row md:justify-between md:gap-0">
|
|
<div class="prose">
|
|
<span class="text-xl font-semibold text-black">
|
|
Wilayah Kecamatan
|
|
</span>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="h-6"></div>
|
|
|
|
<div class="card bg-white">
|
|
<div class="card-body p-2">
|
|
<div class="w-full overflow-x-auto">
|
|
<table class="table-zebra table" id="example">
|
|
<!-- head -->
|
|
<thead>
|
|
<tr>
|
|
<th class="w-[5%]">No</th>
|
|
<th class="w-[10%]">Kode</th>
|
|
<th class="w-[15%]">Nama Kecamatan</th>
|
|
<th class="w-[15%]">Nama Kota/Kabupaten</th>
|
|
<th class="w-[25%]">Provinsi</th>
|
|
<th class="w-[15%]">Latitude</th>
|
|
<th class="w-[15%]">Longitude</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody></tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
@section Scripts {
|
|
<script type="text/javascript">
|
|
var table;
|
|
|
|
$(document).ready(function () {
|
|
table = new DataTable('#example', {
|
|
ajax: '/Wilayah/Kecamatan/Table',
|
|
scrollX: true,
|
|
autoWidth: false,
|
|
initComplete: function () {
|
|
$('div.dt-scroll-body thead').css('visibility', 'collapse');
|
|
},
|
|
columns: [
|
|
{ data: null, render: (d, t, r, m) => m.row + 1, orderable: false, searchable: false },
|
|
{ data: 'kode' },
|
|
{ data: 'kecamatan' },
|
|
{ data: 'kabupaten' },
|
|
{ data: 'provinsi' },
|
|
{ data: 'latitude' },
|
|
{ data: 'longitude' },
|
|
]
|
|
});
|
|
});
|
|
</script>
|
|
}
|