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

cohorts

parent 40a84c1d
No related branches found
No related tags found
No related merge requests found
......@@ -4,7 +4,7 @@ class Extranet::CohortsController < Extranet::ApplicationController
through_association: :education_cohorts
def index
@cohorts = @cohorts.ordered.page(params[:page])
@cohorts = current_context.about&.cohorts || @cohorts
breadcrumb
end
......
<% cohorts_paged = cohorts.ordered.page(params[:page]).per(60) %>
<div class="row">
<% cohorts.each do |cohort| %>
<% cohorts_paged.each do |cohort| %>
<div class="col-md-6">
<article class="card mb-4">
<div class="card-body">
......@@ -15,3 +16,4 @@
</div>
<% end %>
</div>
<%= paginate cohorts_paged, theme: 'bootstrap-5' %>
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