pruvodce/db/schema.sql

39 lines
1.3 KiB
MySQL
Raw Normal View History

2021-07-15 18:42:46 +00:00
-- Adminer 4.7.5 SQLite 3 dump
CREATE TABLE "poi" (
"id" integer NOT NULL PRIMARY KEY AUTOINCREMENT,
"slug" text NOT NULL,
2021-07-15 19:03:35 +00:00
"lon" real NOT NULL,
"lat" real NOT NULL,
2021-07-15 18:42:46 +00:00
"name" text NOT NULL,
"description" text NOT NULL,
"cheatsheet" text NOT NULL,
"internal" text NOT NULL,
"is_public" integer NOT NULL DEFAULT '0'
);
CREATE UNIQUE INDEX "poi_slug" ON "poi" ("slug");
CREATE TABLE sqlite_sequence(name,seq);
INSERT INTO "sqlite_sequence" ("name", "seq") VALUES ('users', 1);
2021-07-15 19:03:35 +00:00
INSERT INTO "sqlite_sequence" ("name", "seq") VALUES ('poi', 0);
2021-07-15 18:31:36 +00:00
CREATE TABLE "users" (
"id" integer NOT NULL PRIMARY KEY AUTOINCREMENT,
"member_id" integer NULL,
"username" text NOT NULL,
"password" text NOT NULL,
"name" text NOT NULL,
"note" text DEFAULT NULL,
"is_active" integer NOT NULL DEFAULT '1',
"is_superuser" integer NOT NULL DEFAULT '0'
);
CREATE UNIQUE INDEX "users_usename" ON "users" ("username");
2021-07-15 18:42:46 +00:00
INSERT INTO "users" ("id", "member_id", "username", "password", "name", "note", "is_active", "is_superuser") VALUES (1, NULL, 'severak', '$2y$10$G//hwvWHJYNHFk6JNr3GG.kuzM/dI9UTtU2bxr9EvTTEg0YOc8mj.', 'Severák', '(testovací účet)', 1, 1);
2021-07-15 18:31:36 +00:00
2021-07-15 18:42:46 +00:00
--