text: -- phpMyAdmin SQL Dump
  -- version 5.0.1
  -- https://www.phpmyadmin.net/
  --
  -- Host: localhost
  -- Generation Time: Jun 03, 2021 at 03:19 PM
  -- Server version: 10.4.11-MariaDB
  -- PHP Version: 7.4.1
  
  SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
  SET AUTOCOMMIT = 0;
  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: `msicourse`
  --
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `kurikulum`
  --
  
  CREATE TABLE `kurikulum` (
    `id_kurikulum` int(11) NOT NULL,
    `id_mp` int(11) NOT NULL,
    `materi` varchar(255) NOT NULL,
    `url_video` text NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `mata_pelajaran`
  --
  
  CREATE TABLE `mata_pelajaran` (
    `id_mp` int(11) NOT NULL,
    `nm_pelajaran` varchar(255) NOT NULL,
    `id_pengguna` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Dumping data for table `mata_pelajaran`
  --
  
  INSERT INTO `mata_pelajaran` (`id_mp`, `nm_pelajaran`, `id_pengguna`) VALUES
  (1, 'BIologi', 3),
  (2, 'Kimia Kuantum', 2),
  (4, 'PHP', 2);
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `mp_transaksi`
  --
  
  CREATE TABLE `mp_transaksi` (
    `id_transaksi` int(11) NOT NULL,
    `judul` varchar(255) NOT NULL,
    `keterangan` text NOT NULL,
    `id_pengguna` int(11) NOT NULL,
    `id_guru` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `pemesanan`
  --
  
  CREATE TABLE `pemesanan` (
    `id_pemesanan` int(11) NOT NULL,
    `id_produk` int(11) NOT NULL,
    `judul` int(11) NOT NULL,
    `keterangan` text NOT NULL,
    `harga` int(11) NOT NULL,
    `id_pengguna` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `pengguna`
  --
  
  CREATE TABLE `pengguna` (
    `id_pengguna` int(10) NOT NULL,
    `nama` varchar(255) NOT NULL,
    `email` varchar(255) NOT NULL,
    `password` varchar(255) NOT NULL,
    `status` enum('admin','pengajar','siswa') NOT NULL DEFAULT 'siswa'
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Dumping data for table `pengguna`
  --
  
  INSERT INTO `pengguna` (`id_pengguna`, `nama`, `email`, `password`, `status`) VALUES
  (1, 'Rifqi', 'muhammad45rifki@gmail.com', '827ccb0eea8a706c4c34a16891f84e7b', 'admin'),
  (2, 'Tommy', 'tommy@gmail.com', '827ccb0eea8a706c4c34a16891f84e7b', 'pengajar'),
  (3, 'Murphy', 'murphy@gmail.com', '827ccb0eea8a706c4c34a16891f84e7b', 'pengajar');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `produk`
  --
  
  CREATE TABLE `produk` (
    `id_produk` int(11) NOT NULL,
    `judul` varchar(255) NOT NULL,
    `keterangan` text NOT NULL,
    `harga` int(11) NOT NULL,
    `foto` varchar(255) NOT NULL,
    `id_pengguna` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Dumping data for table `produk`
  --
  
  INSERT INTO `produk` (`id_produk`, `judul`, `keterangan`, `harga`, `foto`, `id_pengguna`) VALUES
  (1, 'Kegiatan Baznas', 'Dalam Program Payakumbuh Sehat BAZNAS Kota Payakumbuh', 1000000, 'http://localhost/msicourses/asset/upload/produk/104740724_353043129013063_304803123460809531_n.jpg', 2),
  (2, 'Kegiatan Baznas', 'Dalam Program Payakumbuh Sehat BAZNAS Kota Payakumbuh', 300000, 'http://localhost/msicourses/asset/upload/produk/20200726_144315_0000.png', 3);
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `sementara`
  --
  
  CREATE TABLE `sementara` (
    `id_temporary` int(11) NOT NULL,
    `id_produk` int(11) NOT NULL,
    `judul` varchar(255) NOT NULL,
    `keterangan` text NOT NULL,
    `harga` int(11) NOT NULL,
    `id_pengguna` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  
  --
  -- Indexes for dumped tables
  --
  
  --
  -- Indexes for table `kurikulum`
  --
  ALTER TABLE `kurikulum`
    ADD PRIMARY KEY (`id_kurikulum`);
  
  --
  -- Indexes for table `mata_pelajaran`
  --
  ALTER TABLE `mata_pelajaran`
    ADD PRIMARY KEY (`id_mp`);
  
  --
  -- Indexes for table `mp_transaksi`
  --
  ALTER TABLE `mp_transaksi`
    ADD PRIMARY KEY (`id_transaksi`);
  
  --
  -- Indexes for table `pemesanan`
  --
  ALTER TABLE `pemesanan`
    ADD PRIMARY KEY (`id_pemesanan`);
  
  --
  -- Indexes for table `pengguna`
  --
  ALTER TABLE `pengguna`
    ADD PRIMARY KEY (`id_pengguna`);
  
  --
  -- Indexes for table `produk`
  --
  ALTER TABLE `produk`
    ADD PRIMARY KEY (`id_produk`);
  
  --
  -- Indexes for table `sementara`
  --
  ALTER TABLE `sementara`
    ADD PRIMARY KEY (`id_temporary`);
  
  --
  -- AUTO_INCREMENT for dumped tables
  --
  
  --
  -- AUTO_INCREMENT for table `kurikulum`
  --
  ALTER TABLE `kurikulum`
    MODIFY `id_kurikulum` int(11) NOT NULL AUTO_INCREMENT;
  
  --
  -- AUTO_INCREMENT for table `mata_pelajaran`
  --
  ALTER TABLE `mata_pelajaran`
    MODIFY `id_mp` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;
  
  --
  -- AUTO_INCREMENT for table `mp_transaksi`
  --
  ALTER TABLE `mp_transaksi`
    MODIFY `id_transaksi` int(11) NOT NULL AUTO_INCREMENT;
  
  --
  -- AUTO_INCREMENT for table `pemesanan`
  --
  ALTER TABLE `pemesanan`
    MODIFY `id_pemesanan` int(11) NOT NULL AUTO_INCREMENT;
  
  --
  -- AUTO_INCREMENT for table `pengguna`
  --
  ALTER TABLE `pengguna`
    MODIFY `id_pengguna` int(10) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;
  
  --
  -- AUTO_INCREMENT for table `produk`
  --
  ALTER TABLE `produk`
    MODIFY `id_produk` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;
  
  --
  -- AUTO_INCREMENT for table `sementara`
  --
  ALTER TABLE `sementara`
    MODIFY `id_temporary` int(11) NOT NULL AUTO_INCREMENT;
  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 */;
  