Skip to content

Commit

Permalink
Accessibilité : Supprime la statistique sur la page index des évaluat…
Browse files Browse the repository at this point in the history
…ions des superadmins
  • Loading branch information
etienneCharignon committed Nov 4, 2024
1 parent 4508195 commit 13e6b29
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 33 deletions.
14 changes: 0 additions & 14 deletions app/admin/evaluation.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,20 +53,6 @@

form partial: 'form'

sidebar :statistiques, only: :index, if: proc { can?(:manage, Compte) } do
ul do
collection_complete = collection.except(:limit, :offset, :order)
evaluations_par_synthese = collection_complete.select(:synthese_competences_de_base)
.group(:synthese_competences_de_base)
.count
evaluations_par_synthese.delete(nil)

div do
pie_chart evaluations_par_synthese
end
end
end

sidebar :responsable_de_suivi, only: :show, if: proc { resource.responsable_suivi.present? } do
render(Tag.new(resource.responsable_suivi.display_name,
supprimable: can?(:supprimer_responsable_suivi, Evaluation),
Expand Down
19 changes: 0 additions & 19 deletions spec/features/admin/evaluation_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,25 +15,6 @@
parcours_type: parcours_type
end

describe '#index' do
before do
connecte(mon_compte)
visit admin_evaluations_path
end

it "n'affiche pas les statistiques" do
expect(page).not_to have_content('Statistiques')
end

context 'en tant que superadmin' do
let(:role) { 'superadmin' }

it 'affiche les statistiques' do
expect(page).to have_content('Statistiques')
end
end
end

describe '#show' do
before { connecte(mon_compte) }

Expand Down

0 comments on commit 13e6b29

Please sign in to comment.