Class: Search::CertificationPresenter
- Inherits:
-
BasePresenter
- Object
- SimpleDelegator
- BasePresenter
- Search::CertificationPresenter
show all
- Includes:
- Presenters::Timeable
- Defined in:
- app/presenters/search/certification_presenter.rb
Instance Attribute Summary
#current_account, #options, #url_helper
Instance Method Summary
collapse
#can?, #capture, #concat, #content_tag, #fa_icon, #h, #initialize, #link_to, #number_to_currency, #present, presents, #r, #safe_present, #simple_format, #u
Constructor Details
This class inherits a constructor from BasePresenter
Instance Method Details
#certification_link ⇒ Object
22
23
24
25
26
|
# File 'app/presenters/search/certification_presenter.rb', line 22
def certification_link
if r.certification_id.present?
h.link_to(r.certification_reference, h.certification_path(r.certification_id))
end
end
|
#course_link ⇒ Object
18
19
20
|
# File 'app/presenters/search/certification_presenter.rb', line 18
def course_link
h.link_to(r.certification_name, h.course_enrollment_path(r.id))
end
|
#customer_link ⇒ Object
14
15
16
|
# File 'app/presenters/search/certification_presenter.rb', line 14
def customer_link
h.link_to(r.customer_name, h.customer_path(r.customer_id))
end
|
#is_inactive ⇒ Object
6
7
8
|
# File 'app/presenters/search/certification_presenter.rb', line 6
def is_inactive
h.y r.is_inactive
end
|
#state ⇒ Object
10
11
12
|
# File 'app/presenters/search/certification_presenter.rb', line 10
def state
LocatorRecord.human_state_name(r.state)
end
|