-
Notifications
You must be signed in to change notification settings - Fork 168
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
Issue #3345231 by zanivdmar: Missing option to accept invite #3326
Merged
Conversation
This file contains 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
…oup joining option is only by request while user is invited by group/site manager.
Thanks for contributing towards Open Social! A maintainer from the @goalgorilla/maintainers group might not review all changes from all teams/contributors. Please don't be discouraged if it takes a while. In the meantime, we have some automated checks running and it might be that you will see our comments with some tips or requests to speed up the review process. 😊 |
zanvidmar
added
team: guardians
status: needs review
This pull request is waiting for a requested review
labels
Mar 1, 2023
zanvidmar
changed the title
issuer #3345231 by zanivdmar: Missing option to accept invite
Issue #3345231 by zanivdmar: Missing option to accept invite
Mar 1, 2023
zanvidmar
added
prio: medium
type: bug
Fixes a bug in Open Social
and removed
prio: high
labels
Mar 1, 2023
…les like social_course are correctly included.
…an also be an array.
…open to join", shows for regular users as "invitation only".
… defined by field_group_allowed_join_method.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
prio: medium
status: needs review
This pull request is waiting for a requested review
team: guardians
type: bug
Fixes a bug in Open Social
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.
Problem
Invited user is missing option to accept/reject invitation when they are invited to "request to join" group.
Solution
Which "join plugin" is initiated with given group can be determined by field or by method. Flexible groups are defining this by field_group_allowed_join_method "Join methods". In the code, there was already predicted that If user has a pending invite, we should skip the request button and go to "fallback"
added
join method, but that never worked since #2658. To fix this we addedadded
join method as something that is always available for flexible groups despite and in addition to what is selected by "Join methods"Code explanation
social_group_invite.module
Users with certain permissions (SM/GM) can always invite users (member management feature), despite what join method is selected per flexible group. Join options are provided by plugins and which plugins are initiated per entity type, can be defined by field (for example by field_group_allowed_join_method in flexible groups) or by method. If something is defined by field, this is considered as something that user can determine while methods are a bit more predefined.
In this part of code, we are simply adding
added
join method in addition to what is selected by "Join methods". The only case where adding theadded
method is actually used, is when "Request to join" option in "Join methods" is selected.social_group.module
On flexible group create (group/add/flexible_group), there is "Join methods" field which is expected to list of radio buttons. Because we added
added
method to the conditions that triggers the code below are not met anymore.Ideally we should check differently, when we should show checkboxes, but this piece of code was introduced as something that disturbs the process flow as less as possible as this has effect on all the groups.
SocialGroupRequestJoin.php
This piece of code is checking whether "fallback" invite buttons should be shown instead of request to join.
uid
has been changed toentity_id
because we are interested if current user has invitation and not if current user created invitation.invitation_status
was introduced to narrow down only pending invitations.Issue tracker
3345231
Related issue on social course 3345506
Theme issue tracker
N/A
How to test
Additional tests
Definition of done
Before merge
After merge
Screenshots
Release notes
Invited user is missing option to accept/reject invitation when they are invited to "request to join" flexible group. This regression is fixed by this update.
Change Record
N/A
Translations
N/A
translations.php
file.