text: -- phpMyAdmin SQL Dump
  -- version 5.0.2
  -- https://www.phpmyadmin.net/
  --
  -- Host: 127.0.0.1
  -- Generation Time: Mar 30, 2021 at 04:39 AM
  -- Server version: 10.4.14-MariaDB
  -- PHP Version: 7.4.9
  
  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: `e-laundry`
  --
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `detail_transaksi`
  --
  
  CREATE TABLE `detail_transaksi` (
    `id_detail` int(11) NOT NULL,
    `id_transaksi` int(11) NOT NULL,
    `id_paket` int(11) NOT NULL,
    `qty` double NOT NULL,
    `keterangan` text NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `konfigurasi`
  --
  
  CREATE TABLE `konfigurasi` (
    `id_konfigurasi` int(11) NOT NULL,
    `namaweb` varchar(255) NOT NULL,
    `tagline` varchar(255) DEFAULT NULL,
    `email` varchar(255) DEFAULT NULL,
    `website` varchar(255) DEFAULT NULL,
    `keywords` text DEFAULT NULL,
    `metatext` text DEFAULT NULL,
    `telepon` varchar(50) DEFAULT NULL,
    `alamat` varchar(300) DEFAULT NULL,
    `facebook` varchar(255) DEFAULT NULL,
    `instagram` varchar(255) DEFAULT NULL,
    `deskripsi` text DEFAULT NULL,
    `logo` varchar(255) DEFAULT NULL,
    `icon` varchar(255) DEFAULT NULL,
    `rekening_pembayaran` varchar(255) DEFAULT NULL,
    `tanggal_update` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp()
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `konfigurasi`
  --
  
  INSERT INTO `konfigurasi` (`id_konfigurasi`, `namaweb`, `tagline`, `email`, `website`, `keywords`, `metatext`, `telepon`, `alamat`, `facebook`, `instagram`, `deskripsi`, `logo`, `icon`, `rekening_pembayaran`, `tanggal_update`) VALUES
  (1, 'E-LAUNDRY', 'Easy Payment', 'admin@gmail.com', 'www.E-LAUNDRY.com', 'E-LAUNDRY Easy Payment ', 'E-LAUNDRY Easy Payment ', '08967623627', 'Depok    ', 'elaundry', 'elaundry', 'Easy Payment', 'fg2h.png', 'fg2h1.png', '89284928', '2021-03-05 08:38:55');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `kontak`
  --
  
  CREATE TABLE `kontak` (
    `id_kontak` int(11) NOT NULL,
    `name` varchar(50) DEFAULT NULL,
    `no_tlp` varchar(13) DEFAULT NULL,
    `message` varchar(50) DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Dumping data for table `kontak`
  --
  
  INSERT INTO `kontak` (`id_kontak`, `name`, `no_tlp`, `message`) VALUES
  (26, 'rosiyana', '085711981633', 'test');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `outlet`
  --
  
  CREATE TABLE `outlet` (
    `id_outlet` int(11) NOT NULL,
    `nama_outlet` varchar(33) NOT NULL,
    `alamat` text NOT NULL,
    `telp` varchar(13) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Dumping data for table `outlet`
  --
  
  INSERT INTO `outlet` (`id_outlet`, `nama_outlet`, `alamat`, `telp`) VALUES
  (2, 'laundry cabang 1', 'Jl. Bukit Cengkih ', '0831739168619'),
  (4, 'Laundry cabang 2', 'Jl. Bukit Cengkih No.23', '62193271623'),
  (5, 'Laundry cabang 22', 'depok', '97896587');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `paket`
  --
  
  CREATE TABLE `paket` (
    `id_paket` int(11) NOT NULL,
    `id_outlet` int(11) NOT NULL,
    `jenis_paket` varchar(50) NOT NULL,
    `nama_paket` varchar(50) NOT NULL,
    `harga` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Dumping data for table `paket`
  --
  
  INSERT INTO `paket` (`id_paket`, `id_outlet`, `jenis_paket`, `nama_paket`, `harga`) VALUES
  (8, 2, 'Paket B (1 lusin)', 'baju', 50000);
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `pelanggan`
  --
  
  CREATE TABLE `pelanggan` (
    `id_pelanggan` int(11) NOT NULL,
    `nama_pelanggan` varchar(30) NOT NULL,
    `email` varchar(32) NOT NULL,
    `password` varchar(64) NOT NULL,
    `telepon` varchar(15) DEFAULT NULL,
    `alamat` varchar(200) DEFAULT NULL,
    `level` varchar(20) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Dumping data for table `pelanggan`
  --
  
  INSERT INTO `pelanggan` (`id_pelanggan`, `nama_pelanggan`, `email`, `password`, `telepon`, `alamat`, `level`) VALUES
  (2, 'rosiyana', 'rosiyana949@gmail.com', 'b0399d2029f64d445bd131ffaa399a42d2f8e7dc', '02739740264', 'depok', 'pelanggan'),
  (3, 'anatasya', 'anatasya@gmail.com', '57aa9c3185504bff86e88dd69f70e6a9b9094c06', '0858173710483', 'depok', 'pelanggan'),
  (4, 'robiatul ', 'robiatul@gmail.com', 'b1b3773a05c0ed0176787a4f1574ff0075f7521e', '0917328153', 'depok', 'pelanggan');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `petugas`
  --
  
  CREATE TABLE `petugas` (
    `id_petugas` int(11) NOT NULL,
    `nama_petugas` varchar(50) DEFAULT NULL,
    `username` varchar(32) DEFAULT NULL,
    `password` varchar(64) NOT NULL,
    `level` varchar(20) DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `petugas`
  --
  
  INSERT INTO `petugas` (`id_petugas`, `nama_petugas`, `username`, `password`, `level`) VALUES
  (2, 'tasya', 'petugas', 'b1b3773a05c0ed0176787a4f1574ff0075f7521e', 'Petugas'),
  (8, 'Sefviana', 'admin33', 'b1b3773a05c0ed0176787a4f1574ff0075f7521e', 'Admin'),
  (9, 'ananda', 'owner', 'b1b3773a05c0ed0176787a4f1574ff0075f7521e', 'Owner');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `transaksi`
  --
  
  CREATE TABLE `transaksi` (
    `id_transaksi` int(11) NOT NULL,
    `id_outlet` int(11) NOT NULL,
    `id_paket` int(11) NOT NULL,
    `kode_transaksi` varchar(100) DEFAULT NULL,
    `jumlah` varchar(30) DEFAULT NULL,
    `status_bayar` enum('Sudah','Belum') DEFAULT NULL,
    `id_pelanggan` int(11) DEFAULT NULL,
    `tanggal_transaksi` date NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Indexes for dumped tables
  --
  
  --
  -- Indexes for table `detail_transaksi`
  --
  ALTER TABLE `detail_transaksi`
    ADD PRIMARY KEY (`id_detail`),
    ADD KEY `id_transaksi` (`id_transaksi`),
    ADD KEY `id_paket` (`id_paket`);
  
  --
  -- Indexes for table `konfigurasi`
  --
  ALTER TABLE `konfigurasi`
    ADD PRIMARY KEY (`id_konfigurasi`);
  
  --
  -- Indexes for table `kontak`
  --
  ALTER TABLE `kontak`
    ADD PRIMARY KEY (`id_kontak`);
  
  --
  -- Indexes for table `outlet`
  --
  ALTER TABLE `outlet`
    ADD PRIMARY KEY (`id_outlet`);
  
  --
  -- Indexes for table `paket`
  --
  ALTER TABLE `paket`
    ADD PRIMARY KEY (`id_paket`),
    ADD KEY `id_outlet` (`id_outlet`);
  
  --
  -- Indexes for table `pelanggan`
  --
  ALTER TABLE `pelanggan`
    ADD PRIMARY KEY (`id_pelanggan`),
    ADD UNIQUE KEY `email` (`email`);
  
  --
  -- Indexes for table `petugas`
  --
  ALTER TABLE `petugas`
    ADD PRIMARY KEY (`id_petugas`),
    ADD UNIQUE KEY `username` (`username`);
  
  --
  -- Indexes for table `transaksi`
  --
  ALTER TABLE `transaksi`
    ADD PRIMARY KEY (`id_transaksi`),
    ADD KEY `id_outlet` (`id_outlet`),
    ADD KEY `id_pelanggan` (`id_pelanggan`),
    ADD KEY `id_paket` (`id_paket`);
  
  --
  -- AUTO_INCREMENT for dumped tables
  --
  
  --
  -- AUTO_INCREMENT for table `detail_transaksi`
  --
  ALTER TABLE `detail_transaksi`
    MODIFY `id_detail` int(11) NOT NULL AUTO_INCREMENT;
  
  --
  -- AUTO_INCREMENT for table `kontak`
  --
  ALTER TABLE `kontak`
    MODIFY `id_kontak` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=31;
  
  --
  -- AUTO_INCREMENT for table `outlet`
  --
  ALTER TABLE `outlet`
    MODIFY `id_outlet` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7;
  
  --
  -- AUTO_INCREMENT for table `paket`
  --
  ALTER TABLE `paket`
    MODIFY `id_paket` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=9;
  
  --
  -- AUTO_INCREMENT for table `pelanggan`
  --
  ALTER TABLE `pelanggan`
    MODIFY `id_pelanggan` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;
  
  --
  -- AUTO_INCREMENT for table `petugas`
  --
  ALTER TABLE `petugas`
    MODIFY `id_petugas` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;
  
  --
  -- AUTO_INCREMENT for table `transaksi`
  --
  ALTER TABLE `transaksi`
    MODIFY `id_transaksi` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
  
  --
  -- Constraints for dumped tables
  --
  
  --
  -- Constraints for table `detail_transaksi`
  --
  ALTER TABLE `detail_transaksi`
    ADD CONSTRAINT `detail_transaksi_ibfk_1` FOREIGN KEY (`id_transaksi`) REFERENCES `transaksi` (`id_transaksi`),
    ADD CONSTRAINT `detail_transaksi_ibfk_2` FOREIGN KEY (`id_paket`) REFERENCES `paket` (`id_paket`);
  
  --
  -- Constraints for table `paket`
  --
  ALTER TABLE `paket`
    ADD CONSTRAINT `paket_ibfk_1` FOREIGN KEY (`id_outlet`) REFERENCES `outlet` (`id_outlet`);
  
  --
  -- Constraints for table `transaksi`
  --
  ALTER TABLE `transaksi`
    ADD CONSTRAINT `transaksi_ibfk_1` FOREIGN KEY (`id_outlet`) REFERENCES `outlet` (`id_outlet`),
    ADD CONSTRAINT `transaksi_ibfk_2` FOREIGN KEY (`id_pelanggan`) REFERENCES `pelanggan` (`id_pelanggan`),
    ADD CONSTRAINT `transaksi_ibfk_3` FOREIGN KEY (`id_paket`) REFERENCES `paket` (`id_paket`);
  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 */;
  