File size: 330 Bytes
874ae95
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
class FacultyController < ApplicationController
  # GET /coaches
  def index
    @coaches =
      policy_scope(Faculty).includes(
        :faculty_cohort_enrollments,
        user: {
          avatar_attachment: :blob
        }
      )

    raise_not_found unless @coaches.exists?

    render 'index', layout: 'student'
  end
end