* the meeting or copy author gets automagically added as an invitee. myproject #2670
* better test coverage of the meeting copy
* corrected lost initial comment for copied agendas in meeting copy (introduced in commit:5e8a2b54)
* restore copying the agenda on meeting copy lost in commit:48062434
* test and account for freak boundary conditions introduced by the better copy feature (also see myproject #3109)
pull/6827/head
Felix Schäfer14 years agocommitted byFelix Schäfer
copy.participants<<self.participants.invited.reject{|p|copy_participant_user_ids.include?p.user_id}.collect(&:clone).each{|p|p.attended=false}# Make sure the participants have no id
copy
end
@ -77,6 +79,7 @@ class Meeting < ActiveRecord::Base
# set defaults
self.start_time||=Date.tomorrow+10.hours
self.duration||=1
self.participants.build(:user=>self.author,:invited=>true)if(self.new_record?&&self.participants.empty?&&self.author)# Don't add the author as participant if we already have some through nested attributes