Add migration to add custom_url field to BlogPost.
This commit is contained in:
parent
b3c06562a4
commit
07a1a81b95
1 changed files with 9 additions and 0 deletions
9
db/migrate/5_add_custom_url_field_to_blog_posts.rb
Normal file
9
db/migrate/5_add_custom_url_field_to_blog_posts.rb
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
class AddCustomUrlFieldToBlogPosts < ActiveRecord::Migration
|
||||||
|
def self.up
|
||||||
|
add_column :blog_posts, :custom_url, :string
|
||||||
|
end
|
||||||
|
|
||||||
|
def self.down
|
||||||
|
remove_column :blog_posts, :custom_url
|
||||||
|
end
|
||||||
|
end
|
Loading…
Add table
Add a link
Reference in a new issue