mirror of
https://github.com/openSUSE/osem.git
synced 2026-08-13 19:54:02 +00:00
test I removed accidentally while rebasing restored
This commit is contained in:
parent
22916971c7
commit
a30893fae3
1 changed files with 8 additions and 0 deletions
|
|
@ -56,6 +56,14 @@ class User < ActiveRecord::Base
|
|||
|
||||
validate :biography_limit
|
||||
|
||||
##
|
||||
# Checkes if the user attended the event
|
||||
# This is used for events that require registration
|
||||
# The user must have registered to attend the event
|
||||
# Gets an event
|
||||
# === Returns
|
||||
# * +true+ if the user attended the event
|
||||
# * +false+ if the user did not attend the event
|
||||
def attended_event? event
|
||||
event_registration = event.events_registrations.find_by(registration: self.registrations)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue