Skip to content

Conversation

@nb159
Copy link
Contributor

@nb159 nb159 commented Jun 19, 2025

Changed readme.

To test the #275 task.

Visit a student page that hasnt made any request to you -> u should be able to add him as supervisee
Visist a student page that has a pending request to u -> u should be able to accept/dismiss him

@nb159 nb159 marked this pull request as ready for review June 19, 2025 13:36
@nb159 nb159 requested a review from jb-cc as a code owner June 19, 2025 13:36
@nb159 nb159 changed the title SCRUM-308: Nuxt Fe(feature): update readme SCRUM-275/308: Nuxt Fe(feature): Enable supervisors to accept/dismiss/add as supervisee students from their profile page Jun 19, 2025
@nb159 nb159 requested a review from Copilot June 19, 2025 17:22
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enables supervisors to manage supervisee relationships directly from student profile pages by fetching pending requests and providing UI actions to add, accept, or dismiss students.

  • Introduces a getSupervisionRequests action in the supervisor store to load pending supervision requests.
  • Refactors matching and profile pages to use the store, adds buttons and modals for accepting, dismissing, or adding students as supervisees.
  • Updates localization files and README to document new workflows and environment setup.

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
Frontend/stores/useSupervisorStore.ts Adds getSupervisionRequests action to fetch pending requests
Frontend/pages/supervisor/matching.vue Fetches requests on mount and removes inline fetch logic
Frontend/pages/profiles/[id].vue Adds supervisee management buttons, modal configuration, and handlers
Frontend/i18n/locales/en-GB.json & de-DE.json Adds translation keys for manage/add/handle supervision requests
Frontend/components/ConfirmationModal/ConfirmationModal.vue Switches to dynamic props.icon and click handler on icon
Frontend/README.md Expands project README with tech stack, features, and setup steps
Frontend/.env.example Clarifies environment variable placeholders and allowed domains
Comments suppressed due to low confidence (3)

Frontend/pages/profiles/[id].vue:71

  • The supervisee management buttons are rendered based only on the profile user's role (isStudent), but you also need to ensure the current user is a supervisor (currentUser?.role === UserRoles.SUPERVISOR) to prevent other roles (e.g., admins) from seeing these actions.
            "

Frontend/pages/profiles/[id].vue:290

  • [nitpick] The function name manageAddAsSupervisee is ambiguous when compared to addStudentAsSupervisee. Consider renaming it to something more descriptive like openAddSuperviseeModal to clearly convey its purpose.
const manageAddAsSupervisee = () => {

Frontend/README.md:6

  • There's a typo here: "framwork" should be "framework". Also consider reviewing the rest of the README for typos like "I8ln", "managment", "compataibile", and "applicaiton".
## Tech stack

@nb159 nb159 requested review from FelixTeutsch and LionRise June 19, 2025 18:02
@jb-cc jb-cc force-pushed the SCRUM-308-Frontend-update-readme branch from 055b56e to c34c170 Compare June 19, 2025 22:58
@jb-cc
Copy link
Contributor

jb-cc commented Jun 19, 2025

It all works nice! Just one small thing: When I am already supervising a student, then the button is still shown. It does not show the error from the backend, but that would be a nice to have. Bernhard also just implemented an endpoint to retrieve accepted requests from a user, if you want to do it that way --> #202

If you want you can already merge it like this, or add the above thing first and then merge. I will approve anyways :)
Just make sure to update the branch as I fixed one small thing

jb-cc
jb-cc previously approved these changes Jun 19, 2025
@jb-cc jb-cc force-pushed the SCRUM-308-Frontend-update-readme branch from 967cd29 to 5b3d30e Compare June 20, 2025 18:36
@jb-cc jb-cc self-requested a review June 20, 2025 19:12
@jb-cc jb-cc closed this Jun 20, 2025
@jb-cc jb-cc deleted the SCRUM-308-Frontend-update-readme branch June 20, 2025 19:26
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.

3 participants