diff --git a/events.sql b/events.sql new file mode 100644 index 0000000..96953ee --- /dev/null +++ b/events.sql @@ -0,0 +1,165 @@ +-- phpMyAdmin SQL Dump +-- version 5.1.0 +-- https://www.phpmyadmin.net/ +-- +-- Host: 127.0.0.1 +-- Generation Time: Mar 27, 2021 at 05:17 PM +-- Server version: 10.4.18-MariaDB +-- PHP Version: 8.0.3 + +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: `events` +-- + +-- -------------------------------------------------------- + +-- +-- Table structure for table `events` +-- + +CREATE TABLE `events` ( + `id_events` int(11) NOT NULL, + `title` mediumtext COLLATE utf8mb4_polish_ci NOT NULL, + `description` longtext COLLATE utf8mb4_polish_ci NOT NULL, + `date_start` date NOT NULL, + `date_stop` date NOT NULL, + `time_start` time NOT NULL, + `time_stop` time NOT NULL, + `location` mediumtext COLLATE utf8mb4_polish_ci NOT NULL, + `quantity` int(11) NOT NULL, + `quantity_min` int(11) NOT NULL, + `slots` int(11) NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_polish_ci; + +-- +-- Dumping data for table `events` +-- + +INSERT INTO `events` (`id_events`, `title`, `description`, `date_start`, `date_stop`, `time_start`, `time_stop`, `location`, `quantity`, `quantity_min`, `slots`) VALUES +(3, 'Update Testowo', 'Nowy update testowy 12345', '2021-03-28', '2021-03-28', '03:00:00', '06:00:00', 'Salka Niebieska', 8, 0, 0), +(4, 'Testowo1', 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Purus sit amet volutpat consequat mauris. Ut eu sem integer vitae justo eget magna fermentum iaculis. Amet aliquam id diam maecenas ultricies mi eget mauris pharetra. Turpis massa sed elementum tempus egestas sed sed. Congue quisque egestas diam in arcu cursus euismod quis viverra. Non diam phasellus vestibulum lorem sed risus ultricies tristique nulla. Sed lectus vestibulum mattis ullamcorper velit sed. Mi quis hendrerit dolor magna. Pellentesque adipiscing commodo elit at imperdiet. Est ultricies integer quis auctor elit. Aliquet porttitor lacus luctus accumsan tortor posuere. Mattis pellentesque id nibh tortor id aliquet. Tristique nulla aliquet enim tortor. Mattis rhoncus urna neque viverra justo nec ultrices dui. Vitae justo eget magna fermentum iaculis eu non diam phasellus. Massa sapien faucibus et molestie.', '2021-03-28', '2021-03-28', '07:00:00', '12:00:00', 'Salka Operacyjna', 12, 2, 0), +(5, 'Testowo213', 'asdjnsaijfn aksjnkajfnkajn acn knakjdsn a!@', '2021-03-23', '2021-03-23', '02:30:00', '14:30:00', 'Salka Niebieska', 20, 1, 0), +(11, 'dsadas', 'dsad', '2021-03-30', '2021-03-30', '03:37:00', '12:34:00', 'Salka Niebieska', 11, 1, 0), +(12, 'Mylast', 'dasdasd', '2021-03-24', '2021-03-24', '03:00:00', '04:00:00', 'Salka Akwarium', 12, 3, 0), +(13, 'my name is john', 'dsadasdasda casc ax xaxzcasda cxzc a w21 32wdas 11d@@', '2021-04-06', '2021-04-06', '07:00:00', '10:00:00', 'Salka Czerwona', 16, 7, 0), +(14, 'Dolar is what i need', 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis mi quam, posuere sit amet odio vitae, pellentesque auctor dolor. Morbi magna nisl, gravida ac porttitor ut, volutpat vel dui. Vestibulum pharetra urna nibh, nec semper nulla egestas sit amet. Vestibulum vitae rhoncus nulla, sed imperdiet nisl. Nam commodo posuere commodo. Donec rutrum faucibus urna, a accumsan nisi. Mauris quam felis, scelerisque eu leo et, tincidunt fringilla nisi. Etiam quis tellus tristique, porttitor massa non, malesuada turpis. Cras vehicula id felis at faucibus. Etiam arcu felis, egestas sit amet interdum quis, porta vel ante. Morbi fermentum, nisl a pharetra luctus, nibh arcu bibendum eros, in ultricies leo nunc eget mauris. Donec consequat risus id iaculis fringilla. Nullam gravida erat eget tellus lacinia, non vestibulum nulla hendrerit. Etiam quis tincidunt tortor. Proin nunc diam, egestas pharetra malesuada in, ultricies vitae eros. Donec ornare magna ut tempor venenatis.\r\n\r\nVestibulum pretium feugiat tincidunt. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed sollicitudin nibh nec arcu aliquet sodales. Nam sollicitudin aliquet faucibus. Proin congue tortor ac luctus cursus. Integer varius elit vitae accumsan aliquet. Nulla non lobortis tortor. Sed placerat, risus sollicitudin lacinia eleifend, nibh orci lobortis elit, et condimentum enim diam in mi. Nulla sodales in lacus sit amet convallis. Suspendisse et ultricies est, sed tempus velit. Proin elementum arcu sed eros tempus egestas. Aliquam sit amet ligula lobortis, tincidunt quam a, rutrum justo. Donec eleifend auctor dictum.\r\n\r\nVestibulum eu dolor odio. Praesent id enim enim. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Nulla gravida vulputate purus nec tempor. Fusce in vehicula dui. Pellentesque varius, odio ut convallis maximus, diam nisi convallis dolor, nec placerat ante nulla non metus. Donec suscipit accumsan sapien eget imperdiet. Maecenas sollicitudin dui finibus odio ullamcorper, a blandit tellus vulputate. Pellentesque eu risus ac augue dictum fermentum a et massa. Vivamus et consectetur nibh. Proin finibus ut ipsum vel tristique. Morbi dignissim nisl elit, non ultrices odio auctor tempor. Aliquam dictum neque non tincidunt hendrerit.\r\n\r\nPraesent turpis orci, sollicitudin vitae aliquet quis, dictum id massa. Vestibulum interdum, mi vel congue ullamcorper, nisi elit dictum orci, nec pulvinar tortor metus id sem. Donec id mi malesuada, accumsan orci in, tristique felis. Aliquam nec felis nec arcu egestas tempor. Donec ornare neque a tellus iaculis tincidunt sit amet eu ante. Nullam eu venenatis velit. Nunc viverra dapibus auctor. Duis pretium dui in nunc vehicula consectetur. Suspendisse eu odio condimentum, pellentesque nulla semper, commodo ligula. Mauris at malesuada ante, et hendrerit lorem. Donec quis odio eget ex finibus euismod quis id sem. Curabitur at sollicitudin ligula. Donec molestie ante ac dapibus pellentesque. Sed tempor sem sit amet mauris fringilla semper.\r\n\r\nSed nec pretium dolor. Duis dapibus rhoncus risus, nec posuere ipsum pretium vitae. Nulla magna ex, lacinia non libero ac, accumsan condimentum ex. Vestibulum mattis ligula nisl. Vivamus bibendum pharetra egestas. In aliquam leo et velit hendrerit imperdiet. Fusce mattis magna vitae urna convallis sollicitudin. Pellentesque vitae turpis urna. Phasellus sed tristique massa, at porttitor leo. Donec id condimentum nulla. Morbi sit amet nulla nisi. Suspendisse ac sollicitudin mi. Donec magna mauris, convallis at posuere quis, feugiat non enim. Pellentesque quis enim vitae lectus pellentesque porttitor. Interdum et malesuada fames ac ante ipsum primis in faucibus.\r\n\r\nSuspendisse sed dolor eu erat dapibus luctus at quis purus. Sed ac turpis neque. Sed ac hendrerit libero. Nam bibendum justo mi, id posuere massa fringilla non. Cras nec convallis augue. Interdum et malesuada fames ac ante ipsum primis in faucibus. Sed sit amet efficitur est. Nullam non elit nisi. Nullam eleifend faucibus risus nec finibus. Duis eu maximus purus.\r\n\r\nCras non imperdiet magna, ac fermentum tortor. Praesent sit amet molestie dui. Pellentesque vel ornare mi, ac ultricies libero. Duis viverra diam arcu, vel tempor diam tristique ut. Suspendisse euismod risus in ipsum tempor, non pellentesque dui viverra. Phasellus massa urna, gravida vestibulum lobortis ut, varius non risus. Proin et pharetra felis, vel consectetur nunc. Aenean placerat sollicitudin sem eu pharetra.\r\n\r\nCras lacinia risus tellus, vitae egestas eros pellentesque sed. Praesent suscipit mauris finibus mattis efficitur. Ut facilisis est nibh, vitae vulputate felis viverra at. Vivamus venenatis lobortis ante quis mattis. Aliquam nibh ante, feugiat pellentesque ipsum et, faucibus dignissim odio. Aliquam scelerisque ut purus sed tincidunt. Nunc ut erat sed erat porta faucibus.\r\n\r\nNullam justo lectus, molestie eu sagittis et, malesuada eget nulla. Pellentesque dictum, sapien id placerat eleifend, augue elit imperdiet est, sed ultrices tellus diam vitae tellus. Aliquam porta est elit, et vehicula tellus maximus ut. Nullam volutpat commodo tortor, quis interdum elit pharetra vehicula. Fusce rutrum sed ante eu semper. Nunc facilisis, enim vel sollicitudin volutpat, justo quam tempor quam, sed fringilla enim tellus at dolor. Cras convallis felis non orci suscipit, sed dignissim odio iaculis. Suspendisse bibendum leo nibh, ac maximus quam pretium vitae. Sed id lectus auctor, egestas lacus vitae, mollis sapien. Donec tristique vitae elit et ullamcorper. Sed vulputate ut lacus a condimentum. Ut id arcu metus. Sed elit ex, consectetur at velit ut, placerat cursus ex. Nunc vel quam et dui commodo imperdiet. Vestibulum vitae enim et nisl pulvinar euismod.', '2021-03-31', '2021-03-31', '13:06:00', '14:06:00', 'Salka Zielona', 15, 1, 0), +(15, 'Lewandowski ', 'sadas', '2021-03-30', '2021-03-30', '23:10:00', '12:10:00', 'Salka Zielona', 11, 1, 0), +(16, 'Dam dam dam...', 'sdadsadsad', '2021-03-24', '2021-03-24', '13:15:00', '14:14:00', 'Salka Operacyjna', 12, 4, 0), +(17, 'Kiwi', 'kiwawiwadsawaiskdawkd SDAK DjASK$ile=mysqli_num_rows($rezultat);', '2021-04-01', '2021-04-01', '16:15:00', '17:10:00', 'Salka Błękitna', 12, 1, 0); + +-- -------------------------------------------------------- + +-- +-- Table structure for table `manager` +-- + +CREATE TABLE `manager` ( + `id` int(11) NOT NULL, + `employeeID` int(11) NOT NULL, + `id_events` int(11) NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_polish_ci; + +-- +-- Dumping data for table `manager` +-- + +INSERT INTO `manager` (`id`, `employeeID`, `id_events`) VALUES +(14, 17001813, 4), +(15, 17001813, 3), +(16, 17001413, 3); + +-- -------------------------------------------------------- + +-- +-- Table structure for table `users` +-- + +CREATE TABLE `users` ( + `employeeID` int(11) NOT NULL, + `name` varchar(20) COLLATE utf8mb4_polish_ci NOT NULL, + `surnname` varchar(20) COLLATE utf8mb4_polish_ci NOT NULL, + `password` varchar(25) COLLATE utf8mb4_polish_ci NOT NULL, + `perm` varchar(10) COLLATE utf8mb4_polish_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_polish_ci; + +-- +-- Dumping data for table `users` +-- + +INSERT INTO `users` (`employeeID`, `name`, `surnname`, `password`, `perm`) VALUES +(17001222, 'Wladimir', 'Wladimirowicz', 'Wlad1234', 'admin'), +(17001413, 'Adam', 'Nowacki', '12qwert', 'normal'), +(17001777, 'Marian', 'Bandziorek', 'Marcin1234', 'normal'), +(17001813, 'Jan', 'Kowalski', 'Dupa1234', 'admin'); + +-- +-- Indexes for dumped tables +-- + +-- +-- Indexes for table `events` +-- +ALTER TABLE `events` + ADD PRIMARY KEY (`id_events`); + +-- +-- Indexes for table `manager` +-- +ALTER TABLE `manager` + ADD PRIMARY KEY (`id`), + ADD KEY `eventmanager` (`id_events`), + ADD KEY `usermanager` (`employeeID`); + +-- +-- Indexes for table `users` +-- +ALTER TABLE `users` + ADD PRIMARY KEY (`employeeID`); + +-- +-- AUTO_INCREMENT for dumped tables +-- + +-- +-- AUTO_INCREMENT for table `events` +-- +ALTER TABLE `events` + MODIFY `id_events` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=18; + +-- +-- AUTO_INCREMENT for table `manager` +-- +ALTER TABLE `manager` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=18; + +-- +-- AUTO_INCREMENT for table `users` +-- +ALTER TABLE `users` + MODIFY `employeeID` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=17001814; + +-- +-- Constraints for dumped tables +-- + +-- +-- Constraints for table `manager` +-- +ALTER TABLE `manager` + ADD CONSTRAINT `eventmanager` FOREIGN KEY (`id_events`) REFERENCES `events` (`id_events`), + ADD CONSTRAINT `usermanager` FOREIGN KEY (`employeeID`) REFERENCES `users` (`employeeID`); +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 */;