fix: enroll users when added to a forum role#32436
fix: enroll users when added to a forum role#32436mariajgrimaldi merged 1 commit intoopenedx:masterfrom
Conversation
|
Thanks for the pull request, @navinkarkera! Please note that it may take us up to several weeks or months to complete a review and merge your PR. Feel free to add as much of the following information to the ticket as you can:
All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here. Please let us know once your PR is ready for our review and all tests are green. |
There was a problem hiding this comment.
There are two parts to this PR:
-
Discussion roles: Restricting this to only enrolled learners make sense here, since only enrolled users have access to the forum pages.
-
Admin/Staff roles:
Currently there are two ways to add an user as a course staff/admin. Either through the instructor dashboard in LMS, or through the Studio. In studio, we can add unenrolled users as course staff, in which case, the user is auto-enrolled to the course. Not sure if the two flows should behave differently, or if there needs to be a consistency, then what would be the correct behaviour.
15d683e to
10377ea
Compare
|
@kaustavb12 As per your suggestion, I am splitting up changes related to course team roles (Admin/staff roles) into a separate PR due to inconsistency in studio and lms interfaces. Now this PR holds only forum roles related change, i.e., only enrolled users can be added to forum roles via instructor dashboard. |
kaustavb12
left a comment
There was a problem hiding this comment.
👍
LGTM
- I tested this: Tested in devstack
- I read through the code
- I checked for accessibility issues
- Includes documentation
- I made sure any change in configuration variables is reflected in the corresponding client's
configuration-securerepository.
The course team management section under Instructor > Membership tab allows users to be added a role even if are not enrolled in the course. This is not the expected behaviour based on the help text displayed in the section. This PR updates update_forum_role_membership api to check whether user is enrolled before adding them to a role. Cherry pick from openedx#32436 (cherry picked from commit 10377ea7d0b1182f5d0b6d389161fab2bac1722a)
The course team management section under Instructor > Membership tab allows users to be added a role even if are not enrolled in the course. This is not the expected behaviour based on the help text displayed in the section. This PR updates update_forum_role_membership api to check whether user is enrolled before adding them to a role. Cherry pick from openedx#32436 (cherry picked from commit 10377ea7d0b1182f5d0b6d389161fab2bac1722a)
|
Hi @openedx/teaching-and-learning! Would someone be able to review / merge this for us? Thanks! |
|
Hi @navinkarkera! Flagging the new tests per the recent update: https://discuss.openedx.org/t/minor-change-to-edx-platform-check-statuses/11131 |
10377ea to
6dc28ad
Compare
|
Hi @openedx/teaching-and-learning! Friendly ping on this. |
6dc28ad to
f47fb1b
Compare
f47fb1b to
471d39d
Compare
|
Hi @navinkarkera and @gabor-boros! Just flagging that a failing check has popped up. |
|
Sandbox destroy request received. |
7 similar comments
|
Sandbox destroy request received. |
|
Sandbox destroy request received. |
|
Sandbox destroy request received. |
|
Sandbox destroy request received. |
|
Sandbox destroy request received. |
|
Sandbox destroy request received. |
|
Sandbox destroy request received. |
Hi @mariajgrimaldi - checking in on this! |
|
Hi folks @mphilbrick211, @navinkarkera! |
|
See https://openedx.slack.com/archives/C057J2D1WU9/p1710940996542269 for more context on the status change |
|
@mariajgrimaldi Should we also update this PR to auto enroll user instead of checking for enrollment similar to #32561? |
|
@navinkarkera: I think so since both PRs were linked to the product proposal. |
1baf6cd to
91132f2
Compare
372961b to
3ed3f67
Compare
3ed3f67 to
9e95bae
Compare
|
@navinkarkera 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future. |
|
2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production. |
|
2U Release Notice: This PR has been deployed to the edX production environment. |
|
2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production. |
|
2U Release Notice: This PR has been deployed to the edX production environment. |
|
2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production. |
|
2U Release Notice: This PR has been deployed to the edX production environment. |
1 similar comment
|
2U Release Notice: This PR has been deployed to the edX production environment. |
Description
The course team management section under Instructor > Membership tab allows users to be added a role even if are not enrolled in the course. This is not the expected behaviour based on the help text displayed in the section.
This PR updates update_forum_role_membership api to enroll user before adding them to a role.
Supporting information
Private-ref: BB-7543Testing instructions
Instructor > Membershiptab, go toCourse Team Managementsection.Other information
A point of discussion: Should we revoke user's course related roles when they unroll from a course?