public
Rubygem
Description: Extras for DataMapper, including bridges to DataObjects::Migrations and Merb::DataMapper
Homepage: http://datamapper.org
Clone URL: git://github.com/sam/dm-more.git
Changed many_to_one in dm-is-tree to belongs_to
Dan Kubb (author)
Mon Jun 09 09:37:24 -0700 2008
commit  7c8f33d2f5e0d873751229f8f783ff27a35f856c
tree    c9f1e083c17fe9186f8576ed21d788b4d346f794
parent  fac411441ba56dd0302de2da1e67e9428bd154a3
...
62
63
64
65
 
66
67
68
...
62
63
64
 
65
66
67
68
0
@@ -62,7 +62,7 @@ module DataMapper
0
           configuration = { :child_key => :parent_id }
0
           configuration.update(options) if Hash === options
0
 
0
-          many_to_one :parent, :class_name => name, :child_key => [ configuration[:child_key] ]
0
+          belongs_to :parent, :class_name => name, :child_key => [ configuration[:child_key] ]
0
           has n, :children, :class_name => name, :child_key => [ configuration[:child_key] ]
0
 
0
           include DataMapper::Is::Tree::InstanceMethods

Comments