--
-- Host: localhost    Database: norules_community
-- ------------------------------------------------------


--
-- Table structure for table `admins`
--

CREATE TABLE `admins` (
  `id` char(36) NOT NULL DEFAULT (uuid()),
  `username` varchar(80) NOT NULL,
  `password_hash` varchar(255) NOT NULL,
  PRIMARY KEY (`id`),
  UNIQUE KEY `username` (`username`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

--
-- Dumping data for table `admins`
--

INSERT INTO `admins` VALUES ('2578bac5-395d-11f1-b1ef-554b7a7f11d7','admin','$2a$10$VXHKXUU8hi6kwNnhCuz3..d7IML2FWrC56BFUhR.uxgj0wKnMupGm');

--
-- Table structure for table `blacklist`
--

CREATE TABLE `blacklist` (
  `id` char(36) NOT NULL DEFAULT (uuid()),
  `nama` varchar(150) NOT NULL,
  `nickname` varchar(150) NOT NULL,
  `status` varchar(50) NOT NULL,
  `durasi` varchar(100) DEFAULT 'PERMANEN',
  `alasan` text,
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

--
-- Dumping data for table `blacklist`
--


--
-- Table structure for table `events`
--

CREATE TABLE `events` (
  `id` char(36) NOT NULL DEFAULT (uuid()),
  `title` varchar(180) NOT NULL,
  `description` text,
  `event_date` date NOT NULL,
  `banner_url` longtext,
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

--
-- Dumping data for table `events`
--


--
-- Table structure for table `feedback`
--

CREATE TABLE `feedback` (
  `id` char(36) NOT NULL DEFAULT (uuid()),
  `name` varchar(150) DEFAULT NULL,
  `category` varchar(50) NOT NULL,
  `message` text NOT NULL,
  `is_read` tinyint(1) DEFAULT '0',
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

--
-- Dumping data for table `feedback`
--


--
-- Table structure for table `members`
--

CREATE TABLE `members` (
  `id` char(36) NOT NULL DEFAULT (uuid()),
  `nama` varchar(150) NOT NULL,
  `nickname` varchar(150) NOT NULL,
  `gender` varchar(30) DEFAULT NULL,
  `tanggal_lahir` date DEFAULT NULL,
  `domisili` varchar(150) DEFAULT NULL,
  `no_hp` varchar(30) DEFAULT NULL,
  `division` varchar(50) DEFAULT NULL,
  `role` varchar(50) DEFAULT 'Member',
  `photo_url` longtext,
  `member_password_hash` varchar(255) DEFAULT NULL,
  `status` varchar(30) DEFAULT 'pending',
  `join_date` date DEFAULT (curdate()),
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`),
  UNIQUE KEY `uq_members_nickname` (`nickname`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

--
-- Dumping data for table `members`
--


--
-- Table structure for table `settings`
--

CREATE TABLE `settings` (
  `key` varchar(120) NOT NULL,
  `value` text NOT NULL,
  PRIMARY KEY (`key`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

--
-- Dumping data for table `settings`
--

INSERT INTO `settings` VALUES ('recruitment_status','ACTIVE');

--
-- Table structure for table `testers`
--

CREATE TABLE `testers` (
  `id` char(36) NOT NULL DEFAULT (uuid()),
  `nama` varchar(150) NOT NULL,
  `whatsapp` varchar(30) NOT NULL,
  `is_online` tinyint(1) DEFAULT '0',
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

--
-- Dumping data for table `testers`
--



