aboutsummaryrefslogtreecommitdiffstats
path: root/db
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2017-09-08 15:57:03 +0100
committerStruan Donald <struan@exo.org.uk>2017-09-13 09:50:02 +0100
commit0998aef4fb4e7e94b950a6b337ee0c0df72ec7de (patch)
treef849a3e178fcbae8af93839dacf961d52e1e92b4 /db
parentc03096d4ffe3e17d504239ec4c0f006b1266c8e5 (diff)
add is_default column to response_priorities
Diffstat (limited to 'db')
-rw-r--r--db/downgrade_0055---0054.sql6
-rw-r--r--db/schema.sql1
-rw-r--r--db/schema_0055-add-default-to-reponsepriority.sql5
3 files changed, 12 insertions, 0 deletions
diff --git a/db/downgrade_0055---0054.sql b/db/downgrade_0055---0054.sql
new file mode 100644
index 000000000..a38d74ded
--- /dev/null
+++ b/db/downgrade_0055---0054.sql
@@ -0,0 +1,6 @@
+BEGIN;
+
+ALTER TABLE response_priorities DROP COLUMN is_default;
+
+COMMIT;
+
diff --git a/db/schema.sql b/db/schema.sql
index fedab2b9d..f428ff59d 100644
--- a/db/schema.sql
+++ b/db/schema.sql
@@ -144,6 +144,7 @@ CREATE TABLE response_priorities (
name text not null,
description text,
external_id text,
+ is_default boolean not null default 'f',
unique(body_id, name)
);
diff --git a/db/schema_0055-add-default-to-reponsepriority.sql b/db/schema_0055-add-default-to-reponsepriority.sql
new file mode 100644
index 000000000..0f8b72e13
--- /dev/null
+++ b/db/schema_0055-add-default-to-reponsepriority.sql
@@ -0,0 +1,5 @@
+BEGIN;
+
+ALTER TABLE response_priorities ADD is_default boolean not null default 'f';
+
+COMMIT;