Skip to content
Snippets Groups Projects
Unverified Commit c50b1bf1 authored by Sébastien Gaya's avatar Sébastien Gaya
Browse files

allow nested attrs

parent 9709d118
No related branches found
No related tags found
No related merge requests found
......@@ -45,6 +45,7 @@ class Admin::University::Person::AlumniController < Admin::University::Applicati
end
def alumnus_params
# TODO: Permit nested attrs
params.require(:university_person_alumnus)
.permit()
end
......
......@@ -25,6 +25,10 @@ module University::Person::WithEducation
foreign_key: 'university_person_id',
association_foreign_key: 'education_cohort_id'
accepts_nested_attributes_for :cohorts,
reject_if: :all_blank,
allow_destroy: true
# Dénormalisation des liens via cohorts, pour la recherche par facettes
has_and_belongs_to_many :diploma_years,
class_name: 'Education::AcademicYear',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment