Class: CreateMonimonisTable

Inherits:
ActiveRecord::Migration
  • Object
show all
Defined in:
lib/generators/monimoni/templates/migration.rb

Class Method Summary collapse

Class Method Details

.downObject



7
8
9
# File 'lib/generators/monimoni/templates/migration.rb', line 7

def self.down
  drop_table :monimonis
end

.upObject



2
3
4
5
# File 'lib/generators/monimoni/templates/migration.rb', line 2

def self.up
   create_table :monimonis
   Monimoni::Model.find_or_create_by(:id => 1)
end