Skip to content
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

Update GetWebSessionRequest to support masquerading #2958

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rh12
Copy link
Contributor

@rh12 rh12 commented Oct 31, 2024

refs: MBL-17910
affects: Student, Teacher, Parent
release note: none

Problem

When an admin acted as a student, closed discussions were still repliable, although students should not be able to reply to closed discussions. This was because the hybrid discussion page was reached with the admin's permissions instead of the masqueraded user's.

Solution

When masquerading getting session_token needs to use "/api/v1/login/session_token" path instead of "/login/session_token", and the URL in the return_to query parameter also needs to have the as_user_id parameter.

Test plan:

  • Verify closed discussions are not repliable when an admin acts as a student. See ticket for details and credentials.
  • Verify it works properly when logging in as the student, directly.
  • Smoke test a K5 user's Homeroom, Classes, etc.

Screenshots

BeforeAfter

Checklist

  • Follow-up e2e test ticket created
  • Tested on phone
  • Tested on tablet

@inst-danger
Copy link
Contributor

inst-danger commented Oct 31, 2024

Teacher Build QR Code:

@inst-danger
Copy link
Contributor

inst-danger commented Oct 31, 2024

Parent Build QR Code:

@inst-danger
Copy link
Contributor

inst-danger commented Oct 31, 2024

Student Build QR Code:

@inst-danger
Copy link
Contributor

inst-danger commented Oct 31, 2024

Warnings
⚠️ This pull request will not generate a release note.

Affected Apps: Student, Teacher, Parent

MBL-17910

Coverage New % Master % Delta
Canvas iOS 91.7% 91.69% 0%

Generated by 🚫 dangerJS against 0bad7cc

refs: MBL-17910
affects: Student, Teacher, Parent
release note: none

test plan: See PR description
@rh12 rh12 force-pushed the bugfix/MBL-17910-Reply-edit-options-viewable-in-closed-discussions-when-acting-as-student branch from dde191a to 0bad7cc Compare October 31, 2024 01:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants