Cross Reference:
xref
: /
ontohub
/
db
/
migrate
/
20130422184444_create_categories_table.rb
Home
History
Annotate
Line#
Navigate
Download
Search
only in
./
20130422184444_create_categories_table.rb revision 773e8045866bdb28eaa01213dc082552952ff0ad
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
class
CreateCategoriesTable
<
ActiveRecord
::
Migration
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
def
change
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
create_table
:
categories
do
|t|
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
t.string
:
name
, :
null
=>
false
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
t.timestamps
:
null
=>
false
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
end
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
add_index
:
categories
, :
name
, :
unique
=>
true
802014878b7383de536e4fa0ceced1bce3217ead
Daniel Couto Vale
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
end
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger
end
736e78aff9e67436c35d4835c24fca667f3cadf3
Julian Kornberger