Class: LesliCalendar::EventService
- Inherits:
-
Lesli::ApplicationLesliService
- Object
- Lesli::ApplicationLesliService
- LesliCalendar::EventService
- Defined in:
- app/services/lesli_calendar/event_service.rb
Instance Method Summary collapse
Instance Method Details
#find(calendar_id) ⇒ Object
36 37 38 39 |
# File 'app/services/lesli_calendar/event_service.rb', line 36 def find calendar_id #super(current_user.account.calendar.calendar.find_by(id: calendar_id)) super(current_user.account.calendar.calendars.first) end |
#index ⇒ Object
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'app/services/lesli_calendar/event_service.rb', line 41 def index() events = current_user.account.calendar.calendars.first.events .select( :id, :title, :description, :date, :start, :end, :url, :location, :status, "'lesli-calendar' as classNames" ) end |