app/models/costume.rb
# build a costume_assignments record unless one with dancer's id already exists
build a costume_assignments record unless one with dancer's id already exists
build a costume_assignments record unless one with dancer ' s id already exists
def build_assignments_unless_exists(studio, assignments)
    studio.dancers.current_dancers.each do |dancer|
      costume_assignments.build(dancer_id: dancer.id) unless assignments.exists?(dancer_id: dancer.id)
    end
  end
def build_assignments_unless_exists ( studio , assignments ) studio . dancers . current_dancers . each do | dancer | costume_assignments . build ( dancer_id : dancer . id ) unless assignments . exists? ( dancer_id : dancer . id ) end end
build a costume_assignments record unless one with dancer's id already exists
build a costume_assignments record unless one with dancer ' s id already exists
studio
<not_specific>
assignments
<not_specific>