Skip to content

Commit

Permalink
added migration
Browse files Browse the repository at this point in the history
  • Loading branch information
olivM committed Apr 6, 2009
1 parent 6ac80e4 commit ff32528
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 0 deletions.
16 changes: 16 additions & 0 deletions db/migrate/20090406070147_create_users.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
class CreateUsers < ActiveRecord::Migration
def self.up
create_table :users do |t|
t.string :name
t.string :oauth_token
t.string :oauth_secret
t.string :email

t.timestamps
end
end

def self.down
drop_table :users
end
end
15 changes: 15 additions & 0 deletions db/migrate/20090406100933_create_notebooks.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
class CreateNotebooks < ActiveRecord::Migration
def self.up
create_table :notebooks do |t|
t.string :name
t.integer :creator_id
t.text :content

t.timestamps
end
end

def self.down
drop_table :notebooks
end
end
15 changes: 15 additions & 0 deletions db/migrate/20090406121930_create_annoters.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
class CreateAnnoters < ActiveRecord::Migration
def self.up
create_table :annoters do |t|
t.integer :user_id
t.integer :notebook_id
t.string :string

t.timestamps
end
end

def self.down
drop_table :annoters
end
end

0 comments on commit ff32528

Please sign in to comment.