module Admins::SubjectsHelper def display_subject_status(subject) style = case subject.status when 0 then 'text-secondary' when 1 then 'text-warning' when 2 then 'text-success' end raw content_tag(:span, t("subject.status.#{subject.status}"), class: style) end end