From 36c5c5f4442a2c2eb7ae73ceebd4e57e81d7a804 Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Tue, 12 Aug 2014 21:40:56 +0200 Subject: [PATCH] Send notify after organisation has changed. --- app/models/organization.rb | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/models/organization.rb b/app/models/organization.rb index 189600f20..b15d33540 100644 --- a/app/models/organization.rb +++ b/app/models/organization.rb @@ -6,9 +6,12 @@ class Organization < ApplicationModel extend Organization::Search include Organization::SearchIndex - has_and_belongs_to_many :users - has_many :members, :class_name => 'User' - validates :name, :presence => true + has_and_belongs_to_many :users + has_many :members, :class_name => 'User' + validates :name, :presence => true + + after_create :notify_clients_after_create + after_update :notify_clients_after_update activity_stream_support :role => 'Admin' history_support