initiall commit
This commit is contained in:
@@ -0,0 +1,778 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>WebGIS Pontianak — Portal Sistem Informasi Geografis</title>
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Space+Grotesk:wght@500;600;700&display=swap" rel="stylesheet">
|
||||
<style>
|
||||
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
|
||||
|
||||
:root {
|
||||
--bg: #F0F4F8;
|
||||
--surface: #ffffff;
|
||||
--surface2: #F7F9FB;
|
||||
--border: rgba(0,0,0,0.08);
|
||||
--border-md: rgba(0,0,0,0.13);
|
||||
--navy: #0C2D48;
|
||||
--navy2: #163D5E;
|
||||
--blue: #1A6FA8;
|
||||
--blue-light: #E8F3FB;
|
||||
--blue-mid: #378ADD;
|
||||
--green: #1D7A5F;
|
||||
--green-light: #E6F5F0;
|
||||
--amber: #B86800;
|
||||
--amber-light: #FEF3E2;
|
||||
--red: #C23B3B;
|
||||
--red-light: #FDEAEA;
|
||||
--purple: #5B5BD6;
|
||||
--purple-light: #EEF0FE;
|
||||
--text: #0C1B2A;
|
||||
--text2: #4A5E6E;
|
||||
--text3: #8A9BAA;
|
||||
--radius: 10px;
|
||||
--radius-lg: 16px;
|
||||
--shadow: 0 1px 3px rgba(0,0,0,0.07), 0 4px 16px rgba(0,0,0,0.06);
|
||||
--shadow-lg: 0 8px 30px rgba(0,0,0,0.10);
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: 'Inter', sans-serif;
|
||||
background: var(--bg);
|
||||
color: var(--text);
|
||||
min-height: 100vh;
|
||||
font-size: 14px;
|
||||
line-height: 1.6;
|
||||
}
|
||||
|
||||
/* ── NAVBAR ── */
|
||||
.navbar {
|
||||
background: var(--navy);
|
||||
padding: 0 2rem;
|
||||
height: 58px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
position: sticky; top: 0; z-index: 100;
|
||||
border-bottom: 1px solid rgba(255,255,255,0.06);
|
||||
}
|
||||
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; }
|
||||
.brand-icon {
|
||||
width: 36px; height: 36px;
|
||||
background: var(--blue-mid); border-radius: 9px;
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
}
|
||||
.brand-icon svg { width: 18px; height: 18px; fill: none; stroke: #fff; stroke-width: 1.8; }
|
||||
.brand-name { font-family: 'Space Grotesk', sans-serif; font-size: 15px; font-weight: 600; color: #fff; }
|
||||
.brand-sub { font-size: 11px; color: rgba(255,255,255,0.45); }
|
||||
.nav-right { display: flex; align-items: center; gap: 8px; }
|
||||
.pill-online {
|
||||
display: inline-flex; align-items: center; gap: 5px;
|
||||
background: rgba(29,122,95,0.25); color: #6DDDBC;
|
||||
font-size: 11px; font-weight: 500;
|
||||
padding: 4px 10px; border-radius: 20px;
|
||||
border: 1px solid rgba(109,221,188,0.2);
|
||||
}
|
||||
.pill-online::before {
|
||||
content: ''; width: 6px; height: 6px;
|
||||
border-radius: 50%; background: #6DDDBC;
|
||||
animation: blink 2s infinite;
|
||||
}
|
||||
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0.3} }
|
||||
|
||||
/* ── HERO ── */
|
||||
.hero {
|
||||
background: var(--navy2);
|
||||
position: relative; overflow: hidden;
|
||||
padding: 3rem 2.5rem 2.8rem;
|
||||
text-align: center;
|
||||
}
|
||||
.hero-grid-bg {
|
||||
position: absolute; inset: 0;
|
||||
background-image:
|
||||
linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
|
||||
linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
|
||||
background-size: 40px 40px;
|
||||
pointer-events: none;
|
||||
}
|
||||
.hero-content { position: relative; z-index: 1; max-width: 600px; margin: 0 auto; }
|
||||
.hero-eyebrow {
|
||||
display: inline-flex; align-items: center; gap: 8px;
|
||||
font-size: 11px; font-weight: 500; letter-spacing: .06em;
|
||||
color: rgba(255,255,255,0.45); text-transform: uppercase;
|
||||
margin-bottom: 1.1rem;
|
||||
}
|
||||
.hero-eyebrow span { width: 20px; height: 1px; background: rgba(255,255,255,0.25); }
|
||||
.hero h1 {
|
||||
font-family: 'Space Grotesk', sans-serif;
|
||||
font-size: 36px; font-weight: 700;
|
||||
color: #fff; line-height: 1.18; margin-bottom: .75rem;
|
||||
}
|
||||
.hero h1 em { font-style: normal; color: #62C4F5; }
|
||||
.hero-desc {
|
||||
font-size: 14px; color: rgba(255,255,255,0.58);
|
||||
line-height: 1.75; max-width: 460px; margin: 0 auto 2rem;
|
||||
}
|
||||
.hero-chips { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
|
||||
.hero-chip {
|
||||
display: inline-flex; align-items: center; gap: 5px;
|
||||
background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.12);
|
||||
color: rgba(255,255,255,0.65);
|
||||
font-size: 11px; padding: 5px 12px; border-radius: 20px;
|
||||
}
|
||||
.hero-chip svg { width: 12px; height: 12px; }
|
||||
|
||||
/* ── MAIN ── */
|
||||
.main { max-width: 960px; margin: 0 auto; padding: 2.5rem 1.5rem 3rem; }
|
||||
|
||||
/* ── PORTAL LABEL ── */
|
||||
.section-label {
|
||||
font-size: 11px; font-weight: 600; letter-spacing: .1em;
|
||||
text-transform: uppercase; color: var(--text3);
|
||||
margin-bottom: 1.1rem;
|
||||
display: flex; align-items: center; gap: 10px;
|
||||
}
|
||||
.section-label::after { content: ''; flex: 1; height: 1px; background: var(--border); }
|
||||
|
||||
/* ── PORTAL CARDS ── */
|
||||
.portal-grid {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 20px;
|
||||
margin-bottom: 2.5rem;
|
||||
}
|
||||
@media(max-width:640px){ .portal-grid { grid-template-columns: 1fr; } }
|
||||
|
||||
.portal-card {
|
||||
background: var(--surface);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-lg);
|
||||
overflow: hidden;
|
||||
box-shadow: var(--shadow);
|
||||
display: flex; flex-direction: column;
|
||||
transition: transform .18s, box-shadow .18s;
|
||||
text-decoration: none; color: inherit;
|
||||
}
|
||||
.portal-card:hover {
|
||||
transform: translateY(-3px);
|
||||
box-shadow: var(--shadow-lg);
|
||||
}
|
||||
|
||||
/* map preview area */
|
||||
.portal-map {
|
||||
height: 210px;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
.portal-map svg { width: 100%; height: 100%; display: block; }
|
||||
|
||||
/* portal card body */
|
||||
.portal-body {
|
||||
padding: 1.1rem 1.25rem 1rem;
|
||||
flex: 1; display: flex; flex-direction: column;
|
||||
}
|
||||
.portal-badge {
|
||||
display: inline-flex; align-items: center; gap: 5px;
|
||||
font-size: 10px; font-weight: 600; letter-spacing: .04em;
|
||||
text-transform: uppercase;
|
||||
padding: 3px 9px; border-radius: 20px;
|
||||
margin-bottom: .65rem; width: fit-content;
|
||||
}
|
||||
.portal-badge svg { width: 10px; height: 10px; }
|
||||
.portal-title {
|
||||
font-family: 'Space Grotesk', sans-serif;
|
||||
font-size: 17px; font-weight: 700;
|
||||
color: var(--text); margin-bottom: .35rem; line-height: 1.3;
|
||||
}
|
||||
.portal-desc {
|
||||
font-size: 12.5px; color: var(--text2);
|
||||
line-height: 1.65; margin-bottom: 1rem; flex: 1;
|
||||
}
|
||||
|
||||
/* layer chips inside card */
|
||||
.layer-chips { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 1rem; }
|
||||
.lc {
|
||||
display: inline-flex; align-items: center; gap: 4px;
|
||||
font-size: 11px; font-weight: 500;
|
||||
padding: 3px 9px; border-radius: 20px;
|
||||
background: var(--surface2); border: 1px solid var(--border);
|
||||
color: var(--text2);
|
||||
}
|
||||
.lc-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
|
||||
|
||||
/* enter button */
|
||||
.portal-enter {
|
||||
display: flex; align-items: center; justify-content: space-between;
|
||||
padding: 11px 14px; border-radius: var(--radius);
|
||||
font-size: 13px; font-weight: 600;
|
||||
cursor: pointer; border: none;
|
||||
font-family: 'Inter', sans-serif;
|
||||
transition: opacity .15s, transform .12s;
|
||||
color: #fff; text-decoration: none;
|
||||
}
|
||||
.portal-enter:hover { opacity: .9; transform: translateX(2px); }
|
||||
.portal-enter svg { width: 15px; height: 15px; }
|
||||
|
||||
/* ── STAT BAR ── */
|
||||
.stat-bar {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
|
||||
gap: 10px; margin-bottom: 2rem;
|
||||
}
|
||||
.sb-card {
|
||||
background: var(--surface);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-lg);
|
||||
padding: 1rem 1.1rem;
|
||||
display: flex; align-items: center; gap: 10px;
|
||||
box-shadow: var(--shadow);
|
||||
}
|
||||
.sb-icon { width: 36px; height: 36px; border-radius: 9px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
|
||||
.sb-icon svg { width: 17px; height: 17px; stroke-width: 1.8; }
|
||||
.sb-label { font-size: 11px; color: var(--text3); margin-bottom: 1px; }
|
||||
.sb-val { font-size: 19px; font-weight: 600; font-family: 'Space Grotesk', sans-serif; }
|
||||
|
||||
/* ── BOTTOM GRID ── */
|
||||
.bottom-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 1.5rem; }
|
||||
@media(max-width:600px){ .bottom-grid { grid-template-columns: 1fr; } }
|
||||
|
||||
.card {
|
||||
background: var(--surface); border: 1px solid var(--border);
|
||||
border-radius: var(--radius-lg); overflow: hidden;
|
||||
box-shadow: var(--shadow);
|
||||
}
|
||||
.card-head {
|
||||
padding: 12px 16px; border-bottom: 1px solid var(--border);
|
||||
display: flex; align-items: center; justify-content: space-between;
|
||||
}
|
||||
.card-head-title {
|
||||
font-size: 13px; font-weight: 500; color: var(--text);
|
||||
display: flex; align-items: center; gap: 7px;
|
||||
}
|
||||
.card-head-title svg { width: 15px; height: 15px; stroke-width: 2; flex-shrink: 0; }
|
||||
.card-body { padding: 14px 16px; }
|
||||
.badge { font-size: 10px; font-weight: 500; padding: 3px 9px; border-radius: 20px; }
|
||||
.badge-blue { background: var(--blue-light); color: var(--blue); }
|
||||
.badge-green { background: var(--green-light); color: var(--green); }
|
||||
|
||||
/* layer list */
|
||||
.layer-list { display: flex; flex-direction: column; gap: 5px; }
|
||||
.layer-item {
|
||||
display: flex; align-items: center; gap: 9px;
|
||||
padding: 8px 10px; border-radius: 8px;
|
||||
background: var(--surface2);
|
||||
}
|
||||
.l-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
|
||||
.l-name { font-size: 13px; color: var(--text); flex: 1; }
|
||||
.l-folder { font-size: 10px; font-weight: 600; letter-spacing: .03em; padding: 2px 7px; border-radius: 10px; }
|
||||
|
||||
/* activity */
|
||||
.act-list { display: flex; flex-direction: column; }
|
||||
.act-item { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border); }
|
||||
.act-item:last-child { border-bottom: none; }
|
||||
.act-ic { width: 30px; height: 30px; border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 1px; }
|
||||
.act-ic svg { width: 14px; height: 14px; stroke-width: 2; }
|
||||
.act-title { font-size: 13px; color: var(--text); line-height: 1.4; }
|
||||
.act-meta { font-size: 11px; color: var(--text3); margin-top: 1px; }
|
||||
|
||||
/* account card */
|
||||
.account-card {
|
||||
background: var(--surface); border: 1px solid var(--border);
|
||||
border-radius: var(--radius-lg); overflow: hidden;
|
||||
box-shadow: var(--shadow); margin-bottom: 1.5rem;
|
||||
}
|
||||
.ac-header {
|
||||
background: var(--navy); padding: 1.1rem 1.4rem;
|
||||
display: flex; align-items: center; gap: 12px;
|
||||
}
|
||||
.ac-header-ic { width: 36px; height: 36px; border-radius: 9px; background: rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; }
|
||||
.ac-header-ic svg { width: 17px; height: 17px; stroke: rgba(255,255,255,0.8); stroke-width: 1.8; }
|
||||
.ac-header-title { font-size: 14px; font-weight: 500; color: #fff; }
|
||||
.ac-header-sub { font-size: 11px; color: rgba(255,255,255,0.45); margin-top: 1px; }
|
||||
.ac-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
|
||||
.ac-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 9px; background: var(--surface2); }
|
||||
.av { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 600; flex-shrink: 0; }
|
||||
.ac-name { font-size: 13px; font-weight: 500; color: var(--text); }
|
||||
.ac-pass { font-size: 11px; color: var(--text3); font-family: 'Space Grotesk', monospace; margin-top: 1px; }
|
||||
.ac-role { font-size: 10px; font-weight: 600; padding: 3px 9px; border-radius: 20px; margin-left: auto; }
|
||||
.ac-foot { padding: 10px 14px; border-top: 1px solid var(--border); }
|
||||
.btn-login-full {
|
||||
width: 100%; background: var(--blue); color: #fff;
|
||||
border: none; border-radius: 9px; padding: 10px;
|
||||
font-size: 13px; font-weight: 500; cursor: pointer;
|
||||
display: flex; align-items: center; justify-content: center; gap: 7px;
|
||||
font-family: 'Inter', sans-serif; transition: background .15s;
|
||||
text-decoration: none;
|
||||
}
|
||||
.btn-login-full:hover { background: var(--navy2); }
|
||||
.btn-login-full svg { width: 15px; height: 15px; stroke: white; stroke-width: 2; }
|
||||
|
||||
/* footer */
|
||||
.footer {
|
||||
background: var(--navy); padding: 1.2rem 2rem;
|
||||
display: flex; align-items: center; justify-content: space-between;
|
||||
flex-wrap: wrap; gap: 10px;
|
||||
border-top: 1px solid rgba(255,255,255,0.05);
|
||||
}
|
||||
.footer p { font-size: 11px; color: rgba(255,255,255,0.35); }
|
||||
.footer-links { display: flex; gap: 14px; flex-wrap: wrap; }
|
||||
.footer-links a {
|
||||
font-size: 11px; color: rgba(255,255,255,0.45);
|
||||
text-decoration: none; display: flex; align-items: center; gap: 4px;
|
||||
transition: color .12s;
|
||||
}
|
||||
.footer-links a:hover { color: rgba(255,255,255,0.8); }
|
||||
.footer-links a svg { width: 12px; height: 12px; stroke-width: 2; }
|
||||
|
||||
/* color helpers */
|
||||
.c-blue-bg { background: var(--blue-light); }
|
||||
.c-blue-icon { stroke: var(--blue); }
|
||||
.c-green-bg { background: var(--green-light); }
|
||||
.c-green-icon { stroke: var(--green); }
|
||||
.c-amber-bg { background: var(--amber-light); }
|
||||
.c-amber-icon { stroke: var(--amber); }
|
||||
.c-red-bg { background: var(--red-light); }
|
||||
.c-red-icon { stroke: var(--red); }
|
||||
.c-purple-bg { background: var(--purple-light); }
|
||||
.c-purple-icon { stroke: var(--purple); }
|
||||
.c-blue-text { color: var(--blue); }
|
||||
.c-green-text { color: var(--green); }
|
||||
.c-amber-text { color: var(--amber); }
|
||||
.c-red-text { color: var(--red); }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<!-- NAVBAR -->
|
||||
<nav class="navbar">
|
||||
<a class="brand" href="#">
|
||||
<div class="brand-icon">
|
||||
<svg viewBox="0 0 24 24"><path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5A2.5 2.5 0 1 1 12 6.5a2.5 2.5 0 0 1 0 5z"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="brand-name">WebGIS Pontianak</div>
|
||||
<div class="brand-sub">Portal Sistem Informasi Geografis</div>
|
||||
</div>
|
||||
</a>
|
||||
<div class="nav-right">
|
||||
<span class="pill-online">Sistem Online</span>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<!-- HERO -->
|
||||
<div class="hero">
|
||||
<div class="hero-grid-bg"></div>
|
||||
<div class="hero-content">
|
||||
<div class="hero-eyebrow"><span></span>GIS Kota Pontianak<span></span></div>
|
||||
<h1>Pilih <em>Modul Peta</em><br>yang Ingin Diakses</h1>
|
||||
<p class="hero-desc">Sistem WebGIS terpadu Kota Pontianak terbagi menjadi dua modul: infrastruktur fisik dan data sosial warga. Pilih modul di bawah untuk masuk.</p>
|
||||
<div class="hero-chips">
|
||||
<span class="hero-chip">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M3 12h18M3 6h18M3 18h18"/></svg>
|
||||
Jalan & Parsil
|
||||
</span>
|
||||
<span class="hero-chip">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M3 22V6a2 2 0 012-2h8a2 2 0 012 2v16"/><path d="M15 10h2a2 2 0 012 2v6a1 1 0 001 1v0a1 1 0 001-1v-9l-3-5"/><line x1="3" y1="22" x2="15" y2="22"/></svg>
|
||||
SPBU
|
||||
</span>
|
||||
<span class="hero-chip">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M17 21v-2a4 4 0 00-4-4H5a4 4 0 00-4 4v2"/><circle cx="9" cy="7" r="4"/></svg>
|
||||
Data Warga
|
||||
</span>
|
||||
<span class="hero-chip">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M21 15a2 2 0 01-2 2H7l-4 4V5a2 2 0 012-2h14a2 2 0 012 2z"/></svg>
|
||||
Pengaduan
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- MAIN -->
|
||||
<div class="main">
|
||||
|
||||
<div class="section-label">Pilih Modul Peta</div>
|
||||
|
||||
<!-- PORTAL CARDS -->
|
||||
<div class="portal-grid">
|
||||
|
||||
<!-- FOLDER 01: Infrastruktur -->
|
||||
<a href="http://localhost/wib_gis/01/login.php" class="portal-card">
|
||||
<!-- MAP PREVIEW -->
|
||||
<div class="portal-map" style="background:#1C3A5E;">
|
||||
<svg viewBox="0 0 480 210" xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMid slice">
|
||||
<!-- BG water -->
|
||||
<rect width="480" height="210" fill="#1C3A5E"/>
|
||||
<!-- grid -->
|
||||
<rect width="480" height="210" fill="none"
|
||||
style="background-image: linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px), linear-gradient(90deg,rgba(255,255,255,0.03) 1px, transparent 1px); background-size: 30px 30px;"/>
|
||||
<!-- subtle terrain -->
|
||||
<path d="M0 130 Q80 112 160 125 Q240 138 320 122 Q400 106 480 118" stroke="rgba(255,255,255,0.07)" stroke-width="30" fill="none"/>
|
||||
<!-- Jalan Nasional merah -->
|
||||
<line x1="30" y1="98" x2="450" y2="94" stroke="#ef4444" stroke-width="4" opacity="0.85"/>
|
||||
<!-- Jalan Provinsi kuning -->
|
||||
<line x1="180" y1="20" x2="188" y2="190" stroke="#f59e0b" stroke-width="3" opacity="0.8"/>
|
||||
<line x1="310" y1="20" x2="304" y2="190" stroke="#f59e0b" stroke-width="3" opacity="0.75"/>
|
||||
<!-- Jalan Kabupaten biru -->
|
||||
<line x1="30" y1="155" x2="450" y2="150" stroke="#3b82f6" stroke-width="2.5" opacity="0.6"/>
|
||||
<line x1="30" y1="52" x2="450" y2="50" stroke="#3b82f6" stroke-width="2" opacity="0.5"/>
|
||||
<!-- Parsil polygon 1 -->
|
||||
<polygon points="60,35 130,32 135,75 62,78" fill="rgba(139,92,246,0.35)" stroke="#8b5cf6" stroke-width="1.5"/>
|
||||
<!-- Parsil polygon 2 -->
|
||||
<polygon points="350,120 420,116 425,168 352,172" fill="rgba(139,92,246,0.35)" stroke="#8b5cf6" stroke-width="1.5"/>
|
||||
<!-- Parsil polygon 3 small -->
|
||||
<polygon points="200,38 255,36 258,70 202,73" fill="rgba(139,92,246,0.25)" stroke="#8b5cf6" stroke-width="1.2"/>
|
||||
<!-- SPBU 24 jam hijau -->
|
||||
<rect x="96" y="82" width="13" height="17" rx="2" fill="#10b981" opacity="0.9"/>
|
||||
<rect x="98.5" y="84" width="8" height="4" rx="1" fill="rgba(255,255,255,0.5)"/>
|
||||
<rect x="101" y="93" width="3" height="6" fill="rgba(255,255,255,0.4)"/>
|
||||
|
||||
<rect x="258" y="77" width="13" height="17" rx="2" fill="#10b981" opacity="0.9"/>
|
||||
<rect x="260.5" y="79" width="8" height="4" rx="1" fill="rgba(255,255,255,0.5)"/>
|
||||
<rect x="263" y="88" width="3" height="6" fill="rgba(255,255,255,0.4)"/>
|
||||
|
||||
<!-- SPBU reguler merah -->
|
||||
<rect x="155" y="136" width="13" height="17" rx="2" fill="#ef4444" opacity="0.9"/>
|
||||
<rect x="157.5" y="138" width="8" height="4" rx="1" fill="rgba(255,255,255,0.5)"/>
|
||||
<rect x="160" y="147" width="3" height="6" fill="rgba(255,255,255,0.4)"/>
|
||||
|
||||
<rect x="375" y="78" width="13" height="17" rx="2" fill="#ef4444" opacity="0.85"/>
|
||||
<rect x="377.5" y="80" width="8" height="4" rx="1" fill="rgba(255,255,255,0.5)"/>
|
||||
<rect x="380" y="89" width="3" height="6" fill="rgba(255,255,255,0.4)"/>
|
||||
|
||||
<!-- Legend box -->
|
||||
<rect x="8" y="145" width="130" height="58" rx="6" fill="rgba(12,45,72,0.85)" stroke="rgba(255,255,255,0.12)" stroke-width="0.8"/>
|
||||
<text x="18" y="161" font-size="9" fill="rgba(255,255,255,0.5)" font-family="Inter,sans-serif" font-weight="600" letter-spacing="0.04em">LAPISAN AKTIF</text>
|
||||
<line x1="18" y1="164" x2="130" y2="164" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/>
|
||||
<line x1="18" y1="172" x2="30" y2="172" stroke="#ef4444" stroke-width="3"/><text x="34" y="175.5" font-size="9" fill="rgba(255,255,255,0.7)" font-family="Inter,sans-serif">Jalan Nasional</text>
|
||||
<rect x="18" y="179" width="9" height="11" rx="1.5" fill="#10b981"/><text x="31" y="188" font-size="9" fill="rgba(255,255,255,0.7)" font-family="Inter,sans-serif">SPBU 24 Jam</text>
|
||||
<polygon points="18,193 30,192 30.5,196 18.5,197" fill="rgba(139,92,246,0.7)"/><text x="34" y="198" font-size="9" fill="rgba(255,255,255,0.7)" font-family="Inter,sans-serif">Parsil Kavling</text>
|
||||
|
||||
<!-- Folder label pill -->
|
||||
<rect x="350" y="8" width="118" height="22" rx="11" fill="rgba(59,130,246,0.25)" stroke="rgba(99,163,245,0.4)" stroke-width="0.8"/>
|
||||
<text x="409" y="22" font-size="10" fill="#93c5fd" font-family="Inter,sans-serif" font-weight="600" text-anchor="middle">Folder 01 — Infrastruktur</text>
|
||||
</svg>
|
||||
</div>
|
||||
|
||||
<div class="portal-body">
|
||||
<div class="portal-badge" style="background:rgba(59,130,246,0.12);color:#1A6FA8;border:1px solid rgba(59,130,246,0.2);">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M3 12h18M3 6h18M3 18h18"/></svg>
|
||||
Peta Infrastruktur
|
||||
</div>
|
||||
<div class="portal-title">Jaringan Jalan, SPBU & Parsil</div>
|
||||
<div class="portal-desc">Kelola dan pantau infrastruktur fisik kota: ruas jalan berdasarkan status, titik SPBU 24 jam & reguler, serta bidang parsil kavling seluruh wilayah Pontianak.</div>
|
||||
<div class="layer-chips">
|
||||
<span class="lc"><span class="lc-dot" style="background:#ef4444;"></span>Jalan Nasional</span>
|
||||
<span class="lc"><span class="lc-dot" style="background:#f59e0b;"></span>Jalan Provinsi</span>
|
||||
<span class="lc"><span class="lc-dot" style="background:#10b981;"></span>SPBU 24 Jam</span>
|
||||
<span class="lc"><span class="lc-dot" style="background:#ef4444;"></span>SPBU Reguler</span>
|
||||
<span class="lc"><span class="lc-dot" style="background:#8b5cf6;"></span>Parsil Kavling</span>
|
||||
</div>
|
||||
<span class="portal-enter" style="background:#1A6FA8;">
|
||||
Masuk ke Peta Infrastruktur
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.2"><path d="M5 12h14M12 5l7 7-7 7"/></svg>
|
||||
</span>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
<!-- FOLDER 02: Sosial & Warga -->
|
||||
<a href="http://localhost/wib_gis/02/login.php" class="portal-card">
|
||||
<!-- MAP PREVIEW -->
|
||||
<div class="portal-map" style="background:#1A3A2A;">
|
||||
<svg viewBox="0 0 480 210" xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMid slice">
|
||||
<!-- BG -->
|
||||
<rect width="480" height="210" fill="#1A3A2A"/>
|
||||
<!-- subtle terrain -->
|
||||
<path d="M0 120 Q80 105 160 118 Q240 130 320 115 Q400 100 480 112" stroke="rgba(255,255,255,0.06)" stroke-width="28" fill="none"/>
|
||||
<!-- Radius circles rumah ibadah -->
|
||||
<circle cx="200" cy="95" r="58" fill="rgba(16,185,129,0.08)" stroke="#10b981" stroke-width="1" stroke-dasharray="4 3"/>
|
||||
<circle cx="340" cy="115" r="48" fill="rgba(16,185,129,0.08)" stroke="#10b981" stroke-width="1" stroke-dasharray="4 3"/>
|
||||
<!-- Masjid pins -->
|
||||
<!-- pin 1 -->
|
||||
<path d="M200 66C195.58 66 192 69.58 192 74c0 5.06 8 12.5 8 12.5s8-7.44 8-12.5c0-4.42-3.58-8-8-8z" fill="#10b981" stroke="#fff" stroke-width="1.2"/>
|
||||
<circle cx="200" cy="74" r="2.5" fill="white"/>
|
||||
<!-- pin 2 -->
|
||||
<path d="M340 85C335.58 85 332 88.58 332 93c0 5.06 8 12.5 8 12.5s8-7.44 8-12.5c0-4.42-3.58-8-8-8z" fill="#10b981" stroke="#fff" stroke-width="1.2"/>
|
||||
<circle cx="340" cy="93" r="2.5" fill="white"/>
|
||||
<!-- Warga miskin dalam radius - ungu -->
|
||||
<path d="M185 90C180.58 90 177 93.58 177 98c0 5.06 8 12.5 8 12.5s8-7.44 8-12.5c0-4.42-3.58-8-8-8z" fill="#6366f1" stroke="#fff" stroke-width="1.2"/>
|
||||
<circle cx="185" cy="98" r="2.5" fill="white"/>
|
||||
<path d="M215 105C210.58 105 207 108.58 207 113c0 5.06 8 12.5 8 12.5s8-7.44 8-12.5c0-4.42-3.58-8-8-8z" fill="#6366f1" stroke="#fff" stroke-width="1.2"/>
|
||||
<circle cx="215" cy="113" r="2.5" fill="white"/>
|
||||
<path d="M323 118C318.58 118 315 121.58 315 126c0 5.06 8 12.5 8 12.5s8-7.44 8-12.5c0-4.42-3.58-8-8-8z" fill="#6366f1" stroke="#fff" stroke-width="1.2"/>
|
||||
<circle cx="323" cy="126" r="2.5" fill="white"/>
|
||||
<!-- Warga miskin luar radius - pink -->
|
||||
<path d="M90 80C85.58 80 82 83.58 82 88c0 5.06 8 12.5 8 12.5s8-7.44 8-12.5c0-4.42-3.58-8-8-8z" fill="#db2777" stroke="#fff" stroke-width="1.2"/>
|
||||
<circle cx="90" cy="88" r="2.5" fill="white"/>
|
||||
<path d="M420 130C415.58 130 412 133.58 412 138c0 5.06 8 12.5 8 12.5s8-7.44 8-12.5c0-4.42-3.58-8-8-8z" fill="#db2777" stroke="#fff" stroke-width="1.2"/>
|
||||
<circle cx="420" cy="138" r="2.5" fill="white"/>
|
||||
<!-- Laporan merah segitiga -->
|
||||
<polygon points="130,140 138,155 122,155" fill="#e11d48" stroke="#fff" stroke-width="1.2" opacity="0.9"/>
|
||||
<polygon points="280,158 288,173 272,173" fill="#e11d48" stroke="#fff" stroke-width="1.2" opacity="0.9"/>
|
||||
<polygon points="390,68 398,83 382,83" fill="#e11d48" stroke="#fff" stroke-width="1.2" opacity="0.85"/>
|
||||
|
||||
<!-- Legend box -->
|
||||
<rect x="8" y="138" width="140" height="65" rx="6" fill="rgba(10,36,24,0.85)" stroke="rgba(255,255,255,0.12)" stroke-width="0.8"/>
|
||||
<text x="18" y="154" font-size="9" fill="rgba(255,255,255,0.5)" font-family="Inter,sans-serif" font-weight="600" letter-spacing="0.04em">LAPISAN AKTIF</text>
|
||||
<line x1="18" y1="157" x2="140" y2="157" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/>
|
||||
<circle cx="23" cy="166" r="4" fill="#10b981"/><text x="31" y="169" font-size="9" fill="rgba(255,255,255,0.7)" font-family="Inter,sans-serif">Rumah Ibadah</text>
|
||||
<circle cx="23" cy="179" r="4" fill="#6366f1"/><text x="31" y="182" font-size="9" fill="rgba(255,255,255,0.7)" font-family="Inter,sans-serif">Warga (dalam radius)</text>
|
||||
<polygon points="18,190 26,198 10,198" fill="#e11d48"/><text x="31" y="197" font-size="9" fill="rgba(255,255,255,0.7)" font-family="Inter,sans-serif">Laporan Pengaduan</text>
|
||||
|
||||
<!-- Folder label pill -->
|
||||
<rect x="340" y="8" width="130" height="22" rx="11" fill="rgba(16,185,129,0.2)" stroke="rgba(52,211,153,0.35)" stroke-width="0.8"/>
|
||||
<text x="405" y="22" font-size="10" fill="#6ee7b7" font-family="Inter,sans-serif" font-weight="600" text-anchor="middle">Folder 02 — Sosial & Warga</text>
|
||||
</svg>
|
||||
</div>
|
||||
|
||||
<div class="portal-body">
|
||||
<div class="portal-badge" style="background:rgba(16,185,129,0.12);color:#1D7A5F;border:1px solid rgba(16,185,129,0.2);">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M17 21v-2a4 4 0 00-4-4H5a4 4 0 00-4 4v2"/><circle cx="9" cy="7" r="4"/></svg>
|
||||
Peta Sosial & Warga
|
||||
</div>
|
||||
<div class="portal-title">Data Warga, Ibadah & Laporan</div>
|
||||
<div class="portal-desc">Pantau sebaran warga miskin & analisis keterjangkauan radius rumah ibadah, serta kelola laporan pengaduan masyarakat berbasis lokasi geografis.</div>
|
||||
<div class="layer-chips">
|
||||
<span class="lc"><span class="lc-dot" style="background:#10b981;"></span>Rumah Ibadah</span>
|
||||
<span class="lc"><span class="lc-dot" style="background:#6366f1;"></span>Warga (dalam radius)</span>
|
||||
<span class="lc"><span class="lc-dot" style="background:#db2777;"></span>Warga (luar radius)</span>
|
||||
<span class="lc"><span class="lc-dot" style="background:#e11d48;"></span>Pengaduan</span>
|
||||
</div>
|
||||
<span class="portal-enter" style="background:#1D7A5F;">
|
||||
Masuk ke Peta Sosial
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.2"><path d="M5 12h14M12 5l7 7-7 7"/></svg>
|
||||
</span>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- STAT BAR -->
|
||||
<div class="section-label">Ringkasan Data Keseluruhan</div>
|
||||
<div class="stat-bar">
|
||||
<div class="sb-card">
|
||||
<div class="sb-icon c-blue-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="1.8" class="c-blue-icon"><path d="M3 12h18M3 6h18M3 18h18"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="sb-label">Ruas Jalan</div>
|
||||
<div class="sb-val c-blue-text">—</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sb-card">
|
||||
<div class="sb-icon c-purple-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="1.8" class="c-purple-icon"><rect x="3" y="3" width="7" height="7"/><rect x="14" y="3" width="7" height="7"/><rect x="14" y="14" width="7" height="7"/><rect x="3" y="14" width="7" height="7"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="sb-label">Bidang Parsil</div>
|
||||
<div class="sb-val" style="color:var(--purple);">—</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sb-card">
|
||||
<div class="sb-icon c-amber-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="1.8" class="c-amber-icon"><path d="M3 22V6a2 2 0 012-2h8a2 2 0 012 2v16"/><path d="M15 10h2a2 2 0 012 2v6a1 1 0 001 1v0a1 1 0 001-1v-9l-3-5"/><line x1="3" y1="22" x2="15" y2="22"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="sb-label">Titik SPBU</div>
|
||||
<div class="sb-val c-amber-text">—</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sb-card">
|
||||
<div class="sb-icon c-green-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="1.8" class="c-green-icon"><path d="M18.364 5.636a9 9 0 010 12.728M15.536 8.464a5 5 0 010 7.072"/><circle cx="12" cy="12" r="1"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="sb-label">Rumah Ibadah</div>
|
||||
<div class="sb-val c-green-text">—</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sb-card">
|
||||
<div class="sb-icon" style="background:#EEF0FE;">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="1.8" style="stroke:#5B5BD6;"><path d="M17 21v-2a4 4 0 00-4-4H5a4 4 0 00-4 4v2"/><circle cx="9" cy="7" r="4"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="sb-label">Data Warga</div>
|
||||
<div class="sb-val" style="color:#5B5BD6;">—</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sb-card">
|
||||
<div class="sb-icon c-red-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="1.8" class="c-red-icon"><path d="M21 15a2 2 0 01-2 2H7l-4 4V5a2 2 0 012-2h14a2 2 0 012 2z"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="sb-label">Pengaduan</div>
|
||||
<div class="sb-val c-red-text">—</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BOTTOM GRID -->
|
||||
<div class="bottom-grid">
|
||||
<!-- LAPISAN -->
|
||||
<div class="card">
|
||||
<div class="card-head">
|
||||
<div class="card-head-title">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="#1A6FA8"><path d="M12 2L2 7l10 5 10-5-10-5zM2 17l10 5 10-5M2 12l10 5 10-5"/></svg>
|
||||
Semua Lapisan Data
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="layer-list">
|
||||
<div class="layer-item">
|
||||
<div class="l-dot" style="background:#ef4444;"></div>
|
||||
<span class="l-name">Jalan Nasional</span>
|
||||
<span class="l-folder" style="background:#FEF2F2;color:#DC2626;">Folder 01</span>
|
||||
</div>
|
||||
<div class="layer-item">
|
||||
<div class="l-dot" style="background:#f59e0b;"></div>
|
||||
<span class="l-name">Jalan Provinsi</span>
|
||||
<span class="l-folder" style="background:#FEF2F2;color:#DC2626;">Folder 01</span>
|
||||
</div>
|
||||
<div class="layer-item">
|
||||
<div class="l-dot" style="background:#10b981;"></div>
|
||||
<span class="l-name">SPBU 24 Jam</span>
|
||||
<span class="l-folder" style="background:#FEF2F2;color:#DC2626;">Folder 01</span>
|
||||
</div>
|
||||
<div class="layer-item">
|
||||
<div class="l-dot" style="background:#8b5cf6;"></div>
|
||||
<span class="l-name">Parsil Kavling</span>
|
||||
<span class="l-folder" style="background:#FEF2F2;color:#DC2626;">Folder 01</span>
|
||||
</div>
|
||||
<div class="layer-item">
|
||||
<div class="l-dot" style="background:#10b981;"></div>
|
||||
<span class="l-name">Rumah Ibadah</span>
|
||||
<span class="l-folder" style="background:#E6F5F0;color:#1D7A5F;">Folder 02</span>
|
||||
</div>
|
||||
<div class="layer-item">
|
||||
<div class="l-dot" style="background:#6366f1;"></div>
|
||||
<span class="l-name">Data Warga Miskin</span>
|
||||
<span class="l-folder" style="background:#E6F5F0;color:#1D7A5F;">Folder 02</span>
|
||||
</div>
|
||||
<div class="layer-item">
|
||||
<div class="l-dot" style="background:#e11d48;"></div>
|
||||
<span class="l-name">Pengaduan Warga</span>
|
||||
<span class="l-folder" style="background:#E6F5F0;color:#1D7A5F;">Folder 02</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- AKTIVITAS -->
|
||||
<div class="card">
|
||||
<div class="card-head">
|
||||
<div class="card-head-title">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="#1D7A5F"><polyline points="22 12 18 12 15 21 9 3 6 12 2 12"/></svg>
|
||||
Aktivitas Sistem
|
||||
</div>
|
||||
<span class="badge badge-green" id="waktu-update">—</span>
|
||||
</div>
|
||||
<div class="card-body" style="padding:8px 16px">
|
||||
<div class="act-list">
|
||||
<div class="act-item">
|
||||
<div class="act-ic c-blue-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="2" class="c-blue-icon"><path d="M3 12h18M3 6h18M3 18h18"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="act-title">Data jalan diperbarui</div>
|
||||
<div class="act-meta">Folder 01 · edit_jalan.php</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="act-item">
|
||||
<div class="act-ic c-purple-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="2" class="c-purple-icon"><rect x="3" y="3" width="7" height="7"/><rect x="14" y="3" width="7" height="7"/><rect x="14" y="14" width="7" height="7"/><rect x="3" y="14" width="7" height="7"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="act-title">Parsil baru disimpan</div>
|
||||
<div class="act-meta">Folder 01 · simpan_parsil.php</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="act-item">
|
||||
<div class="act-ic c-green-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="2" class="c-green-icon"><path d="M18.364 5.636a9 9 0 010 12.728"/><circle cx="12" cy="12" r="1"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="act-title">Radius ibadah diperbarui</div>
|
||||
<div class="act-meta">Folder 02 · update_radius.php</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="act-item">
|
||||
<div class="act-ic c-red-bg">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke-width="2" class="c-red-icon"><path d="M21 15a2 2 0 01-2 2H7l-4 4V5a2 2 0 012-2h14a2 2 0 012 2z"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="act-title">Laporan pengaduan masuk</div>
|
||||
<div class="act-meta">Folder 02 · simpan_laporan_cepat.php</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- ACCOUNT -->
|
||||
<div class="account-card">
|
||||
<div class="ac-header">
|
||||
<div class="ac-header-ic">
|
||||
<svg viewBox="0 0 24 24" fill="none"><path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z" stroke="rgba(255,255,255,0.8)" stroke-width="1.8"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<div class="ac-header-title">Akses Petugas</div>
|
||||
<div class="ac-header-sub">Login berlaku untuk kedua modul peta (Folder 01 & 02)</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ac-body">
|
||||
<div class="ac-item">
|
||||
<div class="av" style="background:#E6F1FB;color:#1A6FA8;">AD</div>
|
||||
<div>
|
||||
<div class="ac-name">admin</div>
|
||||
<div class="ac-pass">admin123</div>
|
||||
</div>
|
||||
<span class="ac-role" style="background:#E6F1FB;color:#1A6FA8;">Administrator</span>
|
||||
</div>
|
||||
<div class="ac-item">
|
||||
<div class="av" style="background:#FEF3E2;color:#B86800;">WK</div>
|
||||
<div>
|
||||
<div class="ac-name">walikota</div>
|
||||
<div class="ac-pass">walikota123</div>
|
||||
</div>
|
||||
<span class="ac-role" style="background:#FEF3E2;color:#B86800;">Walikota</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ac-foot" style="display:grid;grid-template-columns:1fr 1fr;gap:8px;">
|
||||
<a href="http://localhost/wib_gis/01/login.php" class="btn-login-full" style="background:#1A6FA8;">
|
||||
<svg viewBox="0 0 24 24"><path d="M15 3h4a2 2 0 012 2v14a2 2 0 01-2 2h-4"/><polyline points="10 17 15 12 10 7"/><line x1="15" y1="12" x2="3" y2="12"/></svg>
|
||||
Login Peta Infrastruktur
|
||||
</a>
|
||||
<a href="http://localhost/wib_gis/02/login.php" class="btn-login-full" style="background:#1D7A5F;">
|
||||
<svg viewBox="0 0 24 24"><path d="M15 3h4a2 2 0 012 2v14a2 2 0 01-2 2h-4"/><polyline points="10 17 15 12 10 7"/><line x1="15" y1="12" x2="3" y2="12"/></svg>
|
||||
Login Peta Sosial
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- FOOTER -->
|
||||
<footer class="footer">
|
||||
<p>© 2026 WebGIS Pontianak · Pemerintah Kota Pontianak</p>
|
||||
<div class="footer-links">
|
||||
<a href="http://localhost/wib_gis/01/login.php">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor"><path d="M3 12h18M3 6h18M3 18h18"/></svg>
|
||||
Peta Infrastruktur
|
||||
</a>
|
||||
<a href="http://localhost/wib_gis/02/login.php">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor"><path d="M17 21v-2a4 4 0 00-4-4H5a4 4 0 00-4 4v2"/><circle cx="9" cy="7" r="4"/></svg>
|
||||
Peta Sosial
|
||||
</a>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
<script>
|
||||
const now = new Date();
|
||||
const pad = n => n.toString().padStart(2,'0');
|
||||
document.getElementById('waktu-update').textContent =
|
||||
'Update ' + pad(now.getHours()) + ':' + pad(now.getMinutes()) + ' WIB';
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
+139
@@ -0,0 +1,139 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
// 1. Ambil ID dari URL
|
||||
$id = isset($_GET['id']) ? $_GET['id'] : '';
|
||||
|
||||
// 2. Ambil data lama dari database berdasarkan ID
|
||||
$query = mysqli_query($conn, "SELECT * FROM spbu WHERE id='$id'");
|
||||
$data = mysqli_fetch_array($query);
|
||||
|
||||
// Jika data tidak ditemukan, balikkan ke index
|
||||
if (!$data) {
|
||||
echo "<script>alert('Data tidak ditemukan!'); window.location='index.php';</script>";
|
||||
exit;
|
||||
}
|
||||
|
||||
// 3. Proses Update saat tombol Simpan ditekan
|
||||
if (isset($_POST['update'])) {
|
||||
$nama = mysqli_real_escape_string($conn, $_POST['nama']);
|
||||
$wa = mysqli_real_escape_string($conn, $_POST['wa']);
|
||||
$jam = $_POST['jam'];
|
||||
|
||||
// Update ke tabel spbu
|
||||
$sql = "UPDATE spbu SET nama_spbu='$nama', no_whatsapp='$wa', status_24jam='$jam' WHERE id='$id'";
|
||||
|
||||
if (mysqli_query($conn, $sql)) {
|
||||
echo "<script>alert('Data SPBU Berhasil Diperbarui!'); window.location='index.php';</script>";
|
||||
} else {
|
||||
echo "Gagal Update: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Edit Data SPBU</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
min-height: 100vh;
|
||||
margin: 0;
|
||||
background: #f0f2f5;
|
||||
}
|
||||
.card {
|
||||
background: white;
|
||||
padding: 30px;
|
||||
border-radius: 15px;
|
||||
box-shadow: 0 10px 25px rgba(0,0,0,0.1);
|
||||
width: 100%;
|
||||
max-width: 400px;
|
||||
}
|
||||
h3 {
|
||||
margin-top: 0;
|
||||
color: #1a73e8;
|
||||
text-align: center;
|
||||
border-bottom: 2px solid #f0f2f5;
|
||||
padding-bottom: 15px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
label {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: #555;
|
||||
display: block;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
input, select {
|
||||
width: 100%;
|
||||
padding: 12px;
|
||||
margin-bottom: 20px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 8px;
|
||||
box-sizing: border-box;
|
||||
font-size: 14px;
|
||||
outline: none;
|
||||
transition: 0.3s;
|
||||
}
|
||||
input:focus, select:focus {
|
||||
border-color: #1a73e8;
|
||||
box-shadow: 0 0 0 2px rgba(26,115,232,0.2);
|
||||
}
|
||||
button {
|
||||
width: 100%;
|
||||
background: #1a73e8;
|
||||
color: white;
|
||||
border: none;
|
||||
padding: 12px;
|
||||
cursor: pointer;
|
||||
border-radius: 8px;
|
||||
font-weight: bold;
|
||||
font-size: 15px;
|
||||
transition: 0.3s;
|
||||
}
|
||||
button:hover {
|
||||
background: #1557b0;
|
||||
box-shadow: 0 4px 12px rgba(26,115,232,0.3);
|
||||
}
|
||||
.btn-back {
|
||||
display: block;
|
||||
text-align: center;
|
||||
margin-top: 15px;
|
||||
font-size: 13px;
|
||||
text-decoration: none;
|
||||
color: #666;
|
||||
}
|
||||
.btn-back:hover {
|
||||
color: #333;
|
||||
text-decoration: underline;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="card">
|
||||
<h3>Edit Data SPBU</h3>
|
||||
<form method="POST">
|
||||
<label>NAMA SPBU</label>
|
||||
<input type="text" name="nama" value="<?= htmlspecialchars($data['nama_spbu']) ?>" placeholder="Masukkan nama SPBU" required>
|
||||
|
||||
<label>NOMOR WHATSAPP</label>
|
||||
<input type="text" name="wa" value="<?= htmlspecialchars($data['no_whatsapp']) ?>" placeholder="Contoh: 08123456789" required>
|
||||
|
||||
<label>STATUS OPERASIONAL</label>
|
||||
<select name="jam">
|
||||
<option value="Ya" <?= ($data['status_24jam'] == 'Ya') ? 'selected' : '' ?>>Buka 24 Jam (Ikon Hijau)</option>
|
||||
<option value="Tidak" <?= ($data['status_24jam'] == 'Tidak') ? 'selected' : '' ?>>Tutup Malam (Ikon Merah)</option>
|
||||
</select>
|
||||
|
||||
<button type="submit" name="update">SIMPAN PERUBAHAN</button>
|
||||
<a href="index.php" class="btn-back">← Batal dan Kembali</a>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
$id = $_GET['id'];
|
||||
$data = mysqli_fetch_array(mysqli_query($conn, "SELECT * FROM jalan WHERE id='$id'"));
|
||||
|
||||
if (isset($_POST['update'])) {
|
||||
$nama = $_POST['nama_jalan'];
|
||||
$status = $_POST['status_jalan'];
|
||||
mysqli_query($conn, "UPDATE jalan SET nama_jalan='$nama', status_jalan='$status' WHERE id='$id'");
|
||||
echo "<script>alert('Data Jalan Diperbarui!'); window.location='index.php';</script>";
|
||||
}
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Edit Jalan</title>
|
||||
<style>
|
||||
body { font-family: sans-serif; display: flex; justify-content: center; padding: 50px; background: #f0f2f5; }
|
||||
.card { background: white; padding: 25px; border-radius: 12px; box-shadow: 0 5px 15px rgba(0,0,0,0.1); width: 350px; }
|
||||
input, select { width: 100%; padding: 10px; margin: 10px 0; border: 1px solid #ddd; border-radius: 5px; }
|
||||
button { width: 100%; background: #1a73e8; color: white; border: none; padding: 12px; border-radius: 5px; cursor: pointer; font-weight: bold; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="card">
|
||||
<h3>Edit Data Jalan</h3>
|
||||
<form method="POST">
|
||||
<label>Nama Jalan</label>
|
||||
<input type="text" name="nama_jalan" value="<?= $data['nama_jalan'] ?>" required>
|
||||
<label>Status Jalan</label>
|
||||
<select name="status_jalan">
|
||||
<option value="Jalan Nasional" <?= ($data['status_jalan'] == 'Jalan Nasional') ? 'selected' : '' ?>>Jalan Nasional</option>
|
||||
<option value="Jalan Provinsi" <?= ($data['status_jalan'] == 'Jalan Provinsi') ? 'selected' : '' ?>>Jalan Provinsi</option>
|
||||
<option value="Jalan Kabupaten" <?= ($data['status_jalan'] == 'Jalan Kabupaten') ? 'selected' : '' ?>>Jalan Kabupaten</option>
|
||||
</select>
|
||||
<button type="submit" name="update">Simpan Perubahan</button>
|
||||
<center><br><a href="index.php" style="text-decoration:none; color:gray; font-size:13px">← Kembali</a></center>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
$id = $_GET['id'];
|
||||
$data = mysqli_fetch_array(mysqli_query($conn, "SELECT * FROM parsil WHERE id='$id'"));
|
||||
|
||||
if (isset($_POST['update'])) {
|
||||
$pemilik = $_POST['nama_pemilik'];
|
||||
$status = $_POST['status_kepemilikan'];
|
||||
mysqli_query($conn, "UPDATE parsil SET nama_pemilik='$pemilik', status_kepemilikan='$status' WHERE id='$id'");
|
||||
echo "<script>alert('Data Parsil Diperbarui!'); window.location='index.php';</script>";
|
||||
}
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Edit Parsil</title>
|
||||
<style>
|
||||
body { font-family: sans-serif; display: flex; justify-content: center; padding: 50px; background: #f0f2f5; }
|
||||
.card { background: white; padding: 25px; border-radius: 12px; box-shadow: 0 5px 15px rgba(0,0,0,0.1); width: 350px; }
|
||||
input, select { width: 100%; padding: 10px; margin: 10px 0; border: 1px solid #ddd; border-radius: 5px; }
|
||||
button { width: 100%; background: #1a73e8; color: white; border: none; padding: 12px; border-radius: 5px; cursor: pointer; font-weight: bold; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="card">
|
||||
<h3>Edit Data Parsil</h3>
|
||||
<form method="POST">
|
||||
<label>Nama Pemilik</label>
|
||||
<input type="text" name="nama_pemilik" value="<?= $data['nama_pemilik'] ?>" required>
|
||||
<label>Status Kepemilikan</label>
|
||||
<select name="status_kepemilikan">
|
||||
<option value="SHM" <?= ($data['status_kepemilikan'] == 'SHM') ? 'selected' : '' ?>>SHM</option>
|
||||
<option value="HGB" <?= ($data['status_kepemilikan'] == 'HGB') ? 'selected' : '' ?>>HGB</option>
|
||||
<option value="HGU" <?= ($data['status_kepemilikan'] == 'HGU') ? 'selected' : '' ?>>HGU</option>
|
||||
<option value="HP" <?= ($data['status_kepemilikan'] == 'HP') ? 'selected' : '' ?>>HP</option>
|
||||
</select>
|
||||
<button type="submit" name="update">Simpan Perubahan</button>
|
||||
<center><br><a href="index.php" style="text-decoration:none; color:gray; font-size:13px">← Kembali</a></center>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
// 1. Cek apakah ada ID yang dikirim melalui URL
|
||||
if (isset($_GET['id']) && $_GET['id'] != "") {
|
||||
|
||||
$id = $_GET['id'];
|
||||
|
||||
// 2. Gunakan mysqli_real_escape_string untuk keamanan tambahan
|
||||
$id = mysqli_real_escape_string($conn, $id);
|
||||
|
||||
// 3. Jalankan query hapus
|
||||
$query = "DELETE FROM spbu WHERE id='$id'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
// Jika berhasil, munculkan pesan dan kembali ke index
|
||||
echo "<script>
|
||||
alert('Data SPBU Berhasil Dihapus!');
|
||||
window.location='index.php';
|
||||
</script>";
|
||||
} else {
|
||||
// Jika gagal, tampilkan pesan error
|
||||
echo "<script>
|
||||
alert('Gagal menghapus data: " . mysqli_error($conn) . "');
|
||||
window.location='index.php';
|
||||
</script>";
|
||||
}
|
||||
|
||||
} else {
|
||||
// Jika tidak ada ID di URL, langsung lempar balik ke index
|
||||
header("location:index.php");
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
if (isset($_GET['id'])) {
|
||||
$id = mysqli_real_escape_string($conn, $_GET['id']);
|
||||
if (mysqli_query($conn, "DELETE FROM jalan WHERE id='$id'")) {
|
||||
echo "<script>alert('Data Jalan Berhasil Dihapus!'); window.location='index.php';</script>";
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if (isset($_GET['id'])) {
|
||||
$id = (int)$_GET['id'];
|
||||
|
||||
$query = "DELETE FROM parsil WHERE id=$id";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>
|
||||
alert('Data Parsil Berhasil Dihapus!');
|
||||
window.location='index.php';
|
||||
</script>";
|
||||
} else {
|
||||
echo "Gagal menghapus data: " . mysqli_error($conn);
|
||||
}
|
||||
} else {
|
||||
header("Location: index.php");
|
||||
}
|
||||
?>
|
||||
+1176
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
$host = "localhost";
|
||||
$user = "root";
|
||||
$pass = "";
|
||||
$db = "db_gis_spbu"; // Sesuaikan dengan nama database kamu
|
||||
|
||||
$conn = mysqli_connect($host, $user, $pass, $db);
|
||||
|
||||
if (!$conn) {
|
||||
die("Koneksi ke database gagal: " . mysqli_connect_error());
|
||||
}
|
||||
?>
|
||||
+527
@@ -0,0 +1,527 @@
|
||||
<?php
|
||||
session_start();
|
||||
include 'koneksi.php';
|
||||
|
||||
$error = '';
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
$username = trim($_POST['username'] ?? '');
|
||||
$password = md5(trim($_POST['password'] ?? ''));
|
||||
$q = mysqli_query($conn, "SELECT * FROM users WHERE username='$username' AND password='$password' LIMIT 1");
|
||||
if ($q && mysqli_num_rows($q) > 0) {
|
||||
$user = mysqli_fetch_assoc($q);
|
||||
$_SESSION['user_id'] = $user['id'];
|
||||
$_SESSION['user_nama'] = $user['nama'];
|
||||
$_SESSION['user_role'] = $user['role'];
|
||||
header('Location: index.php');
|
||||
exit;
|
||||
} else {
|
||||
$error = 'Username atau password salah!';
|
||||
}
|
||||
}
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="id" data-theme="dark">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Login - WebGIS Pontianak</title>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
||||
<style>
|
||||
:root {
|
||||
--bg: #0b1120;
|
||||
--bg2: #111827;
|
||||
--card: #161f30;
|
||||
--border: rgba(255,255,255,0.07);
|
||||
--border2: rgba(255,255,255,0.13);
|
||||
--text: #f1f5f9;
|
||||
--muted: #94a3b8;
|
||||
--accent: #3b82f6;
|
||||
--accent2: #60a5fa;
|
||||
--btn: #3b82f6;
|
||||
--btn-text: #ffffff;
|
||||
--input-bg: #1e2b40;
|
||||
--input-bd: rgba(255,255,255,0.1);
|
||||
--input-focus: #3b82f6;
|
||||
--tag-bg: rgba(59,130,246,0.15);
|
||||
--tag-col: #93c5fd;
|
||||
--shadow: 0 40px 100px rgba(0,0,0,0.6);
|
||||
--err-bg: rgba(239,68,68,0.12);
|
||||
--err-bd: rgba(239,68,68,0.3);
|
||||
--err-col: #f87171;
|
||||
}
|
||||
|
||||
[data-theme="light"] {
|
||||
--bg: #e8eef7;
|
||||
--bg2: #dde5f0;
|
||||
--card: #ffffff;
|
||||
--border: rgba(0,0,0,0.06);
|
||||
--border2: rgba(0,0,0,0.12);
|
||||
--text: #0f172a;
|
||||
--muted: #64748b;
|
||||
--accent: #2563eb;
|
||||
--accent2: #3b82f6;
|
||||
--btn: #2563eb;
|
||||
--btn-text: #ffffff;
|
||||
--input-bg: #f1f5fb;
|
||||
--input-bd: rgba(0,0,0,0.1);
|
||||
--input-focus: #2563eb;
|
||||
--tag-bg: #eff6ff;
|
||||
--tag-col: #1d4ed8;
|
||||
--shadow: 0 40px 100px rgba(0,0,0,0.15);
|
||||
--err-bg: #fef2f2;
|
||||
--err-bd: #fecaca;
|
||||
--err-col: #dc2626;
|
||||
}
|
||||
|
||||
* { box-sizing: border-box; margin: 0; padding: 0; }
|
||||
html, body { height: 100%; }
|
||||
|
||||
body {
|
||||
font-family: 'Sora', sans-serif;
|
||||
background: var(--bg);
|
||||
min-height: 100vh;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 20px;
|
||||
transition: background 0.4s;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* background orbs */
|
||||
.orb {
|
||||
position: fixed;
|
||||
border-radius: 50%;
|
||||
filter: blur(80px);
|
||||
opacity: 0.25;
|
||||
pointer-events: none;
|
||||
transition: opacity 0.4s;
|
||||
}
|
||||
.orb1 { width: 500px; height: 500px; background: #3b82f6; top: -150px; left: -100px; }
|
||||
.orb2 { width: 400px; height: 400px; background: #8b5cf6; bottom: -100px; right: -80px; }
|
||||
.orb3 { width: 300px; height: 300px; background: #06b6d4; top: 40%; left: 40%; }
|
||||
|
||||
[data-theme="light"] .orb { opacity: 0.12; }
|
||||
|
||||
/* theme toggle */
|
||||
.theme-toggle {
|
||||
position: fixed;
|
||||
top: 20px; right: 20px;
|
||||
width: 44px; height: 44px;
|
||||
border-radius: 12px;
|
||||
background: var(--card);
|
||||
border: 1px solid var(--border2);
|
||||
color: var(--muted);
|
||||
font-size: 16px;
|
||||
cursor: pointer;
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
transition: all 0.3s;
|
||||
z-index: 100;
|
||||
box-shadow: 0 4px 20px rgba(0,0,0,0.2);
|
||||
}
|
||||
.theme-toggle:hover { color: var(--accent); border-color: var(--accent); }
|
||||
|
||||
/* card */
|
||||
.card {
|
||||
background: var(--card);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 24px;
|
||||
width: 100%;
|
||||
max-width: 440px;
|
||||
padding: 48px 44px;
|
||||
box-shadow: var(--shadow);
|
||||
position: relative;
|
||||
z-index: 10;
|
||||
transition: background 0.4s, border-color 0.4s, box-shadow 0.4s;
|
||||
animation: fadeUp 0.5s ease both;
|
||||
}
|
||||
|
||||
@keyframes fadeUp {
|
||||
from { opacity: 0; transform: translateY(24px); }
|
||||
to { opacity: 1; transform: translateY(0); }
|
||||
}
|
||||
|
||||
/* logo */
|
||||
.logo-wrap {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 14px;
|
||||
margin-bottom: 36px;
|
||||
}
|
||||
|
||||
.logo-icon {
|
||||
width: 52px; height: 52px;
|
||||
border-radius: 16px;
|
||||
background: linear-gradient(135deg, #2563eb, #7c3aed);
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
font-size: 22px;
|
||||
color: #fff;
|
||||
flex-shrink: 0;
|
||||
box-shadow: 0 8px 24px rgba(37,99,235,0.4);
|
||||
}
|
||||
|
||||
.logo-text h1 {
|
||||
font-size: 18px;
|
||||
font-weight: 700;
|
||||
color: var(--text);
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.logo-text p {
|
||||
font-size: 11px;
|
||||
color: var(--muted);
|
||||
margin-top: 2px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
/* badge */
|
||||
.badge-live {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
background: var(--tag-bg);
|
||||
color: var(--tag-col);
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
padding: 4px 10px;
|
||||
border-radius: 999px;
|
||||
margin-bottom: 20px;
|
||||
letter-spacing: 0.04em;
|
||||
transition: background 0.4s, color 0.4s;
|
||||
}
|
||||
|
||||
.dot-live {
|
||||
width: 6px; height: 6px;
|
||||
border-radius: 50%;
|
||||
background: currentColor;
|
||||
animation: pulse 1.8s infinite;
|
||||
}
|
||||
|
||||
@keyframes pulse {
|
||||
0%,100% { opacity: 1; transform: scale(1); }
|
||||
50% { opacity: 0.4; transform: scale(0.7); }
|
||||
}
|
||||
|
||||
/* heading */
|
||||
.heading {
|
||||
font-size: 26px;
|
||||
font-weight: 700;
|
||||
color: var(--text);
|
||||
line-height: 1.2;
|
||||
margin-bottom: 6px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.subheading {
|
||||
font-size: 13px;
|
||||
color: var(--muted);
|
||||
margin-bottom: 28px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
/* divider */
|
||||
.divider {
|
||||
height: 1px;
|
||||
background: var(--border);
|
||||
margin: 0 -44px 28px;
|
||||
transition: background 0.4s;
|
||||
}
|
||||
|
||||
/* form */
|
||||
.field { margin-bottom: 18px; }
|
||||
|
||||
.field label {
|
||||
display: block;
|
||||
font-size: 11px;
|
||||
font-weight: 600;
|
||||
color: var(--muted);
|
||||
letter-spacing: 0.06em;
|
||||
text-transform: uppercase;
|
||||
margin-bottom: 8px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.input-wrap { position: relative; }
|
||||
|
||||
.input-wrap i.ico {
|
||||
position: absolute;
|
||||
left: 14px; top: 50%;
|
||||
transform: translateY(-50%);
|
||||
color: var(--muted);
|
||||
font-size: 14px;
|
||||
pointer-events: none;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.input-wrap input {
|
||||
width: 100%;
|
||||
padding: 13px 14px 13px 42px;
|
||||
background: var(--input-bg);
|
||||
border: 1.5px solid var(--input-bd);
|
||||
border-radius: 12px;
|
||||
font-size: 14px;
|
||||
font-family: 'Sora', sans-serif;
|
||||
color: var(--text);
|
||||
outline: none;
|
||||
transition: all 0.25s;
|
||||
}
|
||||
|
||||
.input-wrap input::placeholder { color: var(--muted); opacity: 0.6; }
|
||||
.input-wrap input:focus { border-color: var(--input-focus); background: var(--input-bg); box-shadow: 0 0 0 3px rgba(59,130,246,0.12); }
|
||||
|
||||
/* eye toggle */
|
||||
.eye-btn {
|
||||
position: absolute;
|
||||
right: 14px; top: 50%;
|
||||
transform: translateY(-50%);
|
||||
background: none; border: none;
|
||||
color: var(--muted); font-size: 14px;
|
||||
cursor: pointer; padding: 0;
|
||||
transition: color 0.2s;
|
||||
}
|
||||
.eye-btn:hover { color: var(--accent); }
|
||||
|
||||
/* error */
|
||||
.error-box {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
background: var(--err-bg);
|
||||
border: 1px solid var(--err-bd);
|
||||
color: var(--err-col);
|
||||
padding: 11px 14px;
|
||||
border-radius: 10px;
|
||||
font-size: 12px;
|
||||
font-weight: 500;
|
||||
margin-bottom: 18px;
|
||||
animation: shake 0.4s ease;
|
||||
}
|
||||
|
||||
@keyframes shake {
|
||||
0%,100% { transform: translateX(0); }
|
||||
20%,60% { transform: translateX(-6px); }
|
||||
40%,80% { transform: translateX(6px); }
|
||||
}
|
||||
|
||||
/* button */
|
||||
.btn-login {
|
||||
width: 100%;
|
||||
padding: 14px;
|
||||
background: linear-gradient(135deg, #2563eb, #7c3aed);
|
||||
color: #fff;
|
||||
border: none;
|
||||
border-radius: 12px;
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
font-family: 'Sora', sans-serif;
|
||||
cursor: pointer;
|
||||
display: flex; align-items: center; justify-content: center; gap: 8px;
|
||||
margin-top: 4px;
|
||||
box-shadow: 0 8px 24px rgba(37,99,235,0.35);
|
||||
transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
|
||||
letter-spacing: 0.02em;
|
||||
}
|
||||
|
||||
.btn-login:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(37,99,235,0.45); filter: brightness(1.05); }
|
||||
.btn-login:active { transform: translateY(0); box-shadow: 0 4px 12px rgba(37,99,235,0.3); }
|
||||
|
||||
/* akun section */
|
||||
.akun-label {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
margin: 24px 0 14px;
|
||||
}
|
||||
.akun-line { flex: 1; height: 1px; background: var(--border); transition: background 0.4s; }
|
||||
.akun-text { font-size: 10px; color: var(--muted); font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; transition: color 0.4s; }
|
||||
|
||||
.akun-grid { display: flex; flex-direction: column; gap: 8px; }
|
||||
|
||||
.akun-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 10px 14px;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 12px;
|
||||
cursor: pointer;
|
||||
transition: all 0.2s;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.akun-item:hover {
|
||||
border-color: var(--accent);
|
||||
background: var(--tag-bg);
|
||||
}
|
||||
|
||||
.akun-left { display: flex; align-items: center; gap: 10px; }
|
||||
|
||||
.akun-icon {
|
||||
width: 32px; height: 32px;
|
||||
border-radius: 9px;
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.ai-admin { background: rgba(37,99,235,0.15); color: #60a5fa; }
|
||||
.ai-wali { background: rgba(245,158,11,0.15); color: #fbbf24; }
|
||||
|
||||
[data-theme="light"] .ai-admin { background: #eff6ff; color: #2563eb; }
|
||||
[data-theme="light"] .ai-wali { background: #fffbeb; color: #d97706; }
|
||||
|
||||
.akun-info-name {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--text);
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.akun-info-pass {
|
||||
font-size: 11px;
|
||||
color: var(--muted);
|
||||
margin-top: 1px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.akun-badge {
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
padding: 3px 10px;
|
||||
border-radius: 999px;
|
||||
letter-spacing: 0.03em;
|
||||
}
|
||||
|
||||
.ab-admin { background: rgba(37,99,235,0.15); color: #60a5fa; }
|
||||
.ab-wali { background: rgba(245,158,11,0.15); color: #fbbf24; }
|
||||
|
||||
[data-theme="light"] .ab-admin { background: #eff6ff; color: #1d4ed8; }
|
||||
[data-theme="light"] .ab-wali { background: #fffbeb; color: #b45309; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="orb orb1"></div>
|
||||
<div class="orb orb2"></div>
|
||||
<div class="orb orb3"></div>
|
||||
|
||||
<button class="theme-toggle" onclick="toggleTheme()" title="Toggle tema">
|
||||
<i class="fa-solid fa-sun" id="theme-icon"></i>
|
||||
</button>
|
||||
|
||||
<div class="card">
|
||||
|
||||
<div class="logo-wrap">
|
||||
<div class="logo-icon"><i class="fa-solid fa-map-location-dot"></i></div>
|
||||
<div class="logo-text">
|
||||
<h1>WebGIS Pontianak</h1>
|
||||
<p>Sistem Informasi Geografis Kota Pontianak</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="badge-live">
|
||||
<span class="dot-live"></span> Sistem Online
|
||||
</div>
|
||||
|
||||
<div class="heading">Selamat Datang</div>
|
||||
<div class="subheading">Masuk ke akun Anda untuk mengakses peta</div>
|
||||
|
||||
<div class="divider"></div>
|
||||
|
||||
<?php if ($error): ?>
|
||||
<div class="error-box">
|
||||
<i class="fa-solid fa-circle-exclamation"></i>
|
||||
<?= htmlspecialchars($error) ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<form method="POST">
|
||||
<div class="field">
|
||||
<label>Username</label>
|
||||
<div class="input-wrap">
|
||||
<i class="fa-solid fa-user ico"></i>
|
||||
<input type="text" name="username" placeholder="Masukkan username" required autocomplete="off">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="field">
|
||||
<label>Password</label>
|
||||
<div class="input-wrap">
|
||||
<i class="fa-solid fa-lock ico"></i>
|
||||
<input type="password" name="password" id="pw" placeholder="Masukkan password" required>
|
||||
<button type="button" class="eye-btn" onclick="togglePw()">
|
||||
<i class="fa-solid fa-eye" id="eye-icon"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<button type="submit" class="btn-login">
|
||||
<i class="fa-solid fa-right-to-bracket"></i> Masuk ke Sistem
|
||||
</button>
|
||||
</form>
|
||||
|
||||
<div class="akun-label">
|
||||
<div class="akun-line"></div>
|
||||
<span class="akun-text">Akun Tersedia</span>
|
||||
<div class="akun-line"></div>
|
||||
</div>
|
||||
|
||||
<div class="akun-grid">
|
||||
<div class="akun-item" onclick="fillLogin('admin','admin123')">
|
||||
<div class="akun-left">
|
||||
<div class="akun-icon ai-admin"><i class="fa-solid fa-shield-halved"></i></div>
|
||||
<div>
|
||||
<div class="akun-info-name">admin</div>
|
||||
<div class="akun-info-pass">admin123</div>
|
||||
</div>
|
||||
</div>
|
||||
<span class="akun-badge ab-admin">Administrator</span>
|
||||
</div>
|
||||
|
||||
<div class="akun-item" onclick="fillLogin('walikota','walikota123')">
|
||||
<div class="akun-left">
|
||||
<div class="akun-icon ai-wali"><i class="fa-solid fa-star"></i></div>
|
||||
<div>
|
||||
<div class="akun-info-name">walikota</div>
|
||||
<div class="akun-info-pass">walikota123</div>
|
||||
</div>
|
||||
</div>
|
||||
<span class="akun-badge ab-wali">Walikota</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function toggleTheme() {
|
||||
const html = document.documentElement;
|
||||
const icon = document.getElementById('theme-icon');
|
||||
if (html.getAttribute('data-theme') === 'dark') {
|
||||
html.setAttribute('data-theme', 'light');
|
||||
icon.className = 'fa-solid fa-moon';
|
||||
} else {
|
||||
html.setAttribute('data-theme', 'dark');
|
||||
icon.className = 'fa-solid fa-sun';
|
||||
}
|
||||
}
|
||||
|
||||
function togglePw() {
|
||||
const pw = document.getElementById('pw');
|
||||
const icon = document.getElementById('eye-icon');
|
||||
if (pw.type === 'password') {
|
||||
pw.type = 'text';
|
||||
icon.className = 'fa-solid fa-eye-slash';
|
||||
} else {
|
||||
pw.type = 'password';
|
||||
icon.className = 'fa-solid fa-eye';
|
||||
}
|
||||
}
|
||||
|
||||
function fillLogin(user, pass) {
|
||||
document.querySelector('input[name="username"]').value = user;
|
||||
document.getElementById('pw').value = pass;
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?php
|
||||
session_start();
|
||||
session_destroy();
|
||||
header('Location: login.php');
|
||||
exit;
|
||||
?>
|
||||
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER["REQUEST_METHOD"] == "POST") {
|
||||
$id = $_POST['id'];
|
||||
$nama = mysqli_real_escape_string($conn, $_POST['nama']);
|
||||
$wa = mysqli_real_escape_string($conn, $_POST['wa']);
|
||||
$jam = $_POST['jam'];
|
||||
|
||||
$query = "UPDATE spbu SET nama_spbu='$nama', no_whatsapp='$wa', status_24jam='$jam' WHERE id='$id'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>alert('Data berhasil diperbarui!'); window.location='index.php';</script>";
|
||||
} else {
|
||||
echo "Gagal mengupdate data: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$nama_jalan = mysqli_real_escape_string($conn, $_POST['nama_jalan']);
|
||||
$status_jalan = mysqli_real_escape_string($conn, $_POST['status_jalan']);
|
||||
$panjang = (float)$_POST['panjang_jalan'];
|
||||
$geojson = mysqli_real_escape_string($conn, $_POST['geojson_coords']);
|
||||
|
||||
$query = "INSERT INTO jalan (nama_jalan, status_jalan, panjang_jalan, geojson)
|
||||
VALUES ('$nama_jalan', '$status_jalan', '$panjang', '$geojson')";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>alert('Data Jalan berhasil disimpan!'); window.location='index.php';</script>";
|
||||
} else {
|
||||
echo "Gagal menyimpan: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$pemilik_tanah = mysqli_real_escape_string($conn, $_POST['pemilik_tanah']);
|
||||
$status_shm = mysqli_real_escape_string($conn, $_POST['status_shm']);
|
||||
$luas_tanah = (float)$_POST['luas_tanah'];
|
||||
$geojson = mysqli_real_escape_string($conn, $_POST['geojson_coords']);
|
||||
|
||||
// Coba insert dengan nama kolom nama_pemilik dan status_kepemilikan
|
||||
$query = "INSERT INTO parsil (nama_pemilik, status_kepemilikan, luas_tanah, geojson)
|
||||
VALUES ('$pemilik_tanah', '$status_shm', '$luas_tanah', '$geojson')";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>alert('Data Parsil berhasil disimpan!'); window.location='index.php';</script>";
|
||||
} else {
|
||||
echo "Gagal menyimpan: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$nama = mysqli_real_escape_string($conn, $_POST['nama_spbu']);
|
||||
$wa = mysqli_real_escape_string($conn, $_POST['no_whatsapp']);
|
||||
$jam = mysqli_real_escape_string($conn, $_POST['status_24jam']);
|
||||
$lat = (float)$_POST['latitude'];
|
||||
$lng = (float)$_POST['longitude'];
|
||||
|
||||
$query = "INSERT INTO spbu (nama_spbu, no_whatsapp, status_24jam, latitude, longitude)
|
||||
VALUES ('$nama', '$wa', '$jam', '$lat', '$lng')";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>
|
||||
alert('Data SPBU berhasil disimpan!');
|
||||
window.location='index.php';
|
||||
</script>";
|
||||
} else {
|
||||
echo "Gagal menyimpan: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$id = (int)$_POST['id'];
|
||||
$radius_baru = (int)$_POST['radius_baru'];
|
||||
|
||||
$query = "UPDATE masjid SET radius_meter = '$radius_baru' WHERE id = '$id'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "ok";
|
||||
} else {
|
||||
echo "Gagal: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$id_warga = (int)$_POST['id_warga'];
|
||||
$radius_baru_warga = (int)$_POST['radius_baru_warga'];
|
||||
|
||||
$query = "UPDATE penduduk_miskin SET radius_warga = '$radius_baru_warga' WHERE id = '$id_warga'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "ok";
|
||||
} else {
|
||||
echo "Gagal: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,60 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
$id = $_GET['id'];
|
||||
$data = mysqli_query($conn, "SELECT * FROM penduduk_miskin WHERE id='$id'");
|
||||
$d = mysqli_fetch_array($data);
|
||||
|
||||
// Penanganan variasi nama kolom database (antisipasi huruf besar/kecil)
|
||||
$jumlah_keluarga = $d['jumlah_keluarga'] ?? $d['anggota_keluarga'] ?? 0;
|
||||
$umur = $d['umur'] ?? 0;
|
||||
$pendidikan = $d['pendidikan_terakhir'] ?? '';
|
||||
$lat = $d['latitude'] ?? $d['Latitude'] ?? '';
|
||||
$lng = $d['longitude'] ?? $d['Longitude'] ?? '';
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Edit Data Miskin</title>
|
||||
<style>
|
||||
body { font-family: sans-serif; background: #f4f7f6; display: flex; justify-content: center; padding: 40px; }
|
||||
.card { background: white; padding: 25px; border-radius: 10px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); width: 380px; }
|
||||
label { font-size: 13px; font-weight: bold; color: #495057; display: block; margin-top: 10px; }
|
||||
input { width: 100%; padding: 10px; margin: 5px 0 12px 0; border: 1px solid #ddd; border-radius: 5px; box-sizing: border-box; }
|
||||
button { width: 100%; padding: 12px; background: #fd7e14; color: white; border: none; border-radius: 5px; cursor: pointer; font-weight: bold; margin-top: 10px; transition: background 0.2s; }
|
||||
button:hover { background: #e8590c; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="card">
|
||||
<h3 style="color:#fd7e14; text-align:center; margin-bottom: 20px;">Edit Data Warga</h3>
|
||||
<form action="proses_edit_miskin.php" method="POST">
|
||||
<!-- ID Warga (Hidden) -->
|
||||
<input type="hidden" name="id" value="<?php echo $d['id']; ?>">
|
||||
|
||||
<label>Nama Kepala Keluarga (KK)</label>
|
||||
<input type="text" name="nama_kk" value="<?php echo $d['nama_kk']; ?>" required>
|
||||
|
||||
<label>Alamat Domisili</label>
|
||||
<input type="text" name="alamat" value="<?php echo $d['alamat']; ?>" required>
|
||||
|
||||
<!-- INPUT YANG SEBELUMNYA HILANG KITA TAMBAHKAN DI BAWAH INI -->
|
||||
<label>Jumlah Anggota Keluarga</label>
|
||||
<input type="number" name="anggota_keluarga" value="<?php echo $jumlah_keluarga; ?>" required>
|
||||
|
||||
<label>Umur Kepala Keluarga</label>
|
||||
<input type="number" name="umur" value="<?php echo $umur; ?>" required>
|
||||
|
||||
<label>Pendidikan Terakhir</label>
|
||||
<input type="text" name="pendidikan_terakhir" value="<?php echo $pendidikan; ?>" required>
|
||||
|
||||
<label>Latitude (Titik Peta)</label>
|
||||
<input type="text" name="latitude" value="<?php echo $lat; ?>" required>
|
||||
|
||||
<label>Longitude (Titik Peta)</label>
|
||||
<input type="text" name="longitude" value="<?php echo $lng; ?>" required>
|
||||
|
||||
<button type="submit">UPDATE DATA WARGA</button>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
$id = mysqli_real_escape_string($conn, $_GET['id']);
|
||||
$data = mysqli_query($conn, "SELECT * FROM pengaduan_warga WHERE id='$id'");
|
||||
$d = mysqli_fetch_array($data);
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Edit Data Pengaduan</title>
|
||||
<style>
|
||||
body { font-family: sans-serif; background: #f4f7f6; display: flex; justify-content: center; padding: 40px; }
|
||||
.card { background: white; padding: 20px; border-radius: 10px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); width: 350px; }
|
||||
input, textarea { width: 100%; padding: 10px; margin: 10px 0; border: 1px solid #ddd; border-radius: 5px; box-sizing: border-box; font-family: sans-serif; }
|
||||
button { width: 100%; padding: 10px; background: #dc2626; color: white; border: none; border-radius: 5px; cursor: pointer; font-weight: bold; }
|
||||
label { font-size: 12px; font-weight: bold; color: #555; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="card">
|
||||
<h3 style="color:#dc2626; text-align:center; margin-bottom:15px;">Edit Laporan Warga</h3>
|
||||
<form action="proses_edit_pengaduan.php" method="POST">
|
||||
<input type="hidden" name="id" value="<?php echo $d['id']; ?>">
|
||||
|
||||
<label>Nama Pelapor</label>
|
||||
<input type="text" name="nama_pelapor" value="<?php echo $d['nama_pelapor']; ?>" required>
|
||||
|
||||
<label>Kontak Pelapor</label>
|
||||
<input type="text" name="kontak_pelapor" value="<?php echo $d['kontak_pelapor']; ?>" required>
|
||||
|
||||
<label>Deskripsi Laporan / Aduan</label>
|
||||
<textarea name="deskripsi_laporan" rows="4" required><?php echo $d['deskripsi_laporan']; ?></textarea>
|
||||
|
||||
<button type="submit">UPDATE LAPORAN</button>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
$id = $_GET['id'];
|
||||
// Proteksi string agar aman dari error sql injection
|
||||
$id = mysqli_real_escape_string($conn, $id);
|
||||
$data = mysqli_query($conn, "SELECT * FROM masjid WHERE id='$id'");
|
||||
$d = mysqli_fetch_array($data);
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Edit Data Masjid</title>
|
||||
<style>
|
||||
body { font-family: 'Segoe UI', sans-serif; background: #f4f7f6; display: flex; justify-content: center; padding: 50px; }
|
||||
.card { background: white; padding: 25px; border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.1); width: 400px; }
|
||||
h3 { color: #10b981; text-align: center; margin-bottom: 20px; }
|
||||
label { font-size: 13px; font-weight: 600; color: #475569; display: block; margin-top: 10px; }
|
||||
input { width: 100%; padding: 10px; margin: 5px 0 15px 0; border: 1px solid #ddd; border-radius: 6px; box-sizing: border-box; }
|
||||
button { width: 100%; padding: 12px; background: #10b981; color: white; border: none; border-radius: 6px; cursor: pointer; font-weight: bold; font-size: 14px; }
|
||||
button:hover { background: #059669; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="card">
|
||||
<h3>Edit Lokasi Masjid</h3>
|
||||
<form action="proses_edit_masjid.php" method="POST">
|
||||
<input type="hidden" name="id" value="<?php echo $d['id']; ?>">
|
||||
|
||||
<label>Nama Masjid</label>
|
||||
<input type="text" name="nama_masjid" value="<?php echo $d['nama_masjid']; ?>" required>
|
||||
|
||||
<label>Nama PIC</label>
|
||||
<input type="text" name="nama_pic" value="<?php echo $d['nama_pic']; ?>" required>
|
||||
|
||||
<label>Radius Jangkauan (Meter)</label>
|
||||
<input type="number" name="radius_meter" value="<?php echo $d['radius_meter']; ?>" required>
|
||||
|
||||
<button type="submit">UPDATE DATA MASJID</button>
|
||||
<center><br><a href="index.php" style="text-decoration:none; color:gray; font-size:13px;">← Kembali ke Peta</a></center>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
$id = $_GET['id'];
|
||||
mysqli_query($conn, "DELETE FROM penduduk_miskin WHERE id='$id'");
|
||||
header("location:index.php");
|
||||
?>
|
||||
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if (isset($_GET['id'])) {
|
||||
$id = mysqli_real_escape_string($conn, $_GET['id']);
|
||||
|
||||
$query = "DELETE FROM pengaduan_warga WHERE id = '$id'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>
|
||||
alert('Laporan pengaduan berhasil dihapus!');
|
||||
window.location.href='index.php';
|
||||
</script>";
|
||||
} else {
|
||||
echo "Gagal menghapus data: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
$id = $_GET['id'];
|
||||
mysqli_query($conn, "DELETE FROM masjid WHERE id='$id'");
|
||||
header("location:index.php");
|
||||
?>
|
||||
@@ -0,0 +1,153 @@
|
||||
<?php
|
||||
session_start();
|
||||
include 'koneksi.php';
|
||||
if (!isset($_SESSION['user_role']) || !in_array($_SESSION['user_role'], ['admin','walikota'])) {
|
||||
header('Location: login.php'); exit;
|
||||
}
|
||||
|
||||
// Tambah histori
|
||||
if (isset($_POST['tambah'])) {
|
||||
$id_warga = (int)$_POST['id_warga'];
|
||||
$jenis = mysqli_real_escape_string($conn, $_POST['jenis_bantuan']);
|
||||
$jumlah = mysqli_real_escape_string($conn, $_POST['jumlah'] ?? '');
|
||||
$tgl = mysqli_real_escape_string($conn, $_POST['tanggal_bantuan']);
|
||||
$ket = mysqli_real_escape_string($conn, $_POST['keterangan'] ?? '');
|
||||
$petugas = mysqli_real_escape_string($conn, $_SESSION['user_nama']);
|
||||
mysqli_query($conn, "INSERT INTO histori_bantuan (id_warga,jenis_bantuan,jumlah,tanggal_bantuan,keterangan,petugas) VALUES ($id_warga,'$jenis','$jumlah','$tgl','$ket','$petugas')");
|
||||
header('Location: histori_bantuan.php?added=1'); exit;
|
||||
}
|
||||
|
||||
// Hapus histori
|
||||
if (isset($_GET['hapus'])) {
|
||||
$id = (int)$_GET['hapus'];
|
||||
mysqli_query($conn, "DELETE FROM histori_bantuan WHERE id=$id");
|
||||
header('Location: histori_bantuan.php'); exit;
|
||||
}
|
||||
|
||||
$warga_list = mysqli_query($conn, "SELECT id, nama_kk FROM penduduk_miskin ORDER BY nama_kk");
|
||||
$histori = mysqli_query($conn, "SELECT h.*, p.nama_kk FROM histori_bantuan h JOIN penduduk_miskin p ON h.id_warga=p.id ORDER BY h.tanggal_bantuan DESC");
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Histori Bantuan - WebGIS Pontianak</title>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
||||
<style>
|
||||
* { box-sizing: border-box; margin: 0; padding: 0; }
|
||||
body { font-family: 'Plus Jakarta Sans', sans-serif; background: #f1f5f9; }
|
||||
.topbar { background: #0f172a; color: white; padding: 14px 28px; display: flex; align-items: center; justify-content: space-between; }
|
||||
.topbar h1 { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
|
||||
.topbar h1 i { color: #22c55e; }
|
||||
.topbar a { color: #94a3b8; text-decoration: none; font-size: 12px; margin-left: 16px; }
|
||||
.topbar a:hover { color: white; }
|
||||
.topbar-role { background: rgba(255,255,255,0.1); padding: 5px 12px; border-radius: 20px; font-size: 11px; font-weight: 700; }
|
||||
.container { max-width: 1100px; margin: 28px auto; padding: 0 20px; display: grid; grid-template-columns: 340px 1fr; gap: 20px; align-items: start; }
|
||||
.card { background: white; border-radius: 16px; border: 1px solid #e2e8f0; overflow: hidden; }
|
||||
.card-header { padding: 18px 22px; border-bottom: 1px solid #f1f5f9; }
|
||||
.card-header h2 { font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
|
||||
.card-header h2 i { color: #22c55e; }
|
||||
.card-body { padding: 20px 22px; }
|
||||
.form-group { margin-bottom: 14px; }
|
||||
.form-group label { font-size: 11px; font-weight: 700; color: #475569; display: block; margin-bottom: 5px; }
|
||||
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 9px 12px; border: 1.5px solid #e2e8f0; border-radius: 8px; font-size: 13px; font-family: inherit; color: #0f172a; }
|
||||
.btn-submit { width: 100%; padding: 11px; background: #0f172a; color: white; border: none; border-radius: 9px; font-size: 13px; font-weight: 700; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 7px; }
|
||||
table { width: 100%; border-collapse: collapse; }
|
||||
th { background: #f8fafc; padding: 11px 14px; text-align: left; font-size: 11px; font-weight: 800; text-transform: uppercase; color: #64748b; }
|
||||
td { padding: 12px 14px; border-top: 1px solid #f1f5f9; font-size: 13px; }
|
||||
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 20px; font-size: 10px; font-weight: 700; }
|
||||
.b-blt { background: #fef3c7; color: #d97706; }
|
||||
.b-sembako { background: #dcfce7; color: #16a34a; }
|
||||
.b-bpjs { background: #dbeafe; color: #2563eb; }
|
||||
.b-lain { background: #f1f5f9; color: #475569; }
|
||||
.btn-del { background: #fef2f2; color: #dc2626; border: none; padding: 5px 10px; border-radius: 6px; font-size: 11px; font-weight: 700; cursor: pointer; text-decoration: none; }
|
||||
.alert-success { background: #dcfce7; border: 1px solid #bbf7d0; color: #16a34a; padding: 12px 16px; border-radius: 10px; margin-bottom: 18px; font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 8px; grid-column: 1/-1; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="topbar">
|
||||
<h1><i class="fa-solid fa-hand-holding-heart"></i> Histori Bantuan Warga</h1>
|
||||
<div style="display:flex;align-items:center;gap:8px;">
|
||||
<span class="topbar-role"><?= htmlspecialchars($_SESSION['user_nama']) ?> (<?= $_SESSION['user_role'] ?>)</span>
|
||||
<a href="index.php"><i class="fa-solid fa-map"></i> Peta</a>
|
||||
<a href="logout.php"><i class="fa-solid fa-right-from-bracket"></i> Logout</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container">
|
||||
<?php if (isset($_GET['added'])): ?>
|
||||
<div class="alert-success"><i class="fa-solid fa-circle-check"></i> Data bantuan berhasil ditambahkan!</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<!-- FORM TAMBAH -->
|
||||
<div class="card">
|
||||
<div class="card-header"><h2><i class="fa-solid fa-plus-circle"></i> Tambah Bantuan</h2></div>
|
||||
<div class="card-body">
|
||||
<form method="POST">
|
||||
<div class="form-group">
|
||||
<label>Nama Warga</label>
|
||||
<select name="id_warga" required>
|
||||
<option value="">-- Pilih Warga --</option>
|
||||
<?php while($w = mysqli_fetch_assoc($warga_list)): ?>
|
||||
<option value="<?= $w['id'] ?>"><?= htmlspecialchars($w['nama_kk']) ?></option>
|
||||
<?php endwhile; ?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>Jenis Bantuan</label>
|
||||
<select name="jenis_bantuan" required>
|
||||
<option value="BLT">BLT (Bantuan Langsung Tunai)</option>
|
||||
<option value="Sembako">Paket Sembako</option>
|
||||
<option value="BPJS">BPJS Kesehatan</option>
|
||||
<option value="PKH">PKH</option>
|
||||
<option value="Lainnya">Lainnya</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>Jumlah / Nominal</label>
|
||||
<input type="text" name="jumlah" placeholder="Contoh: Rp 600.000 / 5 Kg Beras">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>Tanggal Bantuan</label>
|
||||
<input type="date" name="tanggal_bantuan" required value="<?= date('Y-m-d') ?>">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>Keterangan</label>
|
||||
<textarea name="keterangan" rows="3" placeholder="Keterangan tambahan..."></textarea>
|
||||
</div>
|
||||
<button type="submit" name="tambah" class="btn-submit">
|
||||
<i class="fa-solid fa-floppy-disk"></i> Simpan Bantuan
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- TABEL HISTORI -->
|
||||
<div class="card">
|
||||
<div class="card-header"><h2><i class="fa-solid fa-clock-rotate-left"></i> Riwayat Bantuan</h2></div>
|
||||
<table>
|
||||
<thead>
|
||||
<tr><th>#</th><th>Warga</th><th>Jenis</th><th>Jumlah</th><th>Tanggal</th><th>Petugas</th><th>Aksi</th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php $no=1; while ($h = mysqli_fetch_assoc($histori)):
|
||||
$bc = ['BLT'=>'b-blt','Sembako'=>'b-sembako','BPJS'=>'b-bpjs'][$h['jenis_bantuan']] ?? 'b-lain';
|
||||
?>
|
||||
<tr>
|
||||
<td><?= $no++ ?></td>
|
||||
<td><strong><?= htmlspecialchars($h['nama_kk']) ?></strong></td>
|
||||
<td><span class="badge <?= $bc ?>"><?= $h['jenis_bantuan'] ?></span></td>
|
||||
<td><?= htmlspecialchars($h['jumlah'] ?? '-') ?></td>
|
||||
<td style="font-size:12px;color:#64748b;"><?= date('d M Y', strtotime($h['tanggal_bantuan'])) ?></td>
|
||||
<td style="font-size:12px;"><?= htmlspecialchars($h['petugas'] ?? '-') ?></td>
|
||||
<td><a href="?hapus=<?= $h['id'] ?>" class="btn-del" onclick="return confirm('Hapus data ini?')"><i class="fa-solid fa-trash"></i></a></td>
|
||||
</tr>
|
||||
<?php endwhile; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
+1218
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,210 @@
|
||||
<?php
|
||||
session_start();
|
||||
include 'koneksi.php';
|
||||
if (!isset($_SESSION['user_role']) || !in_array($_SESSION['user_role'], ['admin','walikota'])) {
|
||||
header('Location: login.php'); exit;
|
||||
}
|
||||
|
||||
// Update status laporan
|
||||
if (isset($_POST['update_status'])) {
|
||||
$id = (int)$_POST['id'];
|
||||
$status = mysqli_real_escape_string($conn, $_POST['status']);
|
||||
$catatan= mysqli_real_escape_string($conn, $_POST['catatan_admin'] ?? '');
|
||||
mysqli_query($conn, "UPDATE laporan_cepat SET status='$status', catatan_admin='$catatan' WHERE id=$id");
|
||||
header('Location: kelola_laporan.php?updated=1'); exit;
|
||||
}
|
||||
|
||||
$q = mysqli_query($conn, "SELECT * FROM laporan_cepat ORDER BY tgl_lapor DESC");
|
||||
$total = mysqli_num_rows($q);
|
||||
$masuk = mysqli_num_rows(mysqli_query($conn, "SELECT id FROM laporan_cepat WHERE status='Masuk'"));
|
||||
$proses = mysqli_num_rows(mysqli_query($conn, "SELECT id FROM laporan_cepat WHERE status='Diproses'"));
|
||||
$selesai = mysqli_num_rows(mysqli_query($conn, "SELECT id FROM laporan_cepat WHERE status='Selesai'"));
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Kelola Laporan - WebGIS Pontianak</title>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
||||
<style>
|
||||
* { box-sizing: border-box; margin: 0; padding: 0; }
|
||||
body { font-family: 'Plus Jakarta Sans', sans-serif; background: #f1f5f9; color: #0f172a; }
|
||||
.topbar {
|
||||
background: #0f172a; color: white; padding: 14px 28px;
|
||||
display: flex; align-items: center; justify-content: space-between;
|
||||
}
|
||||
.topbar h1 { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
|
||||
.topbar h1 i { color: #3b82f6; }
|
||||
.topbar-right { display: flex; align-items: center; gap: 12px; }
|
||||
.topbar-role { background: rgba(255,255,255,0.1); padding: 5px 12px; border-radius: 20px; font-size: 11px; font-weight: 700; }
|
||||
.topbar a { color: #94a3b8; text-decoration: none; font-size: 12px; }
|
||||
.topbar a:hover { color: white; }
|
||||
|
||||
.container { max-width: 1100px; margin: 28px auto; padding: 0 20px; }
|
||||
|
||||
.stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-bottom: 24px; }
|
||||
.stat-card { background: white; border-radius: 14px; padding: 20px; border: 1px solid #e2e8f0; }
|
||||
.stat-card .num { font-size: 28px; font-weight: 800; }
|
||||
.stat-card .lbl { font-size: 12px; color: #64748b; margin-top: 4px; font-weight: 600; }
|
||||
.stat-card .icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 16px; margin-bottom: 12px; }
|
||||
|
||||
.card { background: white; border-radius: 16px; border: 1px solid #e2e8f0; overflow: hidden; }
|
||||
.card-header { padding: 18px 24px; border-bottom: 1px solid #f1f5f9; display: flex; align-items: center; justify-content: space-between; }
|
||||
.card-header h2 { font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
|
||||
.card-header h2 i { color: #3b82f6; }
|
||||
|
||||
table { width: 100%; border-collapse: collapse; }
|
||||
th { background: #f8fafc; padding: 12px 16px; text-align: left; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px; color: #64748b; }
|
||||
td { padding: 13px 16px; border-top: 1px solid #f1f5f9; font-size: 13px; vertical-align: top; }
|
||||
tr:hover td { background: #fafbfc; }
|
||||
|
||||
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 20px; font-size: 10px; font-weight: 700; }
|
||||
.b-masuk { background: #fef3c7; color: #d97706; }
|
||||
.b-diproses { background: #dbeafe; color: #2563eb; }
|
||||
.b-selesai { background: #dcfce7; color: #16a34a; }
|
||||
.b-kat { background: #f1f5f9; color: #475569; font-size: 10px; padding: 2px 7px; border-radius: 4px; font-weight: 600; }
|
||||
|
||||
.btn-sm { padding: 6px 12px; border-radius: 7px; font-size: 11px; font-weight: 700; border: none; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; }
|
||||
.btn-primary { background: #eff6ff; color: #2563eb; }
|
||||
.btn-back { background: #0f172a; color: white; text-decoration: none; padding: 8px 16px; border-radius: 8px; font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }
|
||||
|
||||
.modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 9999; align-items: center; justify-content: center; }
|
||||
.modal-overlay.open { display: flex; }
|
||||
.modal { background: white; border-radius: 18px; padding: 28px; width: 460px; max-width: 95vw; }
|
||||
.modal h3 { font-size: 16px; font-weight: 700; margin-bottom: 18px; display: flex; align-items: center; gap: 8px; }
|
||||
.modal h3 i { color: #3b82f6; }
|
||||
.form-group { margin-bottom: 14px; }
|
||||
.form-group label { font-size: 11px; font-weight: 700; color: #475569; display: block; margin-bottom: 5px; }
|
||||
.form-group select, .form-group textarea { width: 100%; padding: 9px 12px; border: 1.5px solid #e2e8f0; border-radius: 8px; font-size: 13px; font-family: inherit; }
|
||||
.modal-footer { display: flex; gap: 8px; justify-content: flex-end; margin-top: 18px; }
|
||||
.btn-cancel { background: #f1f5f9; color: #64748b; padding: 9px 18px; border-radius: 8px; border: none; font-size: 13px; font-weight: 700; cursor: pointer; }
|
||||
.btn-save { background: #0f172a; color: white; padding: 9px 18px; border-radius: 8px; border: none; font-size: 13px; font-weight: 700; cursor: pointer; }
|
||||
|
||||
.alert-success { background: #dcfce7; border: 1px solid #bbf7d0; color: #16a34a; padding: 12px 16px; border-radius: 10px; margin-bottom: 18px; font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="topbar">
|
||||
<h1><i class="fa-solid fa-bell"></i> Kelola Laporan Masyarakat</h1>
|
||||
<div class="topbar-right">
|
||||
<span class="topbar-role"><i class="fa-solid fa-circle-user"></i> <?= htmlspecialchars($_SESSION['user_nama']) ?> (<?= $_SESSION['user_role'] ?>)</span>
|
||||
<a href="index.php"><i class="fa-solid fa-map"></i> Kembali ke Peta</a>
|
||||
<a href="logout.php"><i class="fa-solid fa-right-from-bracket"></i> Logout</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container">
|
||||
<?php if (isset($_GET['updated'])): ?>
|
||||
<div class="alert-success"><i class="fa-solid fa-circle-check"></i> Status laporan berhasil diperbarui!</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="stats">
|
||||
<div class="stat-card">
|
||||
<div class="icon" style="background:#f8fafc; color:#64748b;"><i class="fa-solid fa-list"></i></div>
|
||||
<div class="num"><?= $total ?></div><div class="lbl">Total Laporan</div>
|
||||
</div>
|
||||
<div class="stat-card">
|
||||
<div class="icon" style="background:#fef3c7; color:#d97706;"><i class="fa-solid fa-inbox"></i></div>
|
||||
<div class="num" style="color:#d97706;"><?= $masuk ?></div><div class="lbl">Masuk / Baru</div>
|
||||
</div>
|
||||
<div class="stat-card">
|
||||
<div class="icon" style="background:#dbeafe; color:#2563eb;"><i class="fa-solid fa-gears"></i></div>
|
||||
<div class="num" style="color:#2563eb;"><?= $proses ?></div><div class="lbl">Sedang Diproses</div>
|
||||
</div>
|
||||
<div class="stat-card">
|
||||
<div class="icon" style="background:#dcfce7; color:#16a34a;"><i class="fa-solid fa-circle-check"></i></div>
|
||||
<div class="num" style="color:#16a34a;"><?= $selesai ?></div><div class="lbl">Selesai</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h2><i class="fa-solid fa-table-list"></i> Daftar Laporan Masuk</h2>
|
||||
<a href="index.php" class="btn-back"><i class="fa-solid fa-map"></i> Lihat di Peta</a>
|
||||
</div>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>Pelapor</th>
|
||||
<th>Kategori</th>
|
||||
<th>Deskripsi</th>
|
||||
<th>Tanggal</th>
|
||||
<th>Status</th>
|
||||
<th>Aksi</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php
|
||||
mysqli_data_seek($q, 0);
|
||||
$no = 1;
|
||||
while ($d = mysqli_fetch_assoc($q)):
|
||||
$badgeClass = ['Masuk'=>'b-masuk','Diproses'=>'b-diproses','Selesai'=>'b-selesai'][$d['status']] ?? 'b-masuk';
|
||||
?>
|
||||
<tr>
|
||||
<td><?= $no++ ?></td>
|
||||
<td>
|
||||
<strong><?= htmlspecialchars($d['nama_pelapor']) ?></strong><br>
|
||||
<span style="font-size:11px;color:#94a3b8;"><?= htmlspecialchars($d['kontak_pelapor']) ?></span>
|
||||
</td>
|
||||
<td><span class="badge b-kat"><?= $d['kategori'] ?></span></td>
|
||||
<td style="max-width:220px;"><?= htmlspecialchars(substr($d['deskripsi'],0,80)) ?>...</td>
|
||||
<td style="font-size:12px;color:#64748b;"><?= date('d M Y', strtotime($d['tgl_lapor'])) ?></td>
|
||||
<td><span class="badge <?= $badgeClass ?>"><?= $d['status'] ?></span></td>
|
||||
<td>
|
||||
<button class="btn-sm btn-primary" onclick="openModal(<?= $d['id'] ?>, '<?= $d['status'] ?>', '<?= addslashes($d['catatan_admin'] ?? '') ?>')">
|
||||
<i class="fa-solid fa-pen"></i> Update
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endwhile; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- MODAL UPDATE STATUS -->
|
||||
<div class="modal-overlay" id="modal">
|
||||
<div class="modal">
|
||||
<h3><i class="fa-solid fa-pen-to-square"></i> Update Status Laporan</h3>
|
||||
<form method="POST">
|
||||
<input type="hidden" name="update_status" value="1">
|
||||
<input type="hidden" name="id" id="modal-id">
|
||||
<div class="form-group">
|
||||
<label>Status</label>
|
||||
<select name="status" id="modal-status">
|
||||
<option value="Masuk">Masuk</option>
|
||||
<option value="Diproses">Diproses</option>
|
||||
<option value="Selesai">Selesai</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>Catatan Admin</label>
|
||||
<textarea name="catatan_admin" id="modal-catatan" rows="3" placeholder="Tulis catatan tindak lanjut..."></textarea>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn-cancel" onclick="closeModal()">Batal</button>
|
||||
<button type="submit" class="btn-save"><i class="fa-solid fa-floppy-disk"></i> Simpan</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function openModal(id, status, catatan) {
|
||||
document.getElementById('modal-id').value = id;
|
||||
document.getElementById('modal-status').value = status;
|
||||
document.getElementById('modal-catatan').value = catatan;
|
||||
document.getElementById('modal').classList.add('open');
|
||||
}
|
||||
function closeModal() {
|
||||
document.getElementById('modal').classList.remove('open');
|
||||
}
|
||||
document.getElementById('modal').addEventListener('click', function(e) {
|
||||
if (e.target === this) closeModal();
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
$host = "localhost";
|
||||
$user = "root";
|
||||
$pass = "";
|
||||
$db = "db_gis_spbu"; // Sesuaikan dengan nama database kamu
|
||||
|
||||
$conn = mysqli_connect($host, $user, $pass, $db);
|
||||
|
||||
if (!$conn) {
|
||||
die("Koneksi ke database gagal: " . mysqli_connect_error());
|
||||
}
|
||||
?>
|
||||
+527
@@ -0,0 +1,527 @@
|
||||
<?php
|
||||
session_start();
|
||||
include 'koneksi.php';
|
||||
|
||||
$error = '';
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
$username = trim($_POST['username'] ?? '');
|
||||
$password = md5(trim($_POST['password'] ?? ''));
|
||||
$q = mysqli_query($conn, "SELECT * FROM users WHERE username='$username' AND password='$password' LIMIT 1");
|
||||
if ($q && mysqli_num_rows($q) > 0) {
|
||||
$user = mysqli_fetch_assoc($q);
|
||||
$_SESSION['user_id'] = $user['id'];
|
||||
$_SESSION['user_nama'] = $user['nama'];
|
||||
$_SESSION['user_role'] = $user['role'];
|
||||
header('Location: index.php');
|
||||
exit;
|
||||
} else {
|
||||
$error = 'Username atau password salah!';
|
||||
}
|
||||
}
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="id" data-theme="dark">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Login - WebGIS Pontianak</title>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
||||
<style>
|
||||
:root {
|
||||
--bg: #0b1120;
|
||||
--bg2: #111827;
|
||||
--card: #161f30;
|
||||
--border: rgba(255,255,255,0.07);
|
||||
--border2: rgba(255,255,255,0.13);
|
||||
--text: #f1f5f9;
|
||||
--muted: #94a3b8;
|
||||
--accent: #3b82f6;
|
||||
--accent2: #60a5fa;
|
||||
--btn: #3b82f6;
|
||||
--btn-text: #ffffff;
|
||||
--input-bg: #1e2b40;
|
||||
--input-bd: rgba(255,255,255,0.1);
|
||||
--input-focus: #3b82f6;
|
||||
--tag-bg: rgba(59,130,246,0.15);
|
||||
--tag-col: #93c5fd;
|
||||
--shadow: 0 40px 100px rgba(0,0,0,0.6);
|
||||
--err-bg: rgba(239,68,68,0.12);
|
||||
--err-bd: rgba(239,68,68,0.3);
|
||||
--err-col: #f87171;
|
||||
}
|
||||
|
||||
[data-theme="light"] {
|
||||
--bg: #e8eef7;
|
||||
--bg2: #dde5f0;
|
||||
--card: #ffffff;
|
||||
--border: rgba(0,0,0,0.06);
|
||||
--border2: rgba(0,0,0,0.12);
|
||||
--text: #0f172a;
|
||||
--muted: #64748b;
|
||||
--accent: #2563eb;
|
||||
--accent2: #3b82f6;
|
||||
--btn: #2563eb;
|
||||
--btn-text: #ffffff;
|
||||
--input-bg: #f1f5fb;
|
||||
--input-bd: rgba(0,0,0,0.1);
|
||||
--input-focus: #2563eb;
|
||||
--tag-bg: #eff6ff;
|
||||
--tag-col: #1d4ed8;
|
||||
--shadow: 0 40px 100px rgba(0,0,0,0.15);
|
||||
--err-bg: #fef2f2;
|
||||
--err-bd: #fecaca;
|
||||
--err-col: #dc2626;
|
||||
}
|
||||
|
||||
* { box-sizing: border-box; margin: 0; padding: 0; }
|
||||
html, body { height: 100%; }
|
||||
|
||||
body {
|
||||
font-family: 'Sora', sans-serif;
|
||||
background: var(--bg);
|
||||
min-height: 100vh;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 20px;
|
||||
transition: background 0.4s;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* background orbs */
|
||||
.orb {
|
||||
position: fixed;
|
||||
border-radius: 50%;
|
||||
filter: blur(80px);
|
||||
opacity: 0.25;
|
||||
pointer-events: none;
|
||||
transition: opacity 0.4s;
|
||||
}
|
||||
.orb1 { width: 500px; height: 500px; background: #3b82f6; top: -150px; left: -100px; }
|
||||
.orb2 { width: 400px; height: 400px; background: #8b5cf6; bottom: -100px; right: -80px; }
|
||||
.orb3 { width: 300px; height: 300px; background: #06b6d4; top: 40%; left: 40%; }
|
||||
|
||||
[data-theme="light"] .orb { opacity: 0.12; }
|
||||
|
||||
/* theme toggle */
|
||||
.theme-toggle {
|
||||
position: fixed;
|
||||
top: 20px; right: 20px;
|
||||
width: 44px; height: 44px;
|
||||
border-radius: 12px;
|
||||
background: var(--card);
|
||||
border: 1px solid var(--border2);
|
||||
color: var(--muted);
|
||||
font-size: 16px;
|
||||
cursor: pointer;
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
transition: all 0.3s;
|
||||
z-index: 100;
|
||||
box-shadow: 0 4px 20px rgba(0,0,0,0.2);
|
||||
}
|
||||
.theme-toggle:hover { color: var(--accent); border-color: var(--accent); }
|
||||
|
||||
/* card */
|
||||
.card {
|
||||
background: var(--card);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 24px;
|
||||
width: 100%;
|
||||
max-width: 440px;
|
||||
padding: 48px 44px;
|
||||
box-shadow: var(--shadow);
|
||||
position: relative;
|
||||
z-index: 10;
|
||||
transition: background 0.4s, border-color 0.4s, box-shadow 0.4s;
|
||||
animation: fadeUp 0.5s ease both;
|
||||
}
|
||||
|
||||
@keyframes fadeUp {
|
||||
from { opacity: 0; transform: translateY(24px); }
|
||||
to { opacity: 1; transform: translateY(0); }
|
||||
}
|
||||
|
||||
/* logo */
|
||||
.logo-wrap {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 14px;
|
||||
margin-bottom: 36px;
|
||||
}
|
||||
|
||||
.logo-icon {
|
||||
width: 52px; height: 52px;
|
||||
border-radius: 16px;
|
||||
background: linear-gradient(135deg, #2563eb, #7c3aed);
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
font-size: 22px;
|
||||
color: #fff;
|
||||
flex-shrink: 0;
|
||||
box-shadow: 0 8px 24px rgba(37,99,235,0.4);
|
||||
}
|
||||
|
||||
.logo-text h1 {
|
||||
font-size: 18px;
|
||||
font-weight: 700;
|
||||
color: var(--text);
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.logo-text p {
|
||||
font-size: 11px;
|
||||
color: var(--muted);
|
||||
margin-top: 2px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
/* badge */
|
||||
.badge-live {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
background: var(--tag-bg);
|
||||
color: var(--tag-col);
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
padding: 4px 10px;
|
||||
border-radius: 999px;
|
||||
margin-bottom: 20px;
|
||||
letter-spacing: 0.04em;
|
||||
transition: background 0.4s, color 0.4s;
|
||||
}
|
||||
|
||||
.dot-live {
|
||||
width: 6px; height: 6px;
|
||||
border-radius: 50%;
|
||||
background: currentColor;
|
||||
animation: pulse 1.8s infinite;
|
||||
}
|
||||
|
||||
@keyframes pulse {
|
||||
0%,100% { opacity: 1; transform: scale(1); }
|
||||
50% { opacity: 0.4; transform: scale(0.7); }
|
||||
}
|
||||
|
||||
/* heading */
|
||||
.heading {
|
||||
font-size: 26px;
|
||||
font-weight: 700;
|
||||
color: var(--text);
|
||||
line-height: 1.2;
|
||||
margin-bottom: 6px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.subheading {
|
||||
font-size: 13px;
|
||||
color: var(--muted);
|
||||
margin-bottom: 28px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
/* divider */
|
||||
.divider {
|
||||
height: 1px;
|
||||
background: var(--border);
|
||||
margin: 0 -44px 28px;
|
||||
transition: background 0.4s;
|
||||
}
|
||||
|
||||
/* form */
|
||||
.field { margin-bottom: 18px; }
|
||||
|
||||
.field label {
|
||||
display: block;
|
||||
font-size: 11px;
|
||||
font-weight: 600;
|
||||
color: var(--muted);
|
||||
letter-spacing: 0.06em;
|
||||
text-transform: uppercase;
|
||||
margin-bottom: 8px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.input-wrap { position: relative; }
|
||||
|
||||
.input-wrap i.ico {
|
||||
position: absolute;
|
||||
left: 14px; top: 50%;
|
||||
transform: translateY(-50%);
|
||||
color: var(--muted);
|
||||
font-size: 14px;
|
||||
pointer-events: none;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.input-wrap input {
|
||||
width: 100%;
|
||||
padding: 13px 14px 13px 42px;
|
||||
background: var(--input-bg);
|
||||
border: 1.5px solid var(--input-bd);
|
||||
border-radius: 12px;
|
||||
font-size: 14px;
|
||||
font-family: 'Sora', sans-serif;
|
||||
color: var(--text);
|
||||
outline: none;
|
||||
transition: all 0.25s;
|
||||
}
|
||||
|
||||
.input-wrap input::placeholder { color: var(--muted); opacity: 0.6; }
|
||||
.input-wrap input:focus { border-color: var(--input-focus); background: var(--input-bg); box-shadow: 0 0 0 3px rgba(59,130,246,0.12); }
|
||||
|
||||
/* eye toggle */
|
||||
.eye-btn {
|
||||
position: absolute;
|
||||
right: 14px; top: 50%;
|
||||
transform: translateY(-50%);
|
||||
background: none; border: none;
|
||||
color: var(--muted); font-size: 14px;
|
||||
cursor: pointer; padding: 0;
|
||||
transition: color 0.2s;
|
||||
}
|
||||
.eye-btn:hover { color: var(--accent); }
|
||||
|
||||
/* error */
|
||||
.error-box {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
background: var(--err-bg);
|
||||
border: 1px solid var(--err-bd);
|
||||
color: var(--err-col);
|
||||
padding: 11px 14px;
|
||||
border-radius: 10px;
|
||||
font-size: 12px;
|
||||
font-weight: 500;
|
||||
margin-bottom: 18px;
|
||||
animation: shake 0.4s ease;
|
||||
}
|
||||
|
||||
@keyframes shake {
|
||||
0%,100% { transform: translateX(0); }
|
||||
20%,60% { transform: translateX(-6px); }
|
||||
40%,80% { transform: translateX(6px); }
|
||||
}
|
||||
|
||||
/* button */
|
||||
.btn-login {
|
||||
width: 100%;
|
||||
padding: 14px;
|
||||
background: linear-gradient(135deg, #2563eb, #7c3aed);
|
||||
color: #fff;
|
||||
border: none;
|
||||
border-radius: 12px;
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
font-family: 'Sora', sans-serif;
|
||||
cursor: pointer;
|
||||
display: flex; align-items: center; justify-content: center; gap: 8px;
|
||||
margin-top: 4px;
|
||||
box-shadow: 0 8px 24px rgba(37,99,235,0.35);
|
||||
transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
|
||||
letter-spacing: 0.02em;
|
||||
}
|
||||
|
||||
.btn-login:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(37,99,235,0.45); filter: brightness(1.05); }
|
||||
.btn-login:active { transform: translateY(0); box-shadow: 0 4px 12px rgba(37,99,235,0.3); }
|
||||
|
||||
/* akun section */
|
||||
.akun-label {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
margin: 24px 0 14px;
|
||||
}
|
||||
.akun-line { flex: 1; height: 1px; background: var(--border); transition: background 0.4s; }
|
||||
.akun-text { font-size: 10px; color: var(--muted); font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; transition: color 0.4s; }
|
||||
|
||||
.akun-grid { display: flex; flex-direction: column; gap: 8px; }
|
||||
|
||||
.akun-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 10px 14px;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 12px;
|
||||
cursor: pointer;
|
||||
transition: all 0.2s;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.akun-item:hover {
|
||||
border-color: var(--accent);
|
||||
background: var(--tag-bg);
|
||||
}
|
||||
|
||||
.akun-left { display: flex; align-items: center; gap: 10px; }
|
||||
|
||||
.akun-icon {
|
||||
width: 32px; height: 32px;
|
||||
border-radius: 9px;
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.ai-admin { background: rgba(37,99,235,0.15); color: #60a5fa; }
|
||||
.ai-wali { background: rgba(245,158,11,0.15); color: #fbbf24; }
|
||||
|
||||
[data-theme="light"] .ai-admin { background: #eff6ff; color: #2563eb; }
|
||||
[data-theme="light"] .ai-wali { background: #fffbeb; color: #d97706; }
|
||||
|
||||
.akun-info-name {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--text);
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.akun-info-pass {
|
||||
font-size: 11px;
|
||||
color: var(--muted);
|
||||
margin-top: 1px;
|
||||
transition: color 0.4s;
|
||||
}
|
||||
|
||||
.akun-badge {
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
padding: 3px 10px;
|
||||
border-radius: 999px;
|
||||
letter-spacing: 0.03em;
|
||||
}
|
||||
|
||||
.ab-admin { background: rgba(37,99,235,0.15); color: #60a5fa; }
|
||||
.ab-wali { background: rgba(245,158,11,0.15); color: #fbbf24; }
|
||||
|
||||
[data-theme="light"] .ab-admin { background: #eff6ff; color: #1d4ed8; }
|
||||
[data-theme="light"] .ab-wali { background: #fffbeb; color: #b45309; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="orb orb1"></div>
|
||||
<div class="orb orb2"></div>
|
||||
<div class="orb orb3"></div>
|
||||
|
||||
<button class="theme-toggle" onclick="toggleTheme()" title="Toggle tema">
|
||||
<i class="fa-solid fa-sun" id="theme-icon"></i>
|
||||
</button>
|
||||
|
||||
<div class="card">
|
||||
|
||||
<div class="logo-wrap">
|
||||
<div class="logo-icon"><i class="fa-solid fa-map-location-dot"></i></div>
|
||||
<div class="logo-text">
|
||||
<h1>WebGIS Pontianak</h1>
|
||||
<p>Sistem Informasi Geografis Kota Pontianak</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="badge-live">
|
||||
<span class="dot-live"></span> Sistem Online
|
||||
</div>
|
||||
|
||||
<div class="heading">Selamat Datang</div>
|
||||
<div class="subheading">Masuk ke akun Anda untuk mengakses peta</div>
|
||||
|
||||
<div class="divider"></div>
|
||||
|
||||
<?php if ($error): ?>
|
||||
<div class="error-box">
|
||||
<i class="fa-solid fa-circle-exclamation"></i>
|
||||
<?= htmlspecialchars($error) ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<form method="POST">
|
||||
<div class="field">
|
||||
<label>Username</label>
|
||||
<div class="input-wrap">
|
||||
<i class="fa-solid fa-user ico"></i>
|
||||
<input type="text" name="username" placeholder="Masukkan username" required autocomplete="off">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="field">
|
||||
<label>Password</label>
|
||||
<div class="input-wrap">
|
||||
<i class="fa-solid fa-lock ico"></i>
|
||||
<input type="password" name="password" id="pw" placeholder="Masukkan password" required>
|
||||
<button type="button" class="eye-btn" onclick="togglePw()">
|
||||
<i class="fa-solid fa-eye" id="eye-icon"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<button type="submit" class="btn-login">
|
||||
<i class="fa-solid fa-right-to-bracket"></i> Masuk ke Sistem
|
||||
</button>
|
||||
</form>
|
||||
|
||||
<div class="akun-label">
|
||||
<div class="akun-line"></div>
|
||||
<span class="akun-text">Akun Tersedia</span>
|
||||
<div class="akun-line"></div>
|
||||
</div>
|
||||
|
||||
<div class="akun-grid">
|
||||
<div class="akun-item" onclick="fillLogin('admin','admin123')">
|
||||
<div class="akun-left">
|
||||
<div class="akun-icon ai-admin"><i class="fa-solid fa-shield-halved"></i></div>
|
||||
<div>
|
||||
<div class="akun-info-name">admin</div>
|
||||
<div class="akun-info-pass">admin123</div>
|
||||
</div>
|
||||
</div>
|
||||
<span class="akun-badge ab-admin">Administrator</span>
|
||||
</div>
|
||||
|
||||
<div class="akun-item" onclick="fillLogin('walikota','walikota123')">
|
||||
<div class="akun-left">
|
||||
<div class="akun-icon ai-wali"><i class="fa-solid fa-star"></i></div>
|
||||
<div>
|
||||
<div class="akun-info-name">walikota</div>
|
||||
<div class="akun-info-pass">walikota123</div>
|
||||
</div>
|
||||
</div>
|
||||
<span class="akun-badge ab-wali">Walikota</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function toggleTheme() {
|
||||
const html = document.documentElement;
|
||||
const icon = document.getElementById('theme-icon');
|
||||
if (html.getAttribute('data-theme') === 'dark') {
|
||||
html.setAttribute('data-theme', 'light');
|
||||
icon.className = 'fa-solid fa-moon';
|
||||
} else {
|
||||
html.setAttribute('data-theme', 'dark');
|
||||
icon.className = 'fa-solid fa-sun';
|
||||
}
|
||||
}
|
||||
|
||||
function togglePw() {
|
||||
const pw = document.getElementById('pw');
|
||||
const icon = document.getElementById('eye-icon');
|
||||
if (pw.type === 'password') {
|
||||
pw.type = 'text';
|
||||
icon.className = 'fa-solid fa-eye-slash';
|
||||
} else {
|
||||
pw.type = 'password';
|
||||
icon.className = 'fa-solid fa-eye';
|
||||
}
|
||||
}
|
||||
|
||||
function fillLogin(user, pass) {
|
||||
document.querySelector('input[name="username"]').value = user;
|
||||
document.getElementById('pw').value = pass;
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?php
|
||||
session_start();
|
||||
session_destroy();
|
||||
header('Location: login.php');
|
||||
exit;
|
||||
?>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
// Ambil data kiriman dari form edit_masjid.php
|
||||
$id = $_POST['id'];
|
||||
$nama_masjid = $_POST['nama_masjid'];
|
||||
$nama_pic = $_POST['nama_pic'];
|
||||
$radius_meter = $_POST['radius_meter'];
|
||||
|
||||
// Proteksi data sederhana agar aman dari bad character
|
||||
$id = mysqli_real_escape_string($conn, $id);
|
||||
$nama_masjid = mysqli_real_escape_string($conn, $nama_masjid);
|
||||
$nama_pic = mysqli_real_escape_string($conn, $nama_pic);
|
||||
$radius_meter = (int)$radius_meter;
|
||||
|
||||
// Query update data masjid berdasarkan ID
|
||||
$query = "UPDATE masjid SET
|
||||
nama_masjid='$nama_masjid',
|
||||
nama_pic='$nama_pic',
|
||||
radius_meter='$radius_meter'
|
||||
WHERE id='$id'";
|
||||
|
||||
$update = mysqli_query($conn, $query);
|
||||
|
||||
if ($update) {
|
||||
// Jika berhasil, langsung lempar balik secara otomatis ke index.php (Peta)
|
||||
echo "<script>
|
||||
alert('Data Masjid Berhasil Diperbarui!');
|
||||
window.location.href='index.php';
|
||||
</script>";
|
||||
} else {
|
||||
// Jika gagal, tampilkan pesan errornya biar ketahuan salahnya di mana
|
||||
echo "Gagal memperbarui data ke database: " . mysqli_error($conn);
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
// Menangkap data dari form edit
|
||||
$id = $_POST['id'];
|
||||
$nama_kk = $_POST['nama_kk'];
|
||||
$alamat = $_POST['alamat'];
|
||||
$umur = (int)$_POST['umur'];
|
||||
$pendidikan_terakhir = $_POST['pendidikan_terakhir'];
|
||||
$latitude = $_POST['latitude'];
|
||||
$longitude = $_POST['longitude'];
|
||||
|
||||
// Solusi pengaman: Cek jika form mengirimkan 'anggota_keluarga' atau 'jumlah_keluarga'
|
||||
if (isset($_POST['anggota_keluarga'])) {
|
||||
$jumlah_keluarga = (int)$_POST['anggota_keluarga'];
|
||||
} elseif (isset($_POST['jumlah_keluarga'])) {
|
||||
$jumlah_keluarga = (int)$_POST['jumlah_keluarga'];
|
||||
} else {
|
||||
$jumlah_keluarga = 0; // Nilai default berupa angka agar tidak memicu fatal error database
|
||||
}
|
||||
|
||||
// Query Update Data ke Database
|
||||
$query = "UPDATE penduduk_miskin SET
|
||||
nama_kk = '$nama_kk',
|
||||
alamat = '$alamat',
|
||||
jumlah_keluarga = '$jumlah_keluarga',
|
||||
umur = '$umur',
|
||||
pendidikan_terakhir = '$pendidikan_terakhir',
|
||||
latitude = '$latitude',
|
||||
longitude = '$longitude'
|
||||
WHERE id = '$id'";
|
||||
|
||||
$n = mysqli_query($conn, $query);
|
||||
|
||||
if ($n) {
|
||||
echo "<script>alert('Data warga miskin berhasil diperbarui!'); window.location='index.php';</script>";
|
||||
} else {
|
||||
echo "Gagal memperbarui data: " . mysqli_error($conn);
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
$id = mysqli_real_escape_string($conn, $_POST['id']);
|
||||
$nama_pelapor = mysqli_real_escape_string($conn, $_POST['nama_pelapor']);
|
||||
$kontak_pelapor = mysqli_real_escape_string($conn, $_POST['kontak_pelapor']);
|
||||
$deskripsi_laporan = mysqli_real_escape_string($conn, $_POST['deskripsi_laporan']);
|
||||
|
||||
$query = "UPDATE pengaduan_warga SET
|
||||
nama_pelapor = '$nama_pelapor',
|
||||
kontak_pelapor = '$kontak_pelapor',
|
||||
deskripsi_laporan = '$deskripsi_laporan'
|
||||
WHERE id = '$id'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>
|
||||
alert('Laporan pengaduan berhasil diperbarui!');
|
||||
window.location.href='index.php';
|
||||
</script>";
|
||||
} else {
|
||||
echo "Gagal memperbarui data: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
$nama = mysqli_real_escape_string($conn, $_POST['nama_pelapor'] ?? '');
|
||||
$kontak = mysqli_real_escape_string($conn, $_POST['kontak_pelapor'] ?? '');
|
||||
$kategori = mysqli_real_escape_string($conn, $_POST['kategori'] ?? 'Lainnya');
|
||||
$deskripsi= mysqli_real_escape_string($conn, $_POST['deskripsi_laporan'] ?? '');
|
||||
$lat = (float)($_POST['latitude'] ?? 0);
|
||||
$lng = (float)($_POST['longitude'] ?? 0);
|
||||
|
||||
$sql = "INSERT INTO laporan_cepat (nama_pelapor, kontak_pelapor, kategori, deskripsi, latitude, longitude)
|
||||
VALUES ('$nama','$kontak','$kategori','$deskripsi',$lat,$lng)";
|
||||
mysqli_query($conn, $sql);
|
||||
header('Location: index.php');
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
$nama_kk = mysqli_real_escape_string($conn, $_POST['nama_kk'] ?? '');
|
||||
$alamat = mysqli_real_escape_string($conn, $_POST['alamat'] ?? '');
|
||||
$anggota = (int)($_POST['anggota_keluarga'] ?? 0);
|
||||
$umur = (int)($_POST['umur'] ?? 0);
|
||||
$tanggal_lahir = mysqli_real_escape_string($conn, $_POST['tanggal_lahir'] ?? '');
|
||||
$pendidikan = mysqli_real_escape_string($conn, $_POST['pendidikan_terakhir'] ?? '');
|
||||
$riwayat_penyakit = mysqli_real_escape_string($conn, $_POST['riwayat_penyakit'] ?? '');
|
||||
$lat = (float)($_POST['latitude'] ?? 0);
|
||||
$lng = (float)($_POST['longitude'] ?? 0);
|
||||
|
||||
$sql = "INSERT INTO penduduk_miskin
|
||||
(nama_kk, alamat, anggota_keluarga, umur, tanggal_lahir, pendidikan_terakhir, riwayat_penyakit, latitude, longitude)
|
||||
VALUES ('$nama_kk','$alamat',$anggota,$umur,'$tanggal_lahir','$pendidikan','$riwayat_penyakit',$lat,$lng)";
|
||||
|
||||
mysqli_query($conn, $sql);
|
||||
header('Location: index.php');
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
$nama_pelapor = mysqli_real_escape_string($conn, $_POST['nama_pelapor']);
|
||||
$kontak_pelapor = mysqli_real_escape_string($conn, $_POST['kontak_pelapor']);
|
||||
$deskripsi_laporan = mysqli_real_escape_string($conn, $_POST['deskripsi_laporan']);
|
||||
$latitude = mysqli_real_escape_string($conn, $_POST['latitude']);
|
||||
$longitude = mysqli_real_escape_string($conn, $_POST['longitude']);
|
||||
|
||||
$query = "INSERT INTO pengaduan_warga (nama_pelapor, kontak_pelapor, deskripsi_laporan, latitude, longitude)
|
||||
VALUES ('$nama_pelapor', '$kontak_pelapor', '$deskripsi_laporan', '$latitude', '$longitude')";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>alert('Laporan Pengaduan berhasil dikirim!'); window.location.href='index.php';</script>";
|
||||
} else {
|
||||
echo "Error: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$nama_masjid = mysqli_real_escape_string($conn, $_POST['nama_masjid']);
|
||||
$nama_pic = mysqli_real_escape_string($conn, $_POST['nama_pic']);
|
||||
$lat = (float)$_POST['latitude'];
|
||||
$lng = (float)$_POST['longitude'];
|
||||
|
||||
$query = "INSERT INTO masjid (nama_masjid, nama_pic, latitude, longitude)
|
||||
VALUES ('$nama_masjid', '$nama_pic', '$lat', '$lng')";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "<script>alert('Data Masjid berhasil disimpan!'); window.location='index.php';</script>";
|
||||
} else {
|
||||
echo "Gagal menyimpan: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$id = (int)$_POST['id'];
|
||||
$radius_baru = (int)$_POST['radius_baru'];
|
||||
|
||||
$query = "UPDATE masjid SET radius_meter = '$radius_baru' WHERE id = '$id'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "ok";
|
||||
} else {
|
||||
echo "Gagal: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
include 'koneksi.php';
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
$id_warga = (int)$_POST['id_warga'];
|
||||
$radius_baru_warga = (int)$_POST['radius_baru_warga'];
|
||||
|
||||
$query = "UPDATE penduduk_miskin SET radius_warga = '$radius_baru_warga' WHERE id = '$id_warga'";
|
||||
|
||||
if (mysqli_query($conn, $query)) {
|
||||
echo "ok";
|
||||
} else {
|
||||
echo "Gagal: " . mysqli_error($conn);
|
||||
}
|
||||
}
|
||||
?>
|
||||
Reference in New Issue
Block a user