diff --git a/db/migrate/20190622055449_modify_shixun_info_for_shixuns.rb b/db/migrate/20190622055449_modify_shixun_info_for_shixuns.rb index 5b3ceada6..1a3aa147b 100644 --- a/db/migrate/20190622055449_modify_shixun_info_for_shixuns.rb +++ b/db/migrate/20190622055449_modify_shixun_info_for_shixuns.rb @@ -11,8 +11,5 @@ class ModifyShixunInfoForShixuns < ActiveRecord::Migration[5.2] evaluate_script: shixun[:evaluate_script], shixun_id: shixun.id) end end - if Shixun.first.description.present? - remove_columns :shixuns, :description, :propaedeutics, :evaluate_script - end end end diff --git a/db/migrate/20190622060005_remove_shixun_long_text_for_shixuns.rb b/db/migrate/20190622060005_remove_shixun_long_text_for_shixuns.rb new file mode 100644 index 000000000..bcc8a2bce --- /dev/null +++ b/db/migrate/20190622060005_remove_shixun_long_text_for_shixuns.rb @@ -0,0 +1,7 @@ +class RemoveShixunLongTextForShixuns < ActiveRecord::Migration[5.2] + def change + if Shixun.first.description.present? + remove_columns :shixuns, :description, :propaedeutics, :evaluate_script + end + end +end