aboutsummaryrefslogtreecommitdiffstats
path: root/db
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2011-08-17 22:56:37 +0100
committerStruan Donald <struan@exo.org.uk>2011-08-17 22:56:37 +0100
commit3b5d561700b184c20e63111d4cbc1daab78e16c6 (patch)
treef0c53c6bf8d4ebf12e5388053ad856fb0d0e7b86 /db
parent390f8e8ad1e10f832c4323c39bed2c883744a03f (diff)
parentf38b8e985697c35a62374a2f02dce2d681ef58cd (diff)
Merge branch 'master' of ssh://git.mysociety.org/data/git/public/fixmystreet into new_statuses
Conflicts: db/schema.sql perllib/FixMyStreet/App/Controller/Admin.pm perllib/FixMyStreet/DB/Result/User.pm t/app/controller/admin.t templates/web/default/admin/update_edit.html web/css/core.css
Diffstat (limited to 'db')
-rw-r--r--db/schema.sql6
-rw-r--r--db/schema_0005-add_abuse_flags_to_users_and_reports.sql9
2 files changed, 13 insertions, 2 deletions
diff --git a/db/schema.sql b/db/schema.sql
index 5213e8a02..99cf2832d 100644
--- a/db/schema.sql
+++ b/db/schema.sql
@@ -131,7 +131,8 @@ create table users (
name text,
phone text,
password text not null default '',
- from_council integer -- id of council user is from or null/0 if not
+ from_council integer, -- id of council user is from or null/0 if not
+ flagged boolean not null default 'f'
);
-- Problems reported by users of site
@@ -182,7 +183,8 @@ create table problem (
cobrand_data text not null default '' check (cobrand_data ~* '^[a-z0-9]*$'), -- Extra data used in cobranded versions of the site
lastupdate timestamp not null default ms_current_timestamp(),
whensent timestamp,
- send_questionnaire boolean not null default 't'
+ send_questionnaire boolean not null default 't',
+ flagged boolean not null default 'f'
);
create index problem_state_latitude_longitude_idx on problem(state, latitude, longitude);
create index problem_user_id_idx on problem ( user_id );
diff --git a/db/schema_0005-add_abuse_flags_to_users_and_reports.sql b/db/schema_0005-add_abuse_flags_to_users_and_reports.sql
new file mode 100644
index 000000000..040d3294d
--- /dev/null
+++ b/db/schema_0005-add_abuse_flags_to_users_and_reports.sql
@@ -0,0 +1,9 @@
+begin;
+
+ALTER table problem
+ ADD column flagged BOOL NOT NULL DEFAULT 'f';
+
+ALTER table users
+ ADD column flagged BOOL NOT NULL DEFAULT 'f';
+
+commit;