Class: WorkActivity::Message
- Inherits:
-
BaseMessage
- Object
- Renderer
- BaseMessage
- WorkActivity::Message
- Defined in:
- app/models/work_activity.rb
Constant Summary
Constants inherited from Renderer
Renderer::DATE_FORMAT, Renderer::DATE_TIME_FORMAT, Renderer::SORTABLE_DATE_TIME_FORMAT, Renderer::UNKNOWN_USER
Instance Method Summary collapse
-
#created_by_user_html ⇒ Object
Override the default:.
- #title_html ⇒ Object
Methods inherited from BaseMessage
#body_html, #mark_down_to_html, #user_refernces
Methods inherited from Renderer
#created_sortable_html, #created_updated_html, #initialize, #to_html
Constructor Details
This class inherits a constructor from WorkActivity::Renderer
Instance Method Details
#created_by_user_html ⇒ Object
Override the default:
281 282 283 284 285 286 |
# File 'app/models/work_activity.rb', line 281 def created_by_user_html return UNKNOWN_USER unless @work_activity.created_by_user user = @work_activity.created_by_user "#{user.given_name_safe} (@#{user.uid})" end |
#title_html ⇒ Object
288 289 290 |
# File 'app/models/work_activity.rb', line 288 def title_html "<span class='activity-history-title'>#{created_by_user_html} at #{created_updated_html}</span>" end |