summaryrefslogtreecommitdiffstats
path: root/db/migrate/20101107130441_add_custom_fields_visible.rb
blob: d3edb145f0cf1a22f5045f9f951fb8ade706aa5b (plain)
1
2
3
4
5
6
7
8
9
10
class AddCustomFieldsVisible < ActiveRecord::Migration[4.2]
  def self.up
    add_column :custom_fields, :visible, :boolean, :null => false, :default => true
    CustomField.update_all("visible = #{CustomField.connection.quoted_true}")
  end

  def self.down
    remove_column :custom_fields, :visible
  end
end