Update schema to reflect re-usable error_template_attributes, descriptions, hints, and sorting

This commit is contained in:
Maximilian Grundke
2017-07-11 19:22:12 +02:00
parent d2a089d057
commit 872611bff6
6 changed files with 30 additions and 5 deletions

View File

@@ -0,0 +1,9 @@
class AddDescriptionAndHintToErrorTemplate < ActiveRecord::Migration
def change
add_column :error_templates, :description, :text
add_column :error_templates, :hint, :text
add_column :error_template_attributes, :description, :text
add_column :error_template_attributes, :important, :boolean
end
end

View File

@@ -0,0 +1,6 @@
class ChangeErrorTemplateAttributeRelationshipToNToM < ActiveRecord::Migration
def change
remove_belongs_to :error_template_attributes, :error_template
create_join_table :error_templates, :error_template_attributes
end
end