Skip to content
Extraits de code Groupes Projets
Valider 95578e79 rédigé par danielgrippi's avatar danielgrippi
Parcourir les fichiers

fix removing from aspect -> contact removal bug

parent 86fe2db2
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -9,13 +9,13 @@ class AspectMembershipsController < ApplicationController
def destroy
#note :id is garbage
@person_id = params[:person_id]
@aspect_id = params[:id]
@person_id = params[:person_id]
@aspect_id = params[:aspect_id]
@contact = current_user.contact_for(Person.where(:id => @person_id).first)
membership = @contact ? @contact.aspect_memberships.where(:aspect_id => @aspect_id).first : nil
@contact = current_user.contact_for(Person.where(:id => @person_id).first)
membership = @contact ? @contact.aspect_memberships.where(:aspect_id => @aspect_id).first : nil
if membership && membership.destroy
if membership && membership.destroy
flash.now[:notice] = I18n.t 'aspect_memberships.destroy.success'
respond_to do |format|
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter