diff --git a/app/views/exercises/index.html.slim b/app/views/exercises/index.html.slim index ae018e82..9c0b14ee 100644 --- a/app/views/exercises/index.html.slim +++ b/app/views/exercises/index.html.slim @@ -32,12 +32,20 @@ h1 = Exercise.model_name.human(count: 2) td = exercise.files.teacher_defined_tests.count td = exercise.maximum_score td.public data-value=exercise.public? = symbol_for(exercise.public?) - td = link_to(t('shared.show'), exercise) if policy(exercise).show? td = link_to(t('shared.edit'), edit_exercise_path(exercise)) if policy(exercise).edit? - td = link_to(t('shared.destroy'), exercise, data: {confirm: t('shared.confirm_destroy')}, method: :delete) if policy(exercise).destroy? - td = link_to(t('.clone'), clone_exercise_path(exercise), data: {confirm: t('shared.confirm_destroy')}, method: :post) if policy(exercise).clone? td = link_to(t('.implement'), implement_exercise_path(exercise)) if policy(exercise).implement? td = link_to(t('shared.statistics'), statistics_exercise_path(exercise)) if policy(exercise).statistics? + td + .btn-group + button.btn.btn-primary-outline.btn-xs.dropdown-toggle data-toggle="dropdown" type="button" = t('shared.actions_button') + span.caret + span.sr-only Toggle Dropdown + ul.dropdown-menu.pull-right role="menu" + li = link_to(t('shared.show'), exercise) if policy(exercise).show? + li = link_to(t('shared.destroy'), exercise, data: {confirm: t('shared.confirm_destroy')}, method: :delete) if policy(exercise).destroy? + li = link_to(t('.clone'), clone_exercise_path(exercise), data: {confirm: t('shared.confirm_destroy')}, method: :post) if policy(exercise).clone? + li = link_to(t('shared.statistics'), statistics_exercise_path(exercise)) if policy(exercise).statistics? + = render('shared/pagination', collection: @exercises) p = render('shared/new_button', model: Exercise) diff --git a/config/locales/de.yml b/config/locales/de.yml index 53df1858..06085b9d 100644 --- a/config/locales/de.yml +++ b/config/locales/de.yml @@ -402,6 +402,7 @@ de: created_at: Erstellt destroy: Löschen edit: Bearbeiten + actions_button: 'Andere Aktionen' errors_one: 'Beim Speichern ist ein Fehler aufgetreten' errors_other: 'Beim Speichern sind %{count} Fehler aufgetreten' help: diff --git a/config/locales/en.yml b/config/locales/en.yml index 1e72cb34..c37fcd80 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -402,6 +402,7 @@ en: created_at: Created At destroy: Delete edit: Edit + actions_button: 'Other actions' errors_one: 'An error prohibited this %{model} from being saved' errors_other: '%{count} errors prohibited this %{model} from being saved' help: