%table.table.table-striped.simpleTable
  %thead
    %tr
      %th.sortable{"data-sort" => "string"} #{term_for :student}
      %th.sortable{"data-sort" => "string"} #{term_for :badges}
      - if current_course.valuable_badges?
        %th.sortable{"data-sort" => "int"} Total Badge Score
  %tbody
    - current_course.students.each do |student|
      - cache ['v1', student, current_course, 'public_badges'] do
        - if student.badges_shared(current_course)
          %tr
            %td= student.name
            %td
              - student.earned_badges.each do |earned_badge|
                - cache ['v1', earned_badge.badge, 'shared'] do
                  - if earned_badge.shared? && earned_badge.icon.present?
                    = image_tag earned_badge.icon, :alt => earned_badge.name, :width => '40'

%table.table.table-striped.simpleTable
  %thead
    %tr
      %th.sortable{"data-sort" => "string"} #{term_for :student}
      %th.sortable{"data-sort" => "string"} #{term_for :badges}
      - if current_course.valuable_badges?
        %th.sortable{"data-sort" => "int"} Total Badge Score
  %tbody
    - current_course.students.each do |student|
      - cache ['v1', student, current_course, 'public_badges'] do
        - if student.badges_shared(current_course)
          %tr
            %td= student.name
            %td
              - student.earned_badges.each do |earned_badge|
                - cache ['v1', earned_badge.badge, 'shared'] do
                  - if earned_badge.shared? && earned_badge.icon.present?
                    = image_tag earned_badge.icon, :alt => earned_badge.name, :width => '40'
              %td
                - if current_course.valuable_badges?
                  = student.earned_badge_score_for_course(current_course)

Fix display of Total Badge Score on student dashboard.
Fix display of Total Badge Score on student dashboard.
