Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
谁能解释一下 Rails 3 中的模型名称约定?
例如: 我的数据库中有一个名为“materialtitles”的表。 模型文件,模型类必须满足Rails中名称约定的名称是什么???
感谢帮助。
文件materialtitle.rb名将驻留在 app/models 中。
materialtitle.rb
您的模型的类名将是Materialtitle.
Materialtitle