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

@@ -46,7 +46,11 @@ class Neuigkeit < ActiveRecord::Base
if self.has_meeting? if self.has_meeting?
return self.meeting.meetingtyp.picture return self.meeting.meetingtyp.picture
else else
return self.picture 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 end
end end