Users can see waiting votes, votes can be terminated
[cavote.git] / schema.sql
index 7f6a0bc..541fa23 100644 (file)
@@ -18,7 +18,7 @@ create table users (
 
 create table groups (
     id INTEGER primary key autoincrement,
-    name TEXT,
+    name TEXT unique not null,
     system INTEGER default 0 not null 
 );
 
@@ -42,6 +42,7 @@ create table votes (
     is_multiplechoice INTEGER default 1 not null,
     is_weighted INTEGER default 0 not null,
     is_open INTEGER default 0 not null,
+    is_terminated INTEGER default 0 not null,
     id_author INTEGER, -- :COMMENT:maethor:120528: not null ?
     id_group INTEGER default 1 not null,
     FOREIGN KEY(id_author) REFERENCES users(id)
@@ -76,5 +77,5 @@ create table user_choice (
 insert into users (email, password, name, organization, is_admin, key) values ("admin@admin.fr", "d033e22ae348aeb5660fc2140aec35850c4da997", "Toto (admin) Tata", "World corp", 1, "test"); -- mdp = admin
 insert into groups (id, name, system) values (1, "Tous", 1);
 insert into groups (name) values ("CA");
-insert into groups (name) values ("Members");
+insert into groups (name) values ("Membres");