我正在爲我的rails應用程序配置公寓gem,以便爲用戶提供創建子域的功能。我有一個嵌套形式和試圖訪問時 「賬戶/新」 我收到以下錯誤:在視圖表單中沒有將符號隱式轉換爲整數
no implicit conversion of Symbol into Integer in view forms
賬戶/ new.html.erb
<div>
</div>
<h2>Create an Account</h2>
<%= form_for @account do |f| %>
<%= f.fields_for :owner do |o| %>
<%= form_for o, :email do %>
<%= o.text_field :email, class: 'form-control' %>
<% end %>
<%= form_for o, :password do %>
<%= o.password_field :password, class: 'form-control' %>
<% end %>
<%= form_for o, :password_confirmation do %>
<%= o.password_field :password_confirmation, class: 'form-control' %>
<% end %>
<% end %>
<%= form_for f, :subdomain do %>
<div class="input-group">
<%= f.text_field :subdomain, class: 'form-control' %>
<span class="input-group-addon">.scrumteam.com</span>
</div>
<% end %>
<%= f.submit class: 'btn btn-primary' %>
<% end %>
</div>
</div>
accounts_controller.rb
private
def account_params
params.require(:account).permit(:subdomain, :owner_attributes => [:email, :password, :password_confirmation])
end