feat: add base db for init app
This commit is contained in:
parent
c5c8e44752
commit
075020d451
647
sim_rsabhk_db.sql
Normal file
647
sim_rsabhk_db.sql
Normal file
@ -0,0 +1,647 @@
|
||||
-- phpMyAdmin SQL Dump
|
||||
-- version 5.2.1deb3
|
||||
-- https://www.phpmyadmin.net/
|
||||
--
|
||||
-- Host: localhost:3306
|
||||
-- Generation Time: Apr 27, 2025 at 02:56 PM
|
||||
-- Server version: 8.0.41-0ubuntu0.24.04.1
|
||||
-- PHP Version: 8.3.6
|
||||
|
||||
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
|
||||
START TRANSACTION;
|
||||
SET time_zone = "+00:00";
|
||||
|
||||
|
||||
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||
/*!40101 SET NAMES utf8mb4 */;
|
||||
|
||||
--
|
||||
-- Database: `sim_rsabhk_db`
|
||||
--
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `cache`
|
||||
--
|
||||
|
||||
CREATE TABLE `cache` (
|
||||
`key` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`value` mediumtext COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`expiration` int NOT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `cache_locks`
|
||||
--
|
||||
|
||||
CREATE TABLE `cache_locks` (
|
||||
`key` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`owner` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`expiration` int NOT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `failed_jobs`
|
||||
--
|
||||
|
||||
CREATE TABLE `failed_jobs` (
|
||||
`id` bigint UNSIGNED NOT NULL,
|
||||
`uuid` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`connection` text COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`queue` text COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`payload` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`exception` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`failed_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `jobs`
|
||||
--
|
||||
|
||||
CREATE TABLE `jobs` (
|
||||
`id` bigint UNSIGNED NOT NULL,
|
||||
`queue` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`payload` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`attempts` tinyint UNSIGNED NOT NULL,
|
||||
`reserved_at` int UNSIGNED DEFAULT NULL,
|
||||
`available_at` int UNSIGNED NOT NULL,
|
||||
`created_at` int UNSIGNED NOT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `job_batches`
|
||||
--
|
||||
|
||||
CREATE TABLE `job_batches` (
|
||||
`id` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`total_jobs` int NOT NULL,
|
||||
`pending_jobs` int NOT NULL,
|
||||
`failed_jobs` int NOT NULL,
|
||||
`failed_job_ids` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`options` mediumtext COLLATE utf8mb4_unicode_ci,
|
||||
`cancelled_at` int DEFAULT NULL,
|
||||
`created_at` int NOT NULL,
|
||||
`finished_at` int DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `migrations`
|
||||
--
|
||||
|
||||
CREATE TABLE `migrations` (
|
||||
`id` int UNSIGNED NOT NULL,
|
||||
`migration` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`batch` int NOT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `migrations`
|
||||
--
|
||||
|
||||
INSERT INTO `migrations` (`id`, `migration`, `batch`) VALUES
|
||||
(1, '0001_01_01_000000_create_users_table', 1),
|
||||
(2, '0001_01_01_000001_create_cache_table', 1),
|
||||
(3, '0001_01_01_000002_create_jobs_table', 1),
|
||||
(4, '2025_04_25_171116_create_m_employee_table', 1),
|
||||
(5, '2025_04_26_021536_create_m_patient_table', 1),
|
||||
(6, '2025_04_26_042837_create_m_insurance_table', 1),
|
||||
(7, '2025_04_26_060659_create_m_service_room_table', 1),
|
||||
(8, '2025_04_26_082655_create_m_procedure_table', 1),
|
||||
(9, '2025_04_27_045425_create_t_transaction_table', 1),
|
||||
(10, '2025_04_27_050234_create_t_transaction_detail_table', 1),
|
||||
(11, '2025_04_27_050712_create_t_registration_table', 1);
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `m_employee`
|
||||
--
|
||||
|
||||
CREATE TABLE `m_employee` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`user_id` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`employee_id` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`gender` enum('laki-laki','perempuan') COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`nik` varchar(16) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`birth_date` date NOT NULL,
|
||||
`birth_place` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`address` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`phone_number` varchar(15) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`specialization` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`license_number` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`join_date` date NOT NULL,
|
||||
`resign_date` date DEFAULT NULL,
|
||||
`is_active` tinyint(1) NOT NULL DEFAULT '1',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `m_employee`
|
||||
--
|
||||
|
||||
INSERT INTO `m_employee` (`id`, `user_id`, `employee_id`, `gender`, `nik`, `birth_date`, `birth_place`, `address`, `phone_number`, `specialization`, `license_number`, `join_date`, `resign_date`, `is_active`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6b1d5-f08e-4c6f-9979-f199bfd19e01', '9ec6b1d5-f028-4a69-ab83-e76f4261a6a0', 'HK-0001', 'laki-laki', '3505180311000008', '2024-08-05', 'Jakarta', 'Jl. Melati No. 123, Kel. Sukamaju, Kec. Sukasari, Kota Bandung, Jawa Barat 40123', '084743514153', 'Dokter Umum', '7623891', '2025-04-07', NULL, 1, '2025-04-27 06:57:23', '2025-04-27 06:57:23'),
|
||||
('9ec6b298-77ee-4664-b2c1-f889ca630e84', '9ec6b298-7768-4030-bab1-0cd1e4d0cc5d', 'HK-0002', 'laki-laki', '3505180311000002', '2022-01-04', 'Jakarta', 'Jl. Kenanga No. 45A, Kel. Mekarwangi, Kec. Jatisampurna, Kota Bekasi, Jawa Barat 17433', '086649725436', 'Dokter Umum', '9978897', '2025-04-25', NULL, 1, '2025-04-27 06:59:30', '2025-04-27 06:59:30'),
|
||||
('9ec6b2fa-23b9-4587-99fa-9af8425a9e1a', '9ec6b2fa-2324-439f-8e72-3fc12bfda819', 'HK-0003', 'laki-laki', '3505180311000003', '2024-07-15', 'Bandung', 'Jl. Anggrek Raya No. 7, Kel. Bintaro, Kec. Pesanggrahan, Jakarta Selatan, DKI Jakarta 12330', '087897847669', 'Dokter Spesialis Mata (Sp.M)', '6777824', '2025-01-08', '2025-04-21', 0, '2025-04-27 07:00:34', '2025-04-27 07:22:48'),
|
||||
('9ec6b354-aee9-4325-baf2-f4cc1f47091a', '9ec6b354-ae57-4858-98b3-413bdcd4edae', 'HK-0004', 'laki-laki', '3505180311000005', '2023-10-16', 'Bogor', 'Jl. Anggrek Raya No. 7, Kel. Bintaro, Kec. Pesanggrahan, Jakarta Selatan, DKI Jakarta 12330', '082762439324', 'Dokter Spesialis Gigi (Drg.)', '7734678', '2025-04-14', NULL, 1, '2025-04-27 07:01:33', '2025-04-27 07:01:33'),
|
||||
('9ec6b39b-47f6-4880-a2df-8ce9fb969987', '9ec6b39b-476d-4287-9af7-00081b5d7a28', 'HK-0005', 'laki-laki', '3505180311000006', '2025-04-23', 'Bogor', 'Jl. Flamboyan No. 56, Kel. Karanganyar, Kec. Grogol, Kota Surakarta, Jawa Tengah 57141', '086217681732', 'Dokter Spesialis Psikiatri (Sp.KJ)', '2243450', '2025-04-13', NULL, 1, '2025-04-27 07:02:20', '2025-04-27 07:02:20'),
|
||||
('9ec6b3ff-9145-421d-9297-5d82c668d9cd', '9ec6b3ff-90a1-4cba-8da8-8b966de062a6', 'HK-0006', 'laki-laki', '3505180311000007', '2025-04-07', 'Tanggerang', 'Jl. Mawar Putih No. 18, Kel. Purwodadi, Kec. Tegalsari, Kota Surabaya, Jawa Timur 60265', '082628972267', 'Dokter Spesialis Saraf (Sp.N)', '5478934', '2025-01-16', NULL, 1, '2025-04-27 07:03:25', '2025-04-27 07:03:25'),
|
||||
('9ec6b446-9320-4f40-8153-0a490f1e9cda', '9ec6b446-92c6-4aa9-b528-456b300992a7', 'HK-0007', 'laki-laki', '3505180311000008', '2025-04-16', 'Solo', 'Jl. Cemara No. 210, Kel. Antasan Besar, Kec. Banjarmasin Tengah, Kota Banjarmasin, Kalimantan Selatan 70123', '086554597593', 'Dokter Spesialis Anestesi (Sp.An)', '9323061', '2025-04-08', NULL, 1, '2025-04-27 07:04:12', '2025-04-27 07:04:12'),
|
||||
('9ec6b49a-48b9-48c0-bc4f-3179764443c3', '9ec6b49a-4861-430b-b842-249039e819c2', 'HK-0008', 'laki-laki', '3505180311000008', '2025-04-16', 'Yogyakarta', 'Jl. Cemara No. 210, Kel. Antasan Besar, Kec. Banjarmasin Tengah, Kota Banjarmasin, Kalimantan Selatan 70123', '083241188976', 'Dokter Spesialis Radiologi (Sp.Rad)', '4860023', '2025-02-21', NULL, 1, '2025-04-27 07:05:07', '2025-04-27 07:05:07'),
|
||||
('9ec6c69f-8930-4969-8b5e-316871893d79', '9ec6c69f-88c6-43f8-ba4e-4531a926eb76', 'HK-0009', 'laki-laki', '3505180311000011', '1997-04-16', 'Subang', 'Jl. Jati Mulya No. 60, Kel. Harjamukti, Kec. Cimanggis, Kota Depok, Jawa Barat 16454', '086459731654', 'Dokter Spesialis Bedah Saraf (Sp.BS)', '8625467', '2025-01-15', NULL, 1, '2025-04-27 07:55:30', '2025-04-27 07:55:30');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `m_insurance`
|
||||
--
|
||||
|
||||
CREATE TABLE `m_insurance` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`code` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`name` varchar(100) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`address` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`phone_number` varchar(15) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`email` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`contact_person` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`contact_person_phone` varchar(15) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`coverage_percentage` decimal(5,2) NOT NULL DEFAULT '100.00',
|
||||
`coverage_description` text COLLATE utf8mb4_unicode_ci,
|
||||
`agreement_details` text COLLATE utf8mb4_unicode_ci,
|
||||
`agreement_start_date` date DEFAULT NULL,
|
||||
`agreement_end_date` date DEFAULT NULL,
|
||||
`agreement_file_path` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`is_active` tinyint(1) NOT NULL DEFAULT '1',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `m_insurance`
|
||||
--
|
||||
|
||||
INSERT INTO `m_insurance` (`id`, `code`, `name`, `address`, `phone_number`, `email`, `contact_person`, `contact_person_phone`, `coverage_percentage`, `coverage_description`, `agreement_details`, `agreement_start_date`, `agreement_end_date`, `agreement_file_path`, `is_active`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6b5c6-3c37-4f8a-9e1a-8dd2fa21f695', 'BPJS', 'BPJS Kesehatan', 'Jl. Bougenville No. 5, Kel. Sungai Bangkong, Kec. Pontianak Kota, Kota Pontianak, Kalimantan Barat 78113', '034254789901', 'contact@bpjskesehatan.com', 'Madaline Mack', NULL, 70.00, 'Penyakit Infeksi: Tuberkolosis (TBC), demam berdarah, malaria, dan infeksi saluran pernapasan akut (ISPA).\nPenyakit Kronis: Diabetes, hipertensi, gagal ginjal, jantung, dan asma.\nKanker: Pengobatan kanker, termasuk kemoterapi dan operasi.\nPenyakit Pernapasan: Asma, bronkitis, dan pneumonia.\nPenyakit Jantung: Pengobatan penyakit jantung, termasuk pemasangan ring jantung dan operasi bypass.', NULL, NULL, NULL, NULL, 1, '2025-04-27 07:08:23', '2025-04-27 07:08:23'),
|
||||
('9ec6b69a-e80b-4636-b23a-cd7ff2a0f5e2', 'PRU', 'Prudential', 'Jl. Teratai No. 31, Kel. Abiansemal, Kec. Abiansemal, Kabupaten Badung, Bali 80352', '034289074492', 'contact@prudential.com', 'Samson Church', NULL, 100.00, 'Rawat jalan \nRawat inap', NULL, '2025-02-04', '2025-08-30', NULL, 1, '2025-04-27 07:10:43', '2025-04-27 07:10:43');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `m_patient`
|
||||
--
|
||||
|
||||
CREATE TABLE `m_patient` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`medical_record_number` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`nik` varchar(16) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`name` varchar(100) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`gender` enum('laki-laki','perempuan') COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`birth_date` date NOT NULL,
|
||||
`birth_place` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`address` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`phone_number` varchar(15) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`email` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`blood_type` enum('A','B','AB','O','unknown') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'unknown',
|
||||
`religion` enum('islam','kristen','katolik','hindu','budha','konghucu','other') COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`marital_status` enum('lajang','menikah','cerai','duda/janda') COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`emergency_contact_name` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`emergency_contact_phone` varchar(15) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`emergency_contact_relation` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`is_active` tinyint(1) NOT NULL DEFAULT '1',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `m_patient`
|
||||
--
|
||||
|
||||
INSERT INTO `m_patient` (`id`, `medical_record_number`, `nik`, `name`, `gender`, `birth_date`, `birth_place`, `address`, `phone_number`, `email`, `blood_type`, `religion`, `marital_status`, `emergency_contact_name`, `emergency_contact_phone`, `emergency_contact_relation`, `is_active`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6b98f-4dcb-4b70-a476-36151853af0b', 'MRN-202504-0001', '3605180311000001', 'Tate Merrill', 'laki-laki', '2024-11-12', 'Jakarta', 'Jl. Kamboja No. 12, Kel. Wua-Wua, Kec. Wua-Wua, Kota Kendari, Sulawesi Tenggara 93116', '086834184223', 'tovajo@example.com', 'A', 'hindu', 'cerai', 'Lisandra Nelson', '081232274167', 'Keluarga', 1, '2025-04-27 07:18:58', '2025-04-27 07:18:58'),
|
||||
('9ec6ba08-5e1c-4fbf-88a1-bf6f339b3a94', 'MRN-202504-0002', '3605180311000002', 'Ria Ferguson', 'laki-laki', '2025-04-06', 'Jakarta', 'Jl. Cendana No. 88, Kel. Margorejo, Kec. Wonocolo, Kota Surabaya, Jawa Timur 60238', '088615411262', 'jebefisuve@example.com', 'O', 'budha', 'menikah', 'Gareth Beck', '086557427424', 'Ibu', 1, '2025-04-27 07:20:18', '2025-04-27 07:20:18'),
|
||||
('9ec6ba3a-1613-4be1-b49d-e99b697a0027', 'MRN-202504-0003', '3605180311000003', 'Elizabeth Garrett', 'perempuan', '2025-04-08', 'Bogor', 'Jl. Rambutan No. 21, Kel. Medan Sunggal, Kec. Sunggal, Kota Medan, Sumatera Utara 20127', '082654512716', 'loqypipa@example.com', 'B', 'budha', 'duda/janda', 'Sebastian Williamson', '087641172753', 'Ibu', 1, '2025-04-27 07:20:50', '2025-04-27 07:23:42'),
|
||||
('9ec6ba81-936b-43d6-a37b-f21419ed7286', 'MRN-202504-0004', '3605180311000004', 'Jada Rush', 'laki-laki', '2025-04-09', 'Jakarta', 'Jl. Kemuning No. 77, Kel. Panakkukang, Kec. Panakkukang, Kota Makassar, Sulawesi Selatan 90231', '085469513861', 'tele@example.com', 'O', 'katolik', 'duda/janda', 'Murphy Curry', '088976726263', 'Anak Kandung', 1, '2025-04-27 07:21:37', '2025-04-27 07:21:37'),
|
||||
('9ec6bad2-8aa9-4014-a101-8b56bbc2ea95', 'MRN-202504-0005', '3605180311000005', 'Price Glover', 'laki-laki', '2025-04-08', 'Bandung', 'Jl. Nusa Indah No. 15, Kel. Gayamsari, Kec. Gayamsari, Kota Semarang, Jawa Tengah 50161', '084861647855', 'redo@example.com', 'O', 'kristen', 'menikah', 'Hollee Watkins', '085274827282', 'Istri', 1, '2025-04-27 07:22:30', '2025-04-27 07:22:30'),
|
||||
('9ec6c5e9-4a7f-48c2-8975-167f1c5fec7d', 'MRN-202504-0006', '3605180311000009', 'Helen Gay', 'laki-laki', '1991-12-12', 'Jakarta', 'Jl. Sawo Kecil No. 3, Kel. Penjaringan, Kec. Penjaringan, Kota Jakarta Utara, DKI Jakarta 14440', '0812546788890', 'mamot@example.com', 'A', 'islam', 'lajang', NULL, NULL, NULL, 1, '2025-04-27 07:53:31', '2025-04-27 07:53:31');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `m_procedure`
|
||||
--
|
||||
|
||||
CREATE TABLE `m_procedure` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`code` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Kode prosedur: KON-001, OPR-102, dll',
|
||||
`name` varchar(100) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Nama prosedur: Konsultasi Umum, Operasi Appendiks, dll',
|
||||
`category` enum('Konsultasi','Pemeriksaan','Tindakan','Operasi','Laboratorium','Radiologi','Obat','Lainnya') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'Tindakan' COMMENT 'Kategori prosedur',
|
||||
`description` text COLLATE utf8mb4_unicode_ci COMMENT 'Penjelasan prosedur',
|
||||
`base_price` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Harga dasar',
|
||||
`is_taxable` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'Kena pajak?',
|
||||
`tax_percentage` decimal(5,2) NOT NULL DEFAULT '10.00' COMMENT 'Persentase pajak',
|
||||
`is_discountable` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'Bisa dapat diskon?',
|
||||
`requires_approval` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'Butuh persetujuan?',
|
||||
`is_active` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'Status aktif/tidak',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `m_procedure`
|
||||
--
|
||||
|
||||
INSERT INTO `m_procedure` (`id`, `code`, `name`, `category`, `description`, `base_price`, `is_taxable`, `tax_percentage`, `is_discountable`, `requires_approval`, `is_active`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6b82a-f82c-406e-a183-8a9d2baefc47', 'LAB-001', 'Pemeriksaan Darah Lengkap', 'Laboratorium', 'Uji laboratorium darah', 175000.00, 1, 10.00, 0, 0, 1, '2025-04-27 07:15:05', '2025-04-27 07:15:05'),
|
||||
('9ec6b92b-3c46-4bf0-9130-7788cc677b89', 'LAB-002', 'Pemeriksaan Kadar Asam Urat', 'Laboratorium', 'Pemeriksaan asam urat', 325000.00, 1, 10.00, 0, 0, 1, '2025-04-27 07:17:53', '2025-04-27 07:17:53'),
|
||||
('9ec6c155-fec5-42b5-b29f-677e3f6d30c7', 'OP-001', 'Operasi Kanker Otak', 'Operasi', 'Operasi pengangkatan kanker otak', 25175000.00, 1, 10.00, 0, 0, 1, '2025-04-27 07:40:43', '2025-04-27 07:40:43');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `m_service_room`
|
||||
--
|
||||
|
||||
CREATE TABLE `m_service_room` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`code` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Kode unik ruangan: RJ-101, RI-201, dll',
|
||||
`name` varchar(100) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Nama ruangan: Ruang Bedah 1, Kamar VIP 2, dll',
|
||||
`type` enum('Rawat Jalan','Rawat Inap','UGD','ICU','Bedah','Persalinan','Radiologi','Laboratorium','Farmasi','Lainnya') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'Rawat Inap' COMMENT 'Jenis ruangan',
|
||||
`class` enum('vip','class_1','class_2','class_3','standard','non_class') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'standard' COMMENT 'Kelas ruangan',
|
||||
`floor` varchar(10) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Lantai: 1, 2, 3, dll',
|
||||
`building` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Gedung: A, B, Utama, dll',
|
||||
`wing` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Sayap: Timur, Barat, dll',
|
||||
`capacity` int NOT NULL DEFAULT '1' COMMENT 'Kapasitas pasien',
|
||||
`price_per_day` decimal(12,2) DEFAULT NULL COMMENT 'Harga per hari jika ada',
|
||||
`facilities` text COLLATE utf8mb4_unicode_ci COMMENT 'Fasilitas ruangan (JSON atau text)',
|
||||
`is_available` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'Status ketersediaan',
|
||||
`is_active` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'Status aktif/tidak',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `m_service_room`
|
||||
--
|
||||
|
||||
INSERT INTO `m_service_room` (`id`, `code`, `name`, `type`, `class`, `floor`, `building`, `wing`, `capacity`, `price_per_day`, `facilities`, `is_available`, `is_active`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6b72e-5322-4b99-9e62-569b56633ab1', 'RI-101', 'Rawat Inap Standart', 'Rawat Inap', 'standard', '1', 'Gedung A', 'Utara', 2, 375000.00, 'AC, TV, Kamar Mandi', 1, 1, '2025-04-27 07:12:19', '2025-04-27 07:12:19'),
|
||||
('9ec6b7a9-db60-41bd-b460-2cc9388f4b62', 'RI-102', 'Rawat Inap VIP', 'Rawat Inap', 'vip', '1', 'Gedung A', 'Utara', 1, 1500000.00, 'AC, TV, Kamar Mandi, Sofa, Private', 1, 1, '2025-04-27 07:13:40', '2025-04-27 07:26:37'),
|
||||
('9ec6bc2e-6c31-4c16-9b2d-4f32be9826de', 'RJ-000', 'Tidak Perlu Ruangan (Rawat Jalan)', 'Rawat Jalan', 'non_class', NULL, NULL, NULL, 99, 0.00, NULL, 1, 1, '2025-04-27 07:26:18', '2025-04-27 07:26:24');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `password_reset_tokens`
|
||||
--
|
||||
|
||||
CREATE TABLE `password_reset_tokens` (
|
||||
`email` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`token` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`created_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `sessions`
|
||||
--
|
||||
|
||||
CREATE TABLE `sessions` (
|
||||
`id` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`user_id` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`ip_address` varchar(45) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`user_agent` text COLLATE utf8mb4_unicode_ci,
|
||||
`payload` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`last_activity` int NOT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `sessions`
|
||||
--
|
||||
|
||||
INSERT INTO `sessions` (`id`, `user_id`, `ip_address`, `user_agent`, `payload`, `last_activity`) VALUES
|
||||
('i75eydsrV6tAkzoKliReea1bSFyyjrCEA4jq48Ud', '9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', '127.0.0.1', 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/135.0.0.0 Safari/537.36', 'YTo0OntzOjY6Il90b2tlbiI7czo0MDoiRDMyQmZrMVowMGtKUmQxZVVINEd6VUdlaHY0dzJDVFhPQm9iSU5XUyI7czo5OiJfcHJldmlvdXMiO2E6MTp7czozOiJ1cmwiO3M6MzI6Imh0dHA6Ly9sb2NhbGhvc3Q6ODAwMC9wcm9jZWR1cmVzIjt9czo2OiJfZmxhc2giO2E6Mjp7czozOiJvbGQiO2E6MDp7fXM6MzoibmV3IjthOjA6e319czo1MDoibG9naW5fd2ViXzU5YmEzNmFkZGMyYjJmOTQwMTU4MGYwMTRjN2Y1OGVhNGUzMDk4OWQiO3M6MzY6IjllYzZiMDY0LTlmMzQtNGNhOS04N2I4LTZlZTdlZTY4NTJjYiI7fQ==', 1745765750);
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `t_registration`
|
||||
--
|
||||
|
||||
CREATE TABLE `t_registration` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`registration_number` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Format: RJ-YYYYMMDD-001 (Rawat Jalan), RI-YYYYMMDD-001 (Rawat Inap), UGD-YYYYMMDD-001 (Gawat Darurat)',
|
||||
`patient_id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Referensi ke tabel pasien (m_patient)',
|
||||
`employee_id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Dokter penanggung jawab utama',
|
||||
`service_room_id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Ruangan yang digunakan',
|
||||
`insurance_id` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Asuransi yang digunakan (jika ada)',
|
||||
`created_by` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Petugas yang melakukan pendaftaran',
|
||||
`registration_type` enum('Rawat Jalan','Rawat Inap','UGD') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'Rawat Jalan' COMMENT 'Jenis pendaftaran pasien',
|
||||
`patient_type` enum('Umum','BPJS','Asuransi','Perusahaan','Gratis') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'Umum' COMMENT 'Kategori pasien berdasarkan pembiayaan',
|
||||
`registration_datetime` datetime NOT NULL COMMENT 'Waktu pendaftaran pasien',
|
||||
`discharge_datetime` datetime DEFAULT NULL COMMENT 'Waktu pasien keluar/pulang',
|
||||
`estimated_discharge` datetime DEFAULT NULL COMMENT 'Perkiraan waktu pulang (untuk rawat inap)',
|
||||
`diagnoses` json DEFAULT NULL COMMENT 'Diagnosa pasien dalam format JSON',
|
||||
`prescriptions` json DEFAULT NULL COMMENT 'Resep obat dalam format JSON',
|
||||
`medical_notes` text COLLATE utf8mb4_unicode_ci COMMENT 'Catatan medis tambahan',
|
||||
`complaint` text COLLATE utf8mb4_unicode_ci COMMENT 'Keluhan utama pasien',
|
||||
`status` enum('registered','in_progress','completed','cancelled') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'registered' COMMENT 'Status proses pendaftaran',
|
||||
`payment_status` enum('unpaid','partial','paid','insurance_cover') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'unpaid' COMMENT 'Status pembayaran',
|
||||
`need_icu` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'Butuh perawatan ICU',
|
||||
`is_referral` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'Pasien rujukan',
|
||||
`referral_from` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Asal rujukan',
|
||||
`is_active` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'Status aktif/tidak aktif',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `t_registration`
|
||||
--
|
||||
|
||||
INSERT INTO `t_registration` (`id`, `registration_number`, `patient_id`, `employee_id`, `service_room_id`, `insurance_id`, `created_by`, `registration_type`, `patient_type`, `registration_datetime`, `discharge_datetime`, `estimated_discharge`, `diagnoses`, `prescriptions`, `medical_notes`, `complaint`, `status`, `payment_status`, `need_icu`, `is_referral`, `referral_from`, `is_active`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6bbc9-c79a-489c-8ebb-0aa3691fe3ed', 'RI-20250427-001', '9ec6b98f-4dcb-4b70-a476-36151853af0b', '9ec6b1d5-f08e-4c6f-9979-f199bfd19e01', '9ec6bc2e-6c31-4c16-9b2d-4f32be9826de', '9ec6b5c6-3c37-4f8a-9e1a-8dd2fa21f695', '9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', 'Rawat Jalan', 'BPJS', '2025-04-27 14:24:00', NULL, '2025-04-27 21:24:00', '[]', '[]', NULL, 'Pusing, Mual, Sakit Kepala', 'registered', 'paid', 0, 0, NULL, 1, '2025-04-27 07:25:12', '2025-04-27 07:44:37'),
|
||||
('9ec6bed6-d988-4bf7-b5ee-60a8a1c3bf9f', 'RI-20250427-003', '9ec6ba08-5e1c-4fbf-88a1-bf6f339b3a94', '9ec6b3ff-9145-421d-9297-5d82c668d9cd', '9ec6b7a9-db60-41bd-b460-2cc9388f4b62', '9ec6b69a-e80b-4636-b23a-cd7ff2a0f5e2', '9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', 'Rawat Inap', 'Perusahaan', '2025-02-19 06:40:00', NULL, '2025-04-30 22:25:00', NULL, NULL, NULL, 'Sakit Kepala', 'registered', 'unpaid', 0, 0, NULL, 1, '2025-04-27 07:33:44', '2025-04-27 07:33:44'),
|
||||
('9ec6c0eb-9d6b-4115-9f6f-e3912d708d12', 'RI-20250427-004', '9ec6ba3a-1613-4be1-b49d-e99b697a0027', '9ec6b1d5-f08e-4c6f-9979-f199bfd19e01', '9ec6b72e-5322-4b99-9e62-569b56633ab1', '9ec6b69a-e80b-4636-b23a-cd7ff2a0f5e2', '9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', 'Rawat Inap', 'Asuransi', '2025-04-27 14:38:37', NULL, '2025-05-01 21:39:00', NULL, NULL, NULL, 'Sakit', 'registered', 'unpaid', 0, 0, NULL, 1, '2025-04-27 07:39:33', '2025-04-27 07:39:33');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `t_transaction`
|
||||
--
|
||||
|
||||
CREATE TABLE `t_transaction` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`invoice_number` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Format: INV-YYYYMMDD-001',
|
||||
`registration_id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Referensi ke t_registration',
|
||||
`patient_id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Referensi ke m_patient',
|
||||
`insurance_id` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Referensi ke m_insurance',
|
||||
`cashier_id` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Petugas kasir yang memproses',
|
||||
`transaction_datetime` datetime NOT NULL COMMENT 'Waktu transaksi dibuat',
|
||||
`payment_datetime` datetime DEFAULT NULL COMMENT 'Waktu pembayaran',
|
||||
`due_date` date DEFAULT NULL COMMENT 'Jatuh tempo pembayaran',
|
||||
`subtotal` decimal(12,2) NOT NULL COMMENT 'Total sebelum pajak & diskon',
|
||||
`tax_amount` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Total pajak',
|
||||
`discount_amount` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Total diskon',
|
||||
`discount_reason` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Alasan diskon',
|
||||
`grand_total` decimal(12,2) NOT NULL COMMENT 'Total yang harus dibayar',
|
||||
`paid_amount` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Jumlah yang sudah dibayar',
|
||||
`change_amount` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Kembalian',
|
||||
`insurance_covered_amount` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Ditanggung asuransi',
|
||||
`patient_responsibility` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Tanggungan pasien',
|
||||
`payment_method` enum('cash','debit_card','credit_card','transfer','insurance','other') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'cash' COMMENT 'Metode pembayaran',
|
||||
`payment_reference` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'No. referensi pembayaran',
|
||||
`status` enum('pending','paid','partially_paid','cancelled','refunded') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'pending' COMMENT 'Status transaksi',
|
||||
`notes` text COLLATE utf8mb4_unicode_ci COMMENT 'Catatan tambahan',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `t_transaction`
|
||||
--
|
||||
|
||||
INSERT INTO `t_transaction` (`id`, `invoice_number`, `registration_id`, `patient_id`, `insurance_id`, `cashier_id`, `transaction_datetime`, `payment_datetime`, `due_date`, `subtotal`, `tax_amount`, `discount_amount`, `discount_reason`, `grand_total`, `paid_amount`, `change_amount`, `insurance_covered_amount`, `patient_responsibility`, `payment_method`, `payment_reference`, `status`, `notes`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6bd51-30c8-4bed-82f7-5b98648e1532', 'INV-20250427-001', '9ec6bbc9-c79a-489c-8ebb-0aa3691fe3ed', '9ec6b98f-4dcb-4b70-a476-36151853af0b', NULL, '9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', '2025-04-27 21:27:00', '2025-04-27 21:44:00', NULL, 175000.00, 17500.00, 0.00, NULL, 192500.00, 175000.00, 0.00, 0.00, 192500.00, 'cash', NULL, 'paid', NULL, '2025-04-27 07:29:29', '2025-04-27 07:44:37'),
|
||||
('9ec6c18b-ef78-4db3-9caf-d59394e3b085', 'INV-20250427-002', '9ec6bed6-d988-4bf7-b5ee-60a8a1c3bf9f', '9ec6ba08-5e1c-4fbf-88a1-bf6f339b3a94', NULL, '9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', '2025-04-27 21:40:00', NULL, NULL, 25175000.00, 2517500.00, 0.00, NULL, 25175000.00, 175000.00, 0.00, 0.00, 25175000.00, 'debit_card', NULL, 'pending', NULL, '2025-04-27 07:41:18', '2025-04-27 07:41:18'),
|
||||
('9ec6c2a6-d346-450c-bec3-ba979c7ba54b', 'INV-20250427-003', '9ec6c0eb-9d6b-4115-9f6f-e3912d708d12', '9ec6ba3a-1613-4be1-b49d-e99b697a0027', NULL, '9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', '2025-04-27 21:43:00', NULL, NULL, 325000.00, 32500.00, 0.00, NULL, 325000.00, 325000.00, 0.00, 0.00, 325000.00, 'cash', NULL, 'pending', NULL, '2025-04-27 07:44:24', '2025-04-27 07:44:24');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `t_transaction_detail`
|
||||
--
|
||||
|
||||
CREATE TABLE `t_transaction_detail` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`transaction_id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Referensi ke t_transaction',
|
||||
`procedure_id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Referensi ke m_procedure',
|
||||
`performed_by` char(36) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'Dokter/perawat yang melakukan tindakan',
|
||||
`procedure_code` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Kode prosedur',
|
||||
`procedure_name` varchar(100) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'Nama prosedur',
|
||||
`quantity` int NOT NULL DEFAULT '1' COMMENT 'Jumlah',
|
||||
`unit_price` decimal(12,2) NOT NULL COMMENT 'Harga satuan',
|
||||
`discount_amount` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Diskon per item',
|
||||
`tax_amount` decimal(12,2) NOT NULL DEFAULT '0.00' COMMENT 'Pajak per item',
|
||||
`subtotal` decimal(12,2) NOT NULL COMMENT 'Total per item',
|
||||
`performed_datetime` datetime DEFAULT NULL COMMENT 'Waktu tindakan dilakukan',
|
||||
`notes` text COLLATE utf8mb4_unicode_ci COMMENT 'Catatan prosedur',
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `t_transaction_detail`
|
||||
--
|
||||
|
||||
INSERT INTO `t_transaction_detail` (`id`, `transaction_id`, `procedure_id`, `performed_by`, `procedure_code`, `procedure_name`, `quantity`, `unit_price`, `discount_amount`, `tax_amount`, `subtotal`, `performed_datetime`, `notes`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6bd51-3155-485e-a88b-c5209f1bbcab', '9ec6bd51-30c8-4bed-82f7-5b98648e1532', '9ec6b82a-f82c-406e-a183-8a9d2baefc47', '9ec6b1d5-f08e-4c6f-9979-f199bfd19e01', 'LAB-001', 'Pemeriksaan Darah Lengkap', 1, 175000.00, 0.00, 17500.00, 175000.00, NULL, NULL, '2025-04-27 07:29:29', '2025-04-27 07:31:30'),
|
||||
('9ec6c18b-efe5-4d79-a2f0-f93d0c62aee6', '9ec6c18b-ef78-4db3-9caf-d59394e3b085', '9ec6c155-fec5-42b5-b29f-677e3f6d30c7', '9ec6b354-aee9-4325-baf2-f4cc1f47091a', 'OP-001', 'Operasi Kanker Otak', 1, 25175000.00, 0.00, 2517500.00, 25175000.00, NULL, NULL, '2025-04-27 07:41:18', '2025-04-27 07:41:18'),
|
||||
('9ec6c2a6-d40a-41cc-9b79-cd3a33ca603b', '9ec6c2a6-d346-450c-bec3-ba979c7ba54b', '9ec6b92b-3c46-4bf0-9130-7788cc677b89', '9ec6b3ff-9145-421d-9297-5d82c668d9cd', 'LAB-002', 'Pemeriksaan Kadar Asam Urat', 1, 325000.00, 0.00, 32500.00, 325000.00, NULL, NULL, '2025-04-27 07:44:24', '2025-04-27 07:44:24');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `users`
|
||||
--
|
||||
|
||||
CREATE TABLE `users` (
|
||||
`id` char(36) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`email` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`email_verified_at` timestamp NULL DEFAULT NULL,
|
||||
`password` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`remember_token` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
`updated_at` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
--
|
||||
-- Dumping data for table `users`
|
||||
--
|
||||
|
||||
INSERT INTO `users` (`id`, `name`, `email`, `email_verified_at`, `password`, `remember_token`, `created_at`, `updated_at`) VALUES
|
||||
('9ec6b064-9f34-4ca9-87b8-6ee7ee6852cb', 'John Doe', 'test@example.com', '2025-04-27 06:53:20', '$2y$12$LQqRAKANJ3g/oMBFdiKuw.yVvIqoXN9iBjJ3sJv4WEcohcE1JLd1S', 'l0zHAqObED', '2025-04-27 06:53:20', '2025-04-27 07:32:28'),
|
||||
('9ec6b1d5-f028-4a69-ab83-e76f4261a6a0', 'Pascale Shaffer', 'rukoserixu@example.com', NULL, '$2y$12$sXS5uxKcLD5u1uzLvW5rkOdRoypbRAdnthVINu3WqhZRKWK5xfhqW', NULL, '2025-04-27 06:57:23', '2025-04-27 06:57:23'),
|
||||
('9ec6b298-7768-4030-bab1-0cd1e4d0cc5d', 'Leigh Suarez', 'lemekuje@example.com', NULL, '$2y$12$UC77QMXsBWOy0KY/3MTM6.epkxtQAOX/HFOt0JGK9Oi89jwvRYIZW', NULL, '2025-04-27 06:59:30', '2025-04-27 06:59:30'),
|
||||
('9ec6b2fa-2324-439f-8e72-3fc12bfda819', 'Amena Hood', 'butul@example.com', NULL, '$2y$12$WollOpKWOh99DrVrjPg5TehTJ6wP/WQiOwrgPXZ3RfqNVKPU7s3DC', NULL, '2025-04-27 07:00:34', '2025-04-27 07:00:34'),
|
||||
('9ec6b354-ae57-4858-98b3-413bdcd4edae', 'Courtney Schultz', 'qerimex@example.com', NULL, '$2y$12$nxQnCOTYEIKd0x1T6R08quGR75OsH0clcLIXuA1NLedsFhapKByCu', NULL, '2025-04-27 07:01:33', '2025-04-27 07:01:33'),
|
||||
('9ec6b39b-476d-4287-9af7-00081b5d7a28', 'Liberty Mccarthy', 'xawicely@example.com', NULL, '$2y$12$eGAg7Cne94S4XdAUzP5/9OgeKQvMPQz5Le4TAOGirkdwH43TGcXZ.', NULL, '2025-04-27 07:02:20', '2025-04-27 07:02:20'),
|
||||
('9ec6b3ff-90a1-4cba-8da8-8b966de062a6', 'Allegra Burke', 'jyjuk@example.com', NULL, '$2y$12$aWIly1KoLxLxsDp9eGNoDuFRIiiraZ201xh2k4Mjo4eQ9PLBG536K', NULL, '2025-04-27 07:03:25', '2025-04-27 07:03:25'),
|
||||
('9ec6b446-92c6-4aa9-b528-456b300992a7', 'Suki Pace', 'jynutijuw@example.com', NULL, '$2y$12$9Ll18UtbFbvvE8JXgb72huAGs68GcyCSTjUNVj5oC0OFdspb3vORq', NULL, '2025-04-27 07:04:12', '2025-04-27 07:04:12'),
|
||||
('9ec6b49a-4861-430b-b842-249039e819c2', 'Levi Knowles', 'rijuw@example.com', NULL, '$2y$12$MTYB69rTX68R6s7PT7rfVuHNI4aCqhyKzmyjvo6kkQoBlHACuN9bK', NULL, '2025-04-27 07:05:07', '2025-04-27 07:05:07'),
|
||||
('9ec6c69f-88c6-43f8-ba4e-4531a926eb76', 'Marny Bennett', 'fuxijagax@example.com', NULL, '$2y$12$UPNU6O23k1LQyQEp5cOgX.Dk0oHuB996JKqwTT15ienSZUqPwEu/y', NULL, '2025-04-27 07:55:30', '2025-04-27 07:55:30');
|
||||
|
||||
--
|
||||
-- Indexes for dumped tables
|
||||
--
|
||||
|
||||
--
|
||||
-- Indexes for table `cache`
|
||||
--
|
||||
ALTER TABLE `cache`
|
||||
ADD PRIMARY KEY (`key`);
|
||||
|
||||
--
|
||||
-- Indexes for table `cache_locks`
|
||||
--
|
||||
ALTER TABLE `cache_locks`
|
||||
ADD PRIMARY KEY (`key`);
|
||||
|
||||
--
|
||||
-- Indexes for table `failed_jobs`
|
||||
--
|
||||
ALTER TABLE `failed_jobs`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `failed_jobs_uuid_unique` (`uuid`);
|
||||
|
||||
--
|
||||
-- Indexes for table `jobs`
|
||||
--
|
||||
ALTER TABLE `jobs`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD KEY `jobs_queue_index` (`queue`);
|
||||
|
||||
--
|
||||
-- Indexes for table `job_batches`
|
||||
--
|
||||
ALTER TABLE `job_batches`
|
||||
ADD PRIMARY KEY (`id`);
|
||||
|
||||
--
|
||||
-- Indexes for table `migrations`
|
||||
--
|
||||
ALTER TABLE `migrations`
|
||||
ADD PRIMARY KEY (`id`);
|
||||
|
||||
--
|
||||
-- Indexes for table `m_employee`
|
||||
--
|
||||
ALTER TABLE `m_employee`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `m_employee_employee_id_unique` (`employee_id`),
|
||||
ADD KEY `m_employee_nik_index` (`nik`);
|
||||
|
||||
--
|
||||
-- Indexes for table `m_insurance`
|
||||
--
|
||||
ALTER TABLE `m_insurance`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `m_insurance_code_unique` (`code`);
|
||||
|
||||
--
|
||||
-- Indexes for table `m_patient`
|
||||
--
|
||||
ALTER TABLE `m_patient`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `m_patient_medical_record_number_unique` (`medical_record_number`),
|
||||
ADD KEY `m_patient_nik_index` (`nik`);
|
||||
|
||||
--
|
||||
-- Indexes for table `m_procedure`
|
||||
--
|
||||
ALTER TABLE `m_procedure`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `m_procedure_code_unique` (`code`);
|
||||
|
||||
--
|
||||
-- Indexes for table `m_service_room`
|
||||
--
|
||||
ALTER TABLE `m_service_room`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `m_service_room_code_unique` (`code`);
|
||||
|
||||
--
|
||||
-- Indexes for table `password_reset_tokens`
|
||||
--
|
||||
ALTER TABLE `password_reset_tokens`
|
||||
ADD PRIMARY KEY (`email`);
|
||||
|
||||
--
|
||||
-- Indexes for table `sessions`
|
||||
--
|
||||
ALTER TABLE `sessions`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD KEY `sessions_user_id_index` (`user_id`),
|
||||
ADD KEY `sessions_last_activity_index` (`last_activity`);
|
||||
|
||||
--
|
||||
-- Indexes for table `t_registration`
|
||||
--
|
||||
ALTER TABLE `t_registration`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `t_registration_registration_number_unique` (`registration_number`),
|
||||
ADD KEY `t_registration_patient_id_index` (`patient_id`),
|
||||
ADD KEY `t_registration_employee_id_index` (`employee_id`),
|
||||
ADD KEY `t_registration_service_room_id_index` (`service_room_id`),
|
||||
ADD KEY `t_registration_insurance_id_index` (`insurance_id`),
|
||||
ADD KEY `t_registration_created_by_index` (`created_by`);
|
||||
|
||||
--
|
||||
-- Indexes for table `t_transaction`
|
||||
--
|
||||
ALTER TABLE `t_transaction`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `t_transaction_invoice_number_unique` (`invoice_number`),
|
||||
ADD KEY `t_transaction_registration_id_index` (`registration_id`),
|
||||
ADD KEY `t_transaction_patient_id_index` (`patient_id`),
|
||||
ADD KEY `t_transaction_insurance_id_index` (`insurance_id`),
|
||||
ADD KEY `t_transaction_cashier_id_index` (`cashier_id`);
|
||||
|
||||
--
|
||||
-- Indexes for table `t_transaction_detail`
|
||||
--
|
||||
ALTER TABLE `t_transaction_detail`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD KEY `t_transaction_detail_transaction_id_index` (`transaction_id`),
|
||||
ADD KEY `t_transaction_detail_procedure_id_index` (`procedure_id`),
|
||||
ADD KEY `t_transaction_detail_performed_by_index` (`performed_by`);
|
||||
|
||||
--
|
||||
-- Indexes for table `users`
|
||||
--
|
||||
ALTER TABLE `users`
|
||||
ADD PRIMARY KEY (`id`),
|
||||
ADD UNIQUE KEY `users_email_unique` (`email`);
|
||||
|
||||
--
|
||||
-- AUTO_INCREMENT for dumped tables
|
||||
--
|
||||
|
||||
--
|
||||
-- AUTO_INCREMENT for table `failed_jobs`
|
||||
--
|
||||
ALTER TABLE `failed_jobs`
|
||||
MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT;
|
||||
|
||||
--
|
||||
-- AUTO_INCREMENT for table `jobs`
|
||||
--
|
||||
ALTER TABLE `jobs`
|
||||
MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT;
|
||||
|
||||
--
|
||||
-- AUTO_INCREMENT for table `migrations`
|
||||
--
|
||||
ALTER TABLE `migrations`
|
||||
MODIFY `id` int UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=12;
|
||||
COMMIT;
|
||||
|
||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
||||
Loading…
x
Reference in New Issue
Block a user