Sha256: 202ecbca67e85bb42655fd81a9125e92c3b5ab6f8403ec902f2588a372dc03b4
Contents?: true
Size: 370 Bytes
Versions: 5
Compression:
Stored size: 370 Bytes
Contents
class AddOrganizationCustomReference < ActiveRecord::Migration[5.0] def change add_column :decidim_organizations, :reference_prefix, :string Decidim::Organization.find_each do |organization| organization.update_attribute(:reference_prefix, organization.name[0]) end change_column_null :decidim_organizations, :reference_prefix, false end end
Version data entries
5 entries across 5 versions & 1 rubygems