Module: Services::AssessmentRequestHelper

Defined in:
app/helpers/services/assessment_request_helper.rb

Instance Method Summary collapse

Instance Method Details

#assessment_request_status(status) ⇒ Object



4
5
6
7
8
9
10
11
12
13
14
15
16
17
# File 'app/helpers/services/assessment_request_helper.rb', line 4

def assessment_request_status(status)
  status_name = 'Unknown'
  case status
  when Services::AssessmentRequest::STATUS_AVAILABLE
    status_name = 'Available'
  when Services::AssessmentRequest::STATUS_COMPLETED
    status_name = 'Downloaded'
  when Services::AssessmentRequest::STATUS_EMPTY
    status_name = 'Empty'
  when Services::AssessmentRequest::STATUS_ERROR
    status_name = 'Error'
  end
  "(#{status}) #{status_name}"
end