Class: SIF::Model::Common::ScheduleInfo
- Inherits:
-
Object
- Object
- SIF::Model::Common::ScheduleInfo
- Defined in:
- lib/sif/models/common/schedule_info.rb
Instance Method Summary collapse
- #first_meeting_time ⇒ Object
- #first_nonblank_teacher ⇒ Object
- #first_teacher ⇒ Object
- #teacher ⇒ Object
Instance Method Details
#first_meeting_time ⇒ Object
12 13 14 |
# File 'lib/sif/models/common/schedule_info.rb', line 12 def first_meeting_time meeting_times.first || Common::MeetingTime.new end |
#first_nonblank_teacher ⇒ Object
20 21 22 |
# File 'lib/sif/models/common/schedule_info.rb', line 20 def first_nonblank_teacher teachers.find{ |t| !t.nil? and !t.empty? } end |
#first_teacher ⇒ Object
16 17 18 |
# File 'lib/sif/models/common/schedule_info.rb', line 16 def first_teacher teachers.first end |
#teacher ⇒ Object
24 25 26 |
# File 'lib/sif/models/common/schedule_info.rb', line 24 def teacher first_nonblank_teacher || first_teacher || String.new end |