OpenProject is the leading open source project management software.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
openproject/db/migrate/20200903064009_enable_curre...

12 lines
343 B

class EnableCurrentProjectCustomFieldsColumns < ActiveRecord::Migration[6.0]
def up
columns = Setting.enabled_projects_columns
cf_columns = ProjectCustomField.pluck(:id).map { |id| "cf_#{id}" }
Setting.enabled_projects_columns = (columns + cf_columns).uniq
end
def down
# Nothing to do as setting is not used
end
end