/*
SQLyog Ultimate v13.1.1 (64 bit)
MySQL - 5.5.60-MariaDB : Database - antrian_slot
*********************************************************************
*/

/*!40101 SET NAMES utf8 */;

/*!40101 SET SQL_MODE=''*/;

/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
CREATE DATABASE /*!32312 IF NOT EXISTS*/`antrian_slot` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `antrian_slot`;

/*Table structure for table `antrian_ptsp` */

DROP TABLE IF EXISTS `antrian_ptsp`;

CREATE TABLE `antrian_ptsp` (
  `id` int(5) DEFAULT NULL,
  `jenis` varchar(25) DEFAULT NULL,
  `tanggal` date DEFAULT NULL,
  `loket` varchar(10) DEFAULT NULL,
  `no_antrian` int(4) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Table structure for table `antrian_sidang_slot` */

DROP TABLE IF EXISTS `antrian_sidang_slot`;

CREATE TABLE `antrian_sidang_slot` (
  `perkara_id` int(11) NOT NULL,
  `nomor_perkara` varchar(30) NOT NULL,
  `tanggal_sidang` date NOT NULL,
  `no_antrian` tinyint(255) DEFAULT NULL,
  `ruang_sidang` varchar(10) NOT NULL,
  `agenda_sidang` varchar(255) DEFAULT NULL,
  `pihak_id` bigint(20) DEFAULT NULL,
  `nohp` varchar(20) DEFAULT NULL,
  `slot` tinyint(2) DEFAULT NULL,
  `durasi` tinyint(255) DEFAULT NULL,
  `jam_mulai_real` datetime DEFAULT NULL,
  `jam_mulai` datetime DEFAULT NULL,
  `jam_selesai` datetime DEFAULT NULL,
  `tgl_ambil` datetime DEFAULT NULL,
  `status` tinyint(1) DEFAULT NULL,
  PRIMARY KEY (`nomor_perkara`,`perkara_id`,`tanggal_sidang`,`ruang_sidang`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Table structure for table `jam_sidang` */

DROP TABLE IF EXISTS `jam_sidang`;

CREATE TABLE `jam_sidang` (
  `jam_mulai_sidang` time NOT NULL,
  `jam_istirahat_sidang` time NOT NULL,
  `jam_mulai_istirahat` time NOT NULL,
  PRIMARY KEY (`jam_mulai_sidang`,`jam_istirahat_sidang`,`jam_mulai_istirahat`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Table structure for table `jenis_ptsp` */

DROP TABLE IF EXISTS `jenis_ptsp`;

CREATE TABLE `jenis_ptsp` (
  `id` varchar(15) DEFAULT NULL,
  `loket` varchar(25) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Table structure for table `ruang_sidang` */

DROP TABLE IF EXISTS `ruang_sidang`;

CREATE TABLE `ruang_sidang` (
  `km_id` int(4) NOT NULL,
  `nama` varchar(255) NOT NULL,
  `ruang` varchar(50) DEFAULT NULL,
  `hari` varchar(50) NOT NULL,
  PRIMARY KEY (`km_id`,`nama`,`hari`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
