Skip to content
Snippets Groups Projects
Commit cb3fe12a authored by Arnaud Levy's avatar Arnaud Levy
Browse files

better name

parent ea959fa0
No related branches found
No related tags found
No related merge requests found
......@@ -130,6 +130,10 @@ class Education::Program < ApplicationRecord
where(published: publication)
}
def to_short_s
short_name.empty? ? to_s : short_name
end
def to_s
"#{name}"
end
......
......@@ -46,11 +46,11 @@
<div class="col-md-4 mt-5 mt-md-0">
<h2>Promotions actuelles</h2>
<h2>Promotions récentes</h2>
<ul class="promotions">
<% @cohorts.each do |cohort| %>
<li>
<%= link_to cohort.program, cohort %>
<%= link_to cohort.program.to_short_s, cohort %>
<b><%= cohort.academic_year %></b>
</li>
<% end %>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment