开发者

"wrong constant name" error when generating a new model

I'm trying to create a new开发者_JAVA技巧 model like this:

rails generate model Tags name:string

When I run this, I get the following error:

base.rb:266:in `const_defined?': wrong constant name tags (NameError)

Any thoughts? I tried changing Tags to ReportTags and it still gave me the same error.


Model names are singular - try

rails generate model Tag name:string
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜