molten-trunk/molten5_withgrid/app/controllers/case_watchers_controller.rb
def update_contact_case_subscriptions
    cases = params[:cases]
    cases_subscribing = params[:case_subscriptions].is_a?(Hash) ? params[:case_subscriptions].keys : []
    cases_unsubscribing = cases - cases_subscribing

    cases_unsubscribing.each do |c_id|
      Case_Watcher.remove_subscription!(current_contact.synced_record, 
                                        :support_case => Sfcase.find(c_id).synced_record )
    end
    redirect_to :controller => 'contact', :action => 'settings', 
                :notice => "Cases subscriptions updated."
  end
# Updates the current contact's case subscriptions
Updates the current contact's case subscriptions
Updates the current contact ' s case subscriptions
def update_contact_case_subscriptions
    cases = params[:cases]
    cases_subscribing = params[:case_subscriptions].is_a?(Hash) ? params[:case_subscriptions].keys : []
    cases_unsubscribing = cases - cases_subscribing
    cases_unsubscribing.each do |c_id|
      Case_Watcher.remove_subscription!(current_contact.synced_record, 
                                        :support_case => Sfcase.find(c_id).synced_record )
    end
    redirect_to :controller => 'contact', :action => 'settings', 
                :notice => "Cases subscriptions updated."
  end
def update_contact_case_subscriptions cases = params [ :cases ] cases_subscribing = params [ :case_subscriptions ] . is_a? ( Hash ) ? params [ :case_subscriptions ] . keys : [ ] cases_unsubscribing = cases - cases_subscribing cases_unsubscribing . each do | c_id | Case_Watcher . remove_subscription! ( current_contact . synced_record , :support_case => Sfcase . find ( c_id ) . synced_record ) end redirect_to :controller => 'contact' , :action => 'settings' , :notice => "Cases subscriptions updated." end
Updates the current contact's case subscriptions
Updates the current contact ' s case subscriptions