-
Notifications
You must be signed in to change notification settings - Fork 4
Group matching #271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
juopmu
wants to merge
14
commits into
master
Choose a base branch
from
group-matching
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Group matching #271
Changes from 2 commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
102fbff
start groups table
AstiV 9b1ead1
Add group tables
juopmu 7e32ad0
add coaches to events
simaofreitas f9584e0
Add coach names to event groups view and restructure logic of group c…
AstiV 053061d
fix attendee distribution to event groups
AstiV ff4b739
Add .vscode/ to .gitignore
AstiV d17136a
create regenerate action
AstiV d2127ef
reload event before adding new groups
simaofreitas 18e9d16
Add line breaks to event groups tables andadd printe styles
AstiV e870aa7
group attendees by languages and distribute them to event groups
AstiV 8662f85
edit comments and fix typos
AstiV 565e8c4
add language tags to event groups table view
AstiV b3b82a4
add attendees and coaches count info
AstiV df4c2d9
Add logic to group attendees by OS additionally to language and add O…
AstiV File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| class EventGroup < ApplicationRecord | ||
| belongs_to :event | ||
| has_and_belongs_to_many :coaches | ||
| has_and_belongs_to_many :applications, join_table: "event_groups_applications" | ||
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,27 @@ | ||
| <% if @event.has_groups? %> | ||
| has Groups | ||
|
||
|
|
||
| <% @event_groups.each do |event_group| %> | ||
simaofreitas marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| <h2><%= event_group.name %></h2> | ||
| <table> | ||
| <thead> | ||
| <tr> | ||
| <th>Attendees</th> | ||
| <th>Coaches</th> | ||
| </tr> | ||
| </thead> | ||
| <tbody> | ||
| <tr> | ||
| <td> | ||
| <%= event_group.applications.map(&:name).join(", ") %> | ||
| </td> | ||
| <td> | ||
| </td> | ||
| </tr> | ||
| </tbody> | ||
| </table> | ||
| <%end %> | ||
|
|
||
| <% else %> | ||
| <%= button_to "Generate groups", generate_admin_event_groups_path(@event), method: :post %> | ||
| <% end %> | ||
5 changes: 5 additions & 0 deletions
5
db/migrate/20200423182041_change_event_group_coaches_to_event_groups_coaches.rb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| class ChangeEventGroupCoachesToEventGroupsCoaches < ActiveRecord::Migration[5.2] | ||
| def change | ||
| rename_table :event_group_coaches, :event_groups_coaches | ||
| end | ||
| end |
5 changes: 5 additions & 0 deletions
5
db/migrate/20200423182618_change_event_group_attendees_to_event_groups_applicants.rb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| class ChangeEventGroupAttendeesToEventGroupsApplicants < ActiveRecord::Migration[5.2] | ||
| def change | ||
| rename_table :event_group_attendees, :event_groups_applications | ||
| end | ||
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.