Sha256: a4b3802bafb0ed87b9704e06e0638ba0ed31bbd15fb14481e62242802d1f75c6

Contents?: true

Size: 365 Bytes

Versions: 88

Compression:

Stored size: 365 Bytes

Contents

# frozen_string_literal: true

class AddReferenceToProjects < ActiveRecord::Migration[5.0]
  class Project < ApplicationRecord
    self.table_name = :decidim_budgets_projects
  end

  def change
    add_column :decidim_budgets_projects, :reference, :string
    Project.find_each(&:save)
    change_column_null :decidim_budgets_projects, :reference, false
  end
end

Version data entries

88 entries across 88 versions & 1 rubygems

Version Path
decidim-budgets-0.29.1 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.28.4 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.27.9 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.29.0 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.28.3 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.27.8 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.29.0.rc4 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.29.0.rc3 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.29.0.rc2 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.29.0.rc1 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.28.2 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.27.7 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.28.1 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.27.6 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.26.10 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.26.9 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.28.0 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.27.5 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.28.0.rc5 db/migrate/20170215132708_add_reference_to_projects.rb
decidim-budgets-0.28.0.rc4 db/migrate/20170215132708_add_reference_to_projects.rb