1
是否有任何快速的方法來爲embeds_many-embedded_in關係的窗體? 我有以下幾點:Formtastic與Mongoid嵌入關係
class Team
include Mongoid::Document
field :name, :type => String
embeds_many :players
end
class Player
include Mongoid::Document
embedded_in :team, :inverse_of => :players
field :name, :type => String
end
我想創建一個團隊,爲玩家嵌入的編輯形式。看到https://github.com/bowsersenior/formtastic_with_mongoid_tutorial,但「TODO」在那裏。