というテーブルがenrollmentsあり、これが現在の基本的な登録設定である場合:
class Enrollment < ActiveRecord::Base
belongs_to :father
belongs_to :mother
belongs_to :child
end
class Father < ActiveRecord::Base
has_many :enrollments
has_many :children
validates :first_name, :presence => true
validates :last_name, :presence => true
end
guardian_1_idここで、 aと aguardian_2_idをenrollmentsテーブルに追加します。どうすればそれを設定できますか?