Class: CreateSeoMeta
- Inherits:
-
Object
- Object
- CreateSeoMeta
- Defined in:
- lib/generators/active_seo/templates/migration/migration.rb
Instance Method Summary collapse
Instance Method Details
#change ⇒ Object
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
# File 'lib/generators/active_seo/templates/migration/migration.rb', line 2 def change create_table :seo_meta do |t| t.string :title t.text :description t.text :keywords t.boolean :noindex, default: false t.boolean :nofollow, default: false t.integer :seoable_id, null: false t.string :seoable_type, null: false t. end add_index :seo_meta, [:seoable_id, :seoable_type], unique: true end |