Cross Reference:
xref
: /
ontohub
/
db
/
migrate
/
20140516121353_add_path_to_ontology_version.rb
Home
History
Annotate
Line#
Navigate
Download
Search
only in
./
20140516121353_add_path_to_ontology_version.rb revision 823b204d13c129df1ae3b49ff62ee1da0c8f6b63
class
AddPathToOntologyVersion
<
ActiveRecord
::
Migration
def
change
add_column
:
ontology_versions
, :
basepath
, :
string
,
null
:
true
add_column
:
ontology_versions
, :
file_extension
, :
string
,
limit
:
20
Ontology.all.map
do
|o|
o.versions.each
do
|v|
v.basepath
=
o.basepath
v.file
_extension
=
o.file
_extension
v.save
!
end
end
end
end