From d378887d25d026319a9e1d4b66c1b2d0cb6ebbd7 Mon Sep 17 00:00:00 2001 From: Kira Date: Sun, 6 Oct 2019 00:59:19 -0700 Subject: [PATCH] Add tag relationship reason --- db/migrate/20191006073950_add_tag_rel_reasons.rb | 6 ++++++ db/structure.sql | 9 ++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) create mode 100644 db/migrate/20191006073950_add_tag_rel_reasons.rb diff --git a/db/migrate/20191006073950_add_tag_rel_reasons.rb b/db/migrate/20191006073950_add_tag_rel_reasons.rb new file mode 100644 index 000000000..bbb347396 --- /dev/null +++ b/db/migrate/20191006073950_add_tag_rel_reasons.rb @@ -0,0 +1,6 @@ +class AddTagRelReasons < ActiveRecord::Migration[6.0] + def change + add_column :tag_aliases, :reason, :text, null: false, default: '' + add_column :tag_implications, :reason, :text, null: false, default: '' + end +end diff --git a/db/structure.sql b/db/structure.sql index e5e4aaf9e..8c093b113 100644 --- a/db/structure.sql +++ b/db/structure.sql @@ -2121,7 +2121,8 @@ CREATE TABLE public.tag_aliases ( updated_at timestamp without time zone, post_count integer DEFAULT 0 NOT NULL, approver_id integer, - forum_post_id integer + forum_post_id integer, + reason text DEFAULT ''::text NOT NULL ); @@ -2161,7 +2162,8 @@ CREATE TABLE public.tag_implications ( updated_at timestamp without time zone, approver_id integer, forum_post_id integer, - descendant_names text[] DEFAULT '{}'::text[] + descendant_names text[] DEFAULT '{}'::text[], + reason text DEFAULT ''::text NOT NULL ); @@ -5325,6 +5327,7 @@ INSERT INTO "schema_migrations" (version) VALUES ('20190916204908'), ('20190919213915'), ('20190924233432'), -('20191003070653'); +('20191003070653'), +('20191006073950');