Tag: mongoid formtastic

Formtastic与Mongoid embedded_in的关系

有没有快速的方法来为embeds_many-embedded_in关系制作表单? 我有以下内容: 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”。