Ruby on rails 评论表可以';不可渲染
由于某种原因,Rails 3无法呈现评论表单,表单为:Ruby on rails 评论表可以';不可渲染,ruby-on-rails,forms,comments,nested,rendering,Ruby On Rails,Forms,Comments,Nested,Rendering,由于某种原因,Rails 3无法呈现评论表单,表单为: <% form_for ([@post.eng_post, @post.eng_post.eng_comments.build]) do |f| %> 这些模型的结构如下: Posts (have one)-> EngPost (has many)-> EngComments (更详细的模型在这里) 谢谢替换替换谢谢!!!我实际上是从rails 2迁移过来的。像这样的小东西太多了!:)非常感谢。我实际上是从rai
<% form_for ([@post.eng_post, @post.eng_post.eng_comments.build]) do |f| %>
这些模型的结构如下:
Posts (have one)-> EngPost (has many)-> EngComments
(更详细的模型在这里)
谢谢替换
替换谢谢!!!我实际上是从rails 2迁移过来的。像这样的小东西太多了!:)非常感谢。我实际上是从rails 2迁移过来的。像这样的小东西太多了!:)
--- !ruby/object:EngComment
attributes:
id: !!null
eng_post_id: 97
full_name: !!null
website: !!null
email: !!null
comment: !!null
created_at: !!null
updated_at: !!null
Posts (have one)-> EngPost (has many)-> EngComments