Newer
Older
smart-home-server / database_dump / smart-home-server_table_users.sql

-- --------------------------------------------------------

--
-- Структура таблицы `users`
--

CREATE TABLE `users` (
  `id` int(11) NOT NULL,
  `group_id` int(11) NOT NULL DEFAULT 0,
  `nickname` varchar(100) NOT NULL COMMENT 'like login',
  `role` varchar(50) NOT NULL DEFAULT '''user''' COMMENT 'user | admin | superadmin',
  `password` varchar(255) NOT NULL COMMENT 'hash',
  `first_name` int(11) NOT NULL,
  `mid_name` int(11) NOT NULL,
  `userpic` int(11) NOT NULL,
  `contacts` text NOT NULL DEFAULT '{}' COMMENT 'json object',
  `create_at` timestamp NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;