belongs_to 나는 간단한 has_many를 생성 한 두 activerecords과의 관계 belongs_to 난, 초기화되지 않은 일정 도구 :: 버전을 만들려고 할 때레일 3은 일정한 오류, has_many을 초기화되지 않은
tool.rb :
class Tool < ActiveRecord::Base
attr_accessible :name
validates_presence_of :name
has_many :versions
end
:
abc.html.erb
class Versions < ActiveRecord::Base
belongs_to :tool
attr_accessible :tool_version
end
versions.rb
on submit 나는 오류가 발생합니다. 내가 여기서 뭐하는거야?