class CreateRcmsTidingsTables
Public Class Methods
down()
click to toggle source
# File lib/generators/templates_tidings/migration.rb, line 16 def self.down drop_table :rcms_tidings end
up()
click to toggle source
# File lib/generators/templates_tidings/migration.rb, line 2 def self.up create_table :rcms_tidings do |t| t.string :image t.string :title t.string :description t.string :slug t.boolean :is_published t.text :text t.timestamps end add_index :rcms_tidings, :slug, unique: true end