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

(SP: 3) Add review submission functionality to AddReviewModal.tsx #2917

Open
dudchakk opened this issue Nov 30, 2024 · 0 comments · May be fixed by #2915
Open

(SP: 3) Add review submission functionality to AddReviewModal.tsx #2917

dudchakk opened this issue Nov 30, 2024 · 0 comments · May be fixed by #2915
Assignees
Labels
feature Frontend part Functional Something isn't working Student Implementation that regard to the student Tutor Implementation that regard to the tutor

Comments

@dudchakk
Copy link
Contributor

Description: The AddReviewModal.tsx component needs to be updated to enable submitting reviews to the backend. This involves creating a service to handle the API POST request and integrating it with the modal so that review data is sent and saved in the reviews collection upon submission.

Create the service:

Develop a function to send a POST request to the backend. The data sent must include:

  • comment - string,
  • rating - number,
  • targetUserId - ObjectId,
  • targetUserRole - UserRoleEnum,
  • offer - ObjectId

Endpoints to send data to: POST http://localhost:8080/reviews/

Integrate the service with the modal:

  • Attach the service to the Submit button in AddReviewModal.tsx;
  • Collect the input values from the modal and pass them to the service.
@dudchakk dudchakk added Frontend part feature Tutor Implementation that regard to the tutor Student Implementation that regard to the student Functional Something isn't working labels Nov 30, 2024
@dudchakk dudchakk self-assigned this Nov 30, 2024
@github-project-automation github-project-automation bot moved this to Project Backlog in SpaceToStudy Nov 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Frontend part Functional Something isn't working Student Implementation that regard to the student Tutor Implementation that regard to the tutor
Projects
Status: Project Backlog
1 participant