edit files
This commit is contained in:
@@ -17,3 +17,9 @@ CREATE TABLE IF NOT EXISTS spbu (
|
||||
|
||||
ALTER TABLE spbu
|
||||
MODIFY status ENUM('yes','no') NOT NULL DEFAULT 'no';
|
||||
|
||||
-- Insert Dummy Data for Testing
|
||||
INSERT INTO spbu (nama_spbu, no_wa, status, latitude, longitude) VALUES
|
||||
('SPBU Ahmad Yani', '081234567890', 'yes', -0.026300, 109.342500),
|
||||
('SPBU Tanjungpura', '089876543210', 'no', -0.018500, 109.331500),
|
||||
('SPBU Sungai Jawi', '085211223344', 'yes', -0.011200, 109.320500);
|
||||
|
||||
+2
-2
@@ -148,7 +148,7 @@ map.on('click', function(e) {
|
||||
const lat = e.latlng.lat;
|
||||
const lng = e.latlng.lng;
|
||||
|
||||
const form =
|
||||
const form = `
|
||||
<form id="formInput">
|
||||
Nama SPBU:<br>
|
||||
<input type="text" name="nama_spbu" required><br>
|
||||
@@ -167,7 +167,7 @@ map.on('click', function(e) {
|
||||
|
||||
<button type="submit">Simpan</button>
|
||||
</form>
|
||||
;
|
||||
`;
|
||||
|
||||
L.popup().setLatLng(e.latlng).setContent(form).openOn(map);
|
||||
|
||||
|
||||
@@ -49,6 +49,21 @@ CREATE TABLE jalan_rusak (
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
-- Insert Dummy Data for data_jalan
|
||||
USE data_jalan;
|
||||
INSERT INTO jalan (nama, status, panjang, geometry) VALUES
|
||||
('Jalan Ahmad Yani', 'baik', 1200, '{"type":"LineString","coordinates":[[109.342500,-0.026300],[109.350000,-0.030000]]}'),
|
||||
('Jalan Tanjungpura', 'sedang', 800, '{"type":"LineString","coordinates":[[109.331500,-0.018500],[109.340000,-0.020000]]}');
|
||||
|
||||
INSERT INTO parsil (pemilik, status, luas, geometry) VALUES
|
||||
('Budi', 'milik_sendiri', 500, '{"type":"Polygon","coordinates":[[[109.342500,-0.026300],[109.343500,-0.026300],[109.343500,-0.027300],[109.342500,-0.027300],[109.342500,-0.026300]]]}');
|
||||
|
||||
-- Insert Dummy Data for webgis
|
||||
USE webgis;
|
||||
INSERT INTO jalan_rusak (keterangan, tingkat, geometry) VALUES
|
||||
('Lubang besar', 'berat', '{"type":"Point","coordinates":[109.340000,-0.020000]}');
|
||||
|
||||
-- ============================================================
|
||||
-- SELESAI — 2 database, 3 tabel siap dipakai
|
||||
-- ============================================================
|
||||
|
||||
+2
-2
@@ -10,8 +10,8 @@ services:
|
||||
SERVICE_FQDN_WEBGIS:
|
||||
DB_HOST: mysql
|
||||
DB_PORT: 3306
|
||||
DB_USER: ${MYSQL_USER:-webgis}
|
||||
DB_PASSWORD: ${MYSQL_PASSWORD:-webgis_password}
|
||||
DB_USER: root
|
||||
DB_PASSWORD: ${MYSQL_ROOT_PASSWORD:-root_password}
|
||||
DB_NAME_GIS_SPBU: gis_spbu
|
||||
DB_NAME_DATA_JALAN: data_jalan
|
||||
DB_NAME_WEBGIS: webgis
|
||||
|
||||
Reference in New Issue
Block a user