Class: Search::SupportCaseTextPresenter

Inherits:
SupportCasePresenter
  • Object
show all
Defined in:
app/presenters/search/support_case_text_presenter.rb

Overview

Text-only variant of SupportCasePresenter.

Instance Method Summary collapse

Instance Method Details

#participantsString

Returns the participant names joined by semicolons.

Returns:

  • (String)

    the participant names



17
18
19
# File 'app/presenters/search/support_case_text_presenter.rb', line 17

def participants
  r.support_case_participants.select(&:party).map { |scp| scp.party.full_name }.join('; ')
end

#roomsString

Returns the linked room reference numbers joined by semicolons.

Returns:

  • (String)

    the room reference numbers



24
25
26
# File 'app/presenters/search/support_case_text_presenter.rb', line 24

def rooms
  r.room_configurations.map(&:reference_number).join('; ')
end

Returns the support case number as plain text.

Returns:

  • (String)

    the case number



10
11
12
# File 'app/presenters/search/support_case_text_presenter.rb', line 10

def support_case_link
  r.case_number
end