-- phpMyAdmin SQL Dump
-- version 4.7.0
-- https://www.phpmyadmin.net/
--
-- Hôte : 127.0.0.1
-- Généré le : jeu. 20 juil. 2017 à 06:08
-- Version du serveur : 5.7.17
-- Version de PHP : 5.6.30
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 */;
--
-- Base de données : `groupaccess`
--
CREATE DATABASE IF NOT EXISTS `groupaccess` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
USE groupaccess;
-- --------------------------------------------------------
--
-- Structure de la table `groups`
--
CREATE TABLE `groups` (
`idgroup` int(10) UNSIGNED NOT NULL COMMENT 'id of the group',
`name` varchar(256) NOT NULL COMMENT 'group''s name',
`description` text,
`startaccesstime` time DEFAULT NULL,
`endaccesstime` time DEFAULT NULL,
`datecreation` date NOT NULL,
`datecreationtimestamp` bigint(20) UNSIGNED NOT NULL,
`recurrence` enum('dayly','weekly','monthly','quartely','yearly','once','custom') NOT NULL DEFAULT 'dayly',
`days` varchar(256) NOT NULL
) ;
--
-- Déchargement des données de la table `groups`
--
INSERT INTO `groups` (`idgroup`, `name`, `description`, `startaccesstime`, `endaccesstime`, `datecreation`, `datecreationtimestamp`, `recurrence`, `days`) VALUES
(1, 'FIRST', '', '00:00:00', '23:59:59', '2017-07-07', 1499378400, 'dayly', ''),
(2, 'fordelete', '', '09:00:35', '11:00:00', '2017-07-10', 2130822035, 'quartely', '');
-- --------------------------------------------------------
--
-- Structure de la table `users`
--
CREATE TABLE `users` (
`user_id` int(10) UNSIGNED NOT NULL,
`username` varchar(25) NOT NULL,
`password` varchar(256) NOT NULL,
`mail` varchar(256) NOT NULL,
`firstname` varchar(256) NOT NULL,
`lastname` varchar(256) NOT NULL,
`dateinscription` bigint(20) UNSIGNED NOT NULL,
`groupid` int(10) UNSIGNED NOT NULL DEFAULT '1',
`idvalidation` varchar(300) NOT NULL,
`statutvalidation` enum('0','1') NOT NULL DEFAULT '0',
`role` enum('admin','modo','user') NOT NULL DEFAULT 'user'
) ;
--
-- Déchargement des données de la table `users`
--
INSERT INTO `users` (`user_id`, `username`, `password`, `mail`, `firstname`, `lastname`, `dateinscription`, `groupid`, `idvalidation`, `statutvalidation`, `role`) VALUES
(1, 'zinsou', '5ace3dcd9e1dbec0791d5a3440063f00', 'leizmo@gmail.com', 'zinsou', 'moise', 1500518172, 1, '', '1', 'admin'),
(2, 'manuel', 'eb62f6b9306db575c2d596b1279627a4', 'info@phpclasses.org', 'lemos', 'manuel', 1500523599, 1, '0', '1', 'admin');
--
-- Index pour les tables déchargées
--
--
-- Index pour la table `groups`
--
ALTER TABLE `groups`
ADD PRIMARY KEY (`idgroup`),
ADD UNIQUE KEY `name` (`name`);
--
-- Index pour la table `users`
--
ALTER TABLE `users`
ADD PRIMARY KEY (`user_id`),
ADD UNIQUE KEY `username` (`username`),
ADD UNIQUE KEY `mail` (`mail`);
--
-- AUTO_INCREMENT pour les tables déchargées
--
--
-- AUTO_INCREMENT pour la table `groups`
--
ALTER TABLE `groups`
MODIFY `idgroup` int(10) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT 'id of the group';
--
-- AUTO_INCREMENT pour la table `users`
--
ALTER TABLE `users`
MODIFY `user_id` int(10) UNSIGNED 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 */;
|