- content_for :lightboxes do
  = render :partial => 'shared/lightbox_report'
  = render :partial => 'shared/workgroup'

- if @portal_clazz.is_teacher?(current_visitor) || current_visitor.has_role?("admin")
  = render_portal_clazz_partial 'portal/clazzes/show'
  = render_portal_clazz_partial 'portal/offerings/list_for_clazz'
  = link_to 'Manage Student Roster', roster_portal_clazz_url(@portal_clazz), :class => "button pie", :id=>"btn_manage_student_roster"
  / all these br's are to keep a strange scroll bar from showing up
  %br
  %br

- elsif current_visitor.has_role?("manager", "researcher")
  = render :partial => 'shared/offering_for_teacher', :collection => @portal_clazz.offerings, :as => :offering
- else
  = render_portal_clazz_partial 'portal/clazzes/show'
  = render :partial => 'shared/offerings_for_student', :locals => { :offerings => @offerings }

- is_teacher = @portal_clazz.is_teacher?(current_visitor)
- can_manage = is_teacher || current_visitor.has_role?("manager", "researcher", "admin")
= render_portal_clazz_partial 'portal/clazzes/show'
- if can_manage
  %p
    = link_to 'Manage Student Roster',
    roster_portal_clazz_url(@portal_clazz),
    :class => "button pie",
    :id=>"btn_manage_student_roster"
  %p
    = render :partial => 'shared/offering_for_teacher', :collection => @portal_clazz.offerings, :as => :offering
- elsif
  = render :partial => 'shared/offerings_for_student', :locals => { :offerings => @offerings }

Remove unused offering assignment in view.
Remove unused offering assignment in view.
