mirror of
https://github.com/SrIzan10/hc-harbor.git
synced 2026-05-01 10:45:21 +00:00
Humanize mail mission names
This commit is contained in:
@@ -20,6 +20,12 @@ class PhysicalMail < ApplicationRecord
|
||||
"https://hack.club/#{theseus_id}"
|
||||
end
|
||||
|
||||
def humanized_mission_type
|
||||
return "Your first 7-day streak" if first_time_7_streak?
|
||||
|
||||
mission_type.titleize
|
||||
end
|
||||
|
||||
def deliver!
|
||||
slug = "hackatime-#{mission_type.to_s.gsub("_", "-")}"
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
<% end %>
|
||||
<div style="position: relative; z-index: 2;">
|
||||
<h3 style="margin: 0 0 0.5rem 0; font-size: 1.25rem; font-weight: 600;">
|
||||
<%= mail.mission_type.titleize %>
|
||||
<%= mail.humanized_mission_type %>
|
||||
<% if theseus_link %>
|
||||
<span style="font-size: 0.9em; margin-left: 0.5em; color: #6cf;">↗</span>
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user