残渣是:
发布于 2013-05-27 13:49:02
在config/config es.rb文件上添加以下内容:
resources: comments # its aplural version of an existing modelrails将提供一些方法来链接到控制器中的方法,您可以通过输入终端找到这些方法:
rake routes使用第一列并添加"_path“或"_url”
这些可以在rails "link_to“方法中使用,例如:
link_to "this is the text for the link", new_comment_pathhttps://stackoverflow.com/questions/13872645
复制相似问题