attachment titlepic for neuigkeit

This commit is contained in:
Andreas Stephanides
2015-04-07 23:22:08 +02:00
parent 0df5e72e15
commit 6c3c98c919

View File

@@ -45,11 +45,15 @@ class Neuigkeit < ActiveRecord::Base
else
if self.has_meeting?
return self.meeting.meetingtyp.picture
else
unless self.attachments.where(flag_titlepic: true).first.nil?
return self.attachments.where(flag_titlepic: true).first.datei
else
return self.picture
end
end
end
end
def is_annoncement?
!self.meeting.nil?
end