Add CRUD operations for Programming Groups

* Correct sorting in table
* Modify page when nested in exercises
* Fix links between pages
* Link from statistics page to programming_groups/index
* Link from submission page to programming_groups/<id>
* Allow filtering for exercise ID on ProgrammingGroup#index
* Add search fields for internal and external user id on pg/index
This commit is contained in:
kiragrammel
2023-09-14 16:56:36 +02:00
committed by Sebastian Serth
parent f1ca5da44d
commit 79ce069f68
23 changed files with 543 additions and 38 deletions

View File

@@ -0,0 +1,16 @@
= form_for(@programming_group) do |f|
= render('shared/form_errors', object: @programming_group)
h3 = t('activerecord.attributes.programming_group.member')
.table-responsive
table.table class="#{@members.present? ? 'sortable' : ''}"
thead
tr
th = t('activerecord.attributes.exercise.selection')
th = t('navigation.sections.contributors')
= collection_check_boxes :programming_group, :programming_group_membership_ids, @members, :id, :id do |b|
tr
td = b.check_box class: 'form-check-input'
td = link_to_if(policy(b.object.user).show?, b.object.user.displayname, b.object.user)
.actions = render('shared/submit_button', f: f, object: @programming_group)