ddd

Ruby code posted
created at 28 Jul 14:32

Edit | Back
1
2
3
4
5
6
7
8
9
10
class ChangeProductsPrice < ActiveRecord::Migration[5.0]
  def change
    reversible do |dir|
      change_table :products do |t|
        dir.up   { t.change :price, :string }
        dir.down { t.change :price, :integer }
      end
    end
  end
end
259 Bytes in 2 ms with coderay