tambah folder modul
This commit is contained in:
270
FOLDER/Managemen Pelanggan/page/dashboar_pelanggan.html
Normal file
270
FOLDER/Managemen Pelanggan/page/dashboar_pelanggan.html
Normal file
@@ -0,0 +1,270 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Dashboard Pelanggan - Lab Lingkungan</title>
|
||||
<style>
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
line-height: 1.6;
|
||||
background-color: #f4f4f4;
|
||||
}
|
||||
|
||||
.container {
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.dashboard-header {
|
||||
background: white;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
margin-bottom: 20px;
|
||||
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.customer-info {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: 20px;
|
||||
}
|
||||
|
||||
.info-card {
|
||||
background: #fff;
|
||||
padding: 15px;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.stats-container {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
gap: 20px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.stat-card {
|
||||
background: white;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
text-align: center;
|
||||
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.stat-number {
|
||||
font-size: 24px;
|
||||
font-weight: bold;
|
||||
color: #2196F3;
|
||||
}
|
||||
|
||||
.recent-requests {
|
||||
background: white;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
margin-bottom: 20px;
|
||||
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
th, td {
|
||||
padding: 12px;
|
||||
text-align: left;
|
||||
border-bottom: 1px solid #ddd;
|
||||
}
|
||||
|
||||
th {
|
||||
background-color: #f8f9fa;
|
||||
}
|
||||
|
||||
.status {
|
||||
padding: 5px 10px;
|
||||
border-radius: 15px;
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.status-new { background: #e3f2fd; color: #1565c0; }
|
||||
.status-process { background: #fff3e0; color: #ef6c00; }
|
||||
.status-completed { background: #e8f5e9; color: #2e7d32; }
|
||||
.status-cancelled { background: #ffebee; color: #c62828; }
|
||||
|
||||
.btn {
|
||||
padding: 8px 15px;
|
||||
border-radius: 4px;
|
||||
text-decoration: none;
|
||||
color: white;
|
||||
font-size: 14px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.btn-primary { background-color: #2196F3; }
|
||||
.btn-success { background-color: #4CAF50; }
|
||||
|
||||
.notification-panel {
|
||||
background: white;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.notification-item {
|
||||
padding: 10px;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
.notification-item:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="dashboard-header">
|
||||
<h1>Dashboard Pelanggan</h1>
|
||||
<div class="customer-info">
|
||||
<div class="info-card">
|
||||
<h3>Informasi Perusahaan</h3>
|
||||
<p>PT Lingkungan Hijau</p>
|
||||
<p>CUST001</p>
|
||||
</div>
|
||||
<div class="info-card">
|
||||
<h3>Kontak PIC</h3>
|
||||
<p>Budi Santoso</p>
|
||||
<p>081234567890</p>
|
||||
</div>
|
||||
<div class="info-card">
|
||||
<h3>Status Akun</h3>
|
||||
<p>Aktif</p>
|
||||
<p>Sejak: 15 Mar 2024</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="stats-container">
|
||||
<div class="stat-card">
|
||||
<h3>Total Permintaan</h3>
|
||||
<div class="stat-number">15</div>
|
||||
</div>
|
||||
<div class="stat-card">
|
||||
<h3>Dalam Proses</h3>
|
||||
<div class="stat-number">3</div>
|
||||
</div>
|
||||
<div class="stat-card">
|
||||
<h3>Selesai</h3>
|
||||
<div class="stat-number">11</div>
|
||||
</div>
|
||||
<div class="stat-card">
|
||||
<h3>Total Pembayaran</h3>
|
||||
<div class="stat-number">Rp 25.5M</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="recent-requests">
|
||||
<div style="display: flex; justify-content: space-between; align-items: center;">
|
||||
<h2>Permintaan Analisis Terbaru</h2>
|
||||
<a href="#" class="btn btn-primary">Buat Permintaan Baru</a>
|
||||
</div>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Kode</th>
|
||||
<th>Tanggal</th>
|
||||
<th>Jenis Analisis</th>
|
||||
<th>Status</th>
|
||||
<th>Total Biaya</th>
|
||||
<th>Aksi</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>REQ001</td>
|
||||
<td>15 Mar 2024</td>
|
||||
<td>Analisis Air Limbah</td>
|
||||
<td><span class="status status-completed">Selesai</span></td>
|
||||
<td>Rp 2.500.000</td>
|
||||
<td><a href="#" class="btn btn-primary">Lihat Detail</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>REQ002</td>
|
||||
<td>16 Mar 2024</td>
|
||||
<td>Analisis Kualitas Udara</td>
|
||||
<td><span class="status status-process">Proses</span></td>
|
||||
<td>Rp 1.750.000</td>
|
||||
<td><a href="#" class="btn btn-primary">Lihat Detail</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>REQ003</td>
|
||||
<td>17 Mar 2024</td>
|
||||
<td>Analisis Tanah</td>
|
||||
<td><span class="status status-new">Baru</span></td>
|
||||
<td>Rp 3.000.000</td>
|
||||
<td><a href="#" class="btn btn-primary">Lihat Detail</a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div style="display: grid; grid-template-columns: 2fr 1fr; gap: 20px;">
|
||||
<div class="recent-requests">
|
||||
<h2>Riwayat Pembayaran</h2>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Kode</th>
|
||||
<th>Tanggal</th>
|
||||
<th>Jumlah</th>
|
||||
<th>Status</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>PAY001</td>
|
||||
<td>15 Mar 2024</td>
|
||||
<td>Rp 2.500.000</td>
|
||||
<td><span class="status status-completed">Lunas</span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>PAY002</td>
|
||||
<td>16 Mar 2024</td>
|
||||
<td>Rp 875.000</td>
|
||||
<td><span class="status status-process">DP 50%</span></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div class="notification-panel">
|
||||
<h2>Notifikasi</h2>
|
||||
<div class="notification-item">
|
||||
<p><strong>Jadwal Sampling</strong></p>
|
||||
<p>20 Mar 2024 - 09:00</p>
|
||||
<p>Lokasi: Plant A</p>
|
||||
</div>
|
||||
<div class="notification-item">
|
||||
<p><strong>Hasil Analisis Selesai</strong></p>
|
||||
<p>REQ001 telah selesai</p>
|
||||
<p>15 Mar 2024</p>
|
||||
</div>
|
||||
<div class="notification-item">
|
||||
<p><strong>Pembayaran Diterima</strong></p>
|
||||
<p>PAY001 - Rp 2.500.000</p>
|
||||
<p>15 Mar 2024</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
140
FOLDER/Managemen Pelanggan/page/form_pendaftaran_pelanggan.html
Normal file
140
FOLDER/Managemen Pelanggan/page/form_pendaftaran_pelanggan.html
Normal file
@@ -0,0 +1,140 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Pendaftaran Pelanggan - Lab Lingkungan</title>
|
||||
<style>
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
line-height: 1.6;
|
||||
background-color: #f4f4f4;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.container {
|
||||
max-width: 800px;
|
||||
margin: 0 auto;
|
||||
background: white;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 0 10px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.form-group {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
||||
label {
|
||||
display: block;
|
||||
margin-bottom: 5px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
input[type="text"],
|
||||
input[type="email"],
|
||||
input[type="tel"],
|
||||
select,
|
||||
textarea {
|
||||
width: 100%;
|
||||
padding: 8px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 4px;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.btn {
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
padding: 10px 20px;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.btn:hover {
|
||||
background-color: #45a049;
|
||||
}
|
||||
|
||||
.form-header {
|
||||
text-align: center;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="form-header">
|
||||
<h1>Pendaftaran Pelanggan Baru</h1>
|
||||
<p>Silakan lengkapi form di bawah ini</p>
|
||||
</div>
|
||||
|
||||
<form id="customerForm">
|
||||
<div class="form-group">
|
||||
<label for="companyName">Nama Perusahaan</label>
|
||||
<input type="text" id="companyName" name="companyName" required>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="customerType">Jenis Pelanggan</label>
|
||||
<select id="customerType" name="customerType" required>
|
||||
<option value="">Pilih Jenis Pelanggan</option>
|
||||
<option value="internal">Internal</option>
|
||||
<option value="external">External</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="address">Alamat</label>
|
||||
<textarea id="address" name="address" rows="3" required></textarea>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="city">Kota</label>
|
||||
<input type="text" id="city" name="city" required>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="postalCode">Kode Pos</label>
|
||||
<input type="text" id="postalCode" name="postalCode" required>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="phone">Telepon Perusahaan</label>
|
||||
<input type="tel" id="phone" name="phone" required>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="email">Email Perusahaan</label>
|
||||
<input type="email" id="email" name="email" required>
|
||||
</div>
|
||||
|
||||
<h3>Informasi PIC</h3>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="picName">Nama PIC</label>
|
||||
<input type="text" id="picName" name="picName" required>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="picPhone">Telepon PIC</label>
|
||||
<input type="tel" id="picPhone" name="picPhone" required>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="picEmail">Email PIC</label>
|
||||
<input type="email" id="picEmail" name="picEmail" required>
|
||||
</div>
|
||||
|
||||
<button type="submit" class="btn">Daftar</button>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
65
FOLDER/Managemen Pelanggan/query.sql
Normal file
65
FOLDER/Managemen Pelanggan/query.sql
Normal file
@@ -0,0 +1,65 @@
|
||||
-- Tabel Pelanggan
|
||||
CREATE TABLE customers (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
customer_code VARCHAR(20) UNIQUE,
|
||||
company_name VARCHAR(100),
|
||||
customer_type ENUM('internal', 'external'),
|
||||
address TEXT,
|
||||
city VARCHAR(50),
|
||||
postal_code VARCHAR(10),
|
||||
phone VARCHAR(20),
|
||||
email VARCHAR(100),
|
||||
pic_name VARCHAR(100),
|
||||
pic_phone VARCHAR(20),
|
||||
pic_email VARCHAR(100),
|
||||
registration_date DATETIME DEFAULT CURRENT_TIMESTAMP,
|
||||
status ENUM('active', 'inactive') DEFAULT 'active',
|
||||
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
|
||||
updated_at DATETIME ON UPDATE CURRENT_TIMESTAMP
|
||||
);
|
||||
|
||||
-- Tabel Riwayat Permintaan Analisis
|
||||
CREATE TABLE analysis_requests (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
request_code VARCHAR(20) UNIQUE,
|
||||
customer_id INT,
|
||||
request_date DATETIME,
|
||||
status ENUM('new', 'process', 'completed', 'cancelled'),
|
||||
total_amount DECIMAL(10,2),
|
||||
notes TEXT,
|
||||
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
|
||||
FOREIGN KEY (customer_id) REFERENCES customers(id)
|
||||
);
|
||||
|
||||
-- Tabel Riwayat Pembayaran
|
||||
CREATE TABLE payments (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
request_id INT,
|
||||
payment_code VARCHAR(20) UNIQUE,
|
||||
payment_date DATETIME,
|
||||
amount DECIMAL(10,2),
|
||||
payment_method ENUM('cash', 'transfer', 'credit_card'),
|
||||
payment_status ENUM('pending', 'completed', 'failed'),
|
||||
proof_of_payment VARCHAR(255),
|
||||
notes TEXT,
|
||||
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
|
||||
FOREIGN KEY (request_id) REFERENCES analysis_requests(id)
|
||||
);
|
||||
|
||||
-- Contoh data pelanggan
|
||||
INSERT INTO customers (customer_code, company_name, customer_type, address, city, postal_code, phone, email, pic_name, pic_phone, pic_email) VALUES
|
||||
('CUST001', 'PT Lingkungan Hijau', 'external', 'Jl. Raya Utama No. 123', 'Jakarta', '12345', '021-5551234', 'info@lingkunganhijau.com', 'Budi Santoso', '081234567890', 'budi@lingkunganhijau.com'),
|
||||
('CUST002', 'Dinas Lingkungan Hidup', 'internal', 'Jl. Pemda No. 45', 'Bandung', '40111', '022-7891234', 'dlh@bandung.go.id', 'Siti Aminah', '087812345678', 'siti@bandung.go.id'),
|
||||
('CUST003', 'CV Alam Lestari', 'external', 'Jl. Industri Blok A2', 'Surabaya', '60111', '031-8765432', 'contact@alamlestari.com', 'Rudi Hartono', '085678901234', 'rudi@alamlestari.com');
|
||||
|
||||
-- Contoh data permintaan analisis
|
||||
INSERT INTO analysis_requests (request_code, customer_id, request_date, status, total_amount, notes) VALUES
|
||||
('REQ001', 1, '2024-03-15 09:00:00', 'completed', 2500000, 'Analisis air limbah'),
|
||||
('REQ002', 1, '2024-03-16 10:30:00', 'process', 1750000, 'Analisis kualitas udara'),
|
||||
('REQ003', 2, '2024-03-17 13:15:00', 'new', 3000000, 'Analisis tanah');
|
||||
|
||||
-- Contoh data pembayaran
|
||||
INSERT INTO payments (request_id, payment_code, payment_date, amount, payment_method, payment_status, notes) VALUES
|
||||
(1, 'PAY001', '2024-03-15 14:30:00', 2500000, 'transfer', 'completed', 'Pembayaran lunas'),
|
||||
(2, 'PAY002', '2024-03-16 11:00:00', 875000, 'transfer', 'completed', 'Pembayaran DP 50%'),
|
||||
(3, 'PAY003', '2024-03-17 14:00:00', 1500000, 'transfer', 'pending', 'Menunggu konfirmasi transfer');
|
||||
182
FOLDER/Permintaan Layanan/page/permintaan_layanan.html
Normal file
182
FOLDER/Permintaan Layanan/page/permintaan_layanan.html
Normal file
@@ -0,0 +1,182 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Form Permintaan Layanan - Lab Lingkungan</title>
|
||||
<style>
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
line-height: 1.6;
|
||||
background-color: #f4f4f4;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.container {
|
||||
max-width: 1000px;
|
||||
margin: 0 auto;
|
||||
background: white;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 0 10px rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.form-header {
|
||||
text-align: center;
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
|
||||
.form-section {
|
||||
margin-bottom: 30px;
|
||||
padding: 20px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.form-group {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
||||
label {
|
||||
display: block;
|
||||
margin-bottom: 5px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
input[type="text"],
|
||||
input[type="date"],
|
||||
input[type="number"],
|
||||
select,
|
||||
textarea {
|
||||
width: 100%;
|
||||
padding: 8px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 4px;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.parameter-list {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.parameter-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 10px;
|
||||
border: 1px solid #ddd;
|
||||
margin-bottom: 10px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.parameter-item label {
|
||||
margin: 0;
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
.price-summary {
|
||||
background: #f8f9fa;
|
||||
padding: 20px;
|
||||
border-radius: 4px;
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.btn {
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
padding: 10px 20px;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.btn:hover {
|
||||
background-color: #45a049;
|
||||
}
|
||||
|
||||
.btn-secondary {
|
||||
background-color: #6c757d;
|
||||
}
|
||||
|
||||
.actions {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
margin-top: 20px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="form-header">
|
||||
<h1>Form Permintaan Layanan Analisis</h1>
|
||||
<p>Silakan lengkapi informasi di bawah ini</p>
|
||||
</div>
|
||||
|
||||
<form id="serviceRequestForm">
|
||||
<div class="form-section">
|
||||
<h3>Informasi Umum</h3>
|
||||
<div class="form-group">
|
||||
<label for="requestType">Jenis Layanan</label>
|
||||
<select id="requestType" name="requestType" required>
|
||||
<option value="">Pilih Jenis Layanan</option>
|
||||
<option value="sampling_analysis">Sampling & Analisis</option>
|
||||
<option value="analysis_only">Analisis Saja</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="samplingDate">Tanggal Sampling</label>
|
||||
<input type="date" id="samplingDate" name="samplingDate">
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="samplingLocation">Lokasi Sampling</label>
|
||||
<textarea id="samplingLocation" name="samplingLocation" rows="3"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-section">
|
||||
<h3>Parameter Analisis</h3>
|
||||
<div class="parameter-list">
|
||||
<div class="parameter-item">
|
||||
<input type="checkbox" id="param1" name="parameters[]" value="1">
|
||||
<label for="param1">BOD (Biochemical Oxygen Demand) - Rp 250.000</label>
|
||||
</div>
|
||||
<div class="parameter-item">
|
||||
<input type="checkbox" id="param2" name="parameters[]" value="2">
|
||||
<label for="param2">COD (Chemical Oxygen Demand) - Rp 200.000</label>
|
||||
</div>
|
||||
<div class="parameter-item">
|
||||
<input type="checkbox" id="param3" name="parameters[]" value="3">
|
||||
<label for="param3">TSS (Total Suspended Solid) - Rp 150.000</label>
|
||||
</div>
|
||||
<div class="parameter-item">
|
||||
<input type="checkbox" id="param4" name="parameters[]" value="4">
|
||||
<label for="param4">pH - Rp 100.000</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-section">
|
||||
<h3>Ringkasan Biaya</h3>
|
||||
<div class="price-summary">
|
||||
<p>Subtotal: Rp 0</p>
|
||||
<p>PPN (11%): Rp 0</p>
|
||||
<p><strong>Total: Rp 0</strong></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="actions">
|
||||
<button type="button" class="btn btn-secondary">Simpan Draft</button>
|
||||
<button type="submit" class="btn">Kirim Permintaan</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
95
FOLDER/Permintaan Layanan/query.sql
Normal file
95
FOLDER/Permintaan Layanan/query.sql
Normal file
@@ -0,0 +1,95 @@
|
||||
-- Tabel Template Sampling
|
||||
CREATE TABLE sampling_templates (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
template_name VARCHAR(100),
|
||||
description TEXT,
|
||||
created_at DATETIME DEFAULT CURRENT_TIMESTAMP
|
||||
);
|
||||
|
||||
-- Tabel Parameter Analisis
|
||||
CREATE TABLE analysis_parameters (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
parameter_code VARCHAR(20),
|
||||
parameter_name VARCHAR(100),
|
||||
unit VARCHAR(20),
|
||||
price DECIMAL(10,2),
|
||||
method VARCHAR(100),
|
||||
created_at DATETIME DEFAULT CURRENT_TIMESTAMP
|
||||
);
|
||||
|
||||
-- Tabel Permintaan Layanan
|
||||
CREATE TABLE service_requests (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
request_code VARCHAR(20) UNIQUE,
|
||||
customer_id INT,
|
||||
request_type ENUM('sampling_analysis', 'analysis_only'),
|
||||
sampling_date DATE,
|
||||
sampling_location TEXT,
|
||||
status ENUM('draft', 'submitted', 'approved', 'rejected', 'in_progress', 'completed'),
|
||||
total_amount DECIMAL(10,2),
|
||||
dp_amount DECIMAL(10,2),
|
||||
dp_status ENUM('unpaid', 'paid') DEFAULT 'unpaid',
|
||||
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
|
||||
FOREIGN KEY (customer_id) REFERENCES customers(id)
|
||||
);
|
||||
|
||||
-- Tabel Detail Parameter yang Diminta
|
||||
CREATE TABLE request_parameters (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
request_id INT,
|
||||
parameter_id INT,
|
||||
price DECIMAL(10,2),
|
||||
notes TEXT,
|
||||
FOREIGN KEY (request_id) REFERENCES service_requests(id),
|
||||
FOREIGN KEY (parameter_id) REFERENCES analysis_parameters(id)
|
||||
);
|
||||
|
||||
-- Tabel Quotation
|
||||
CREATE TABLE quotations (
|
||||
id INT PRIMARY KEY AUTO_INCREMENT,
|
||||
quotation_code VARCHAR(20) UNIQUE,
|
||||
request_id INT,
|
||||
issue_date DATE,
|
||||
valid_until DATE,
|
||||
status ENUM('draft', 'sent', 'approved', 'rejected'),
|
||||
total_amount DECIMAL(10,2),
|
||||
notes TEXT,
|
||||
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
|
||||
FOREIGN KEY (request_id) REFERENCES service_requests(id)
|
||||
);
|
||||
|
||||
-- Contoh data template sampling
|
||||
INSERT INTO sampling_templates (template_name, description) VALUES
|
||||
('Air Limbah Industri', 'Template untuk sampling air limbah industri'),
|
||||
('Kualitas Udara Ambien', 'Template untuk sampling kualitas udara'),
|
||||
('Air Permukaan', 'Template untuk sampling air sungai/danau');
|
||||
|
||||
-- Contoh data parameter analisis
|
||||
INSERT INTO analysis_parameters (parameter_code, parameter_name, unit, price, method) VALUES
|
||||
('BOD5', 'Biochemical Oxygen Demand', 'mg/L', 250000, 'SNI 6989.72:2009'),
|
||||
('COD', 'Chemical Oxygen Demand', 'mg/L', 200000, 'SNI 6989.2:2009'),
|
||||
('TSS', 'Total Suspended Solid', 'mg/L', 150000, 'SNI 06-6989.3-2004'),
|
||||
('PH', 'Derajat Keasaman', '-', 100000, 'SNI 06-6989.11-2004');
|
||||
|
||||
-- Contoh data permintaan layanan
|
||||
INSERT INTO service_requests (request_code, customer_id, request_type, sampling_date, sampling_location, status, total_amount) VALUES
|
||||
('REQ001', 1, 'sampling_analysis', '2024-03-20', 'Plant A - Outlet IPAL', 'approved', 700000),
|
||||
('REQ002', 2, 'analysis_only', '2024-03-21', 'Lab Internal', 'submitted', 450000),
|
||||
('REQ003', 3, 'sampling_analysis', '2024-03-22', 'Intake Water Treatment', 'draft', 550000);
|
||||
|
||||
-- Contoh data parameter yang diminta
|
||||
INSERT INTO request_parameters (request_id, parameter_id, price) VALUES
|
||||
(1, 1, 250000),
|
||||
(1, 2, 200000),
|
||||
(1, 3, 150000),
|
||||
(1, 4, 100000),
|
||||
(2, 1, 250000),
|
||||
(2, 2, 200000),
|
||||
(3, 3, 150000),
|
||||
(3, 4, 100000);
|
||||
|
||||
-- Contoh data quotation
|
||||
INSERT INTO quotations (quotation_code, request_id, issue_date, valid_until, status, total_amount) VALUES
|
||||
('QUO001', 1, '2024-03-15', '2024-04-15', 'approved', 700000),
|
||||
('QUO002', 2, '2024-03-16', '2024-04-16', 'sent', 450000),
|
||||
('QUO003', 3, '2024-03-17', '2024-04-17', 'draft', 550000);
|
||||
Reference in New Issue
Block a user