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

Add Functionality to Invitation Modal #186

Open
wants to merge 8 commits into
base: bog-changes-s23
Choose a base branch
from

Conversation

yatharth-b
Copy link
Contributor

@yatharth-b yatharth-b commented Mar 2, 2023

Summary

Resolves #173

Users can now send invitations to friends from the share schedule popup. Added new variables to ScheduleContext to update and read friend data. Added checks to make sure only signed in users can open popup. Update cloud functions (gt-scheduler/firebase-conf#3) to alter create and handle invitation behavior. Fixed cloud functions to account for requests made from both fetch and axios.

Checklist

  • ScheduleData is updated to include the list of invited friends and the status of the invitation.
  • migrateScheduleData must be updated along with any related tests.
  • Autocomplete displays emails of recently invited friends from the last 3 semesters.
  • Search results are displayed based on what the user has typed in.
  • Emails are sent and feedback is displayed to the user appropriately.
  • Status of invitation is updated appropriately.
  • List of invited friends is displayed appropriately.

How to Test

Run firebase cloud function emulator from the firebase-conf repository and then try inviting users from the frontend. The cloud function links are hardcoded right now to be the local emulator links.

Note

Did not implement recently invited friends feature yet because of the backend overhead.

@github-actions
Copy link

github-actions bot commented Mar 2, 2023

PR Preview Action c7c4712
🚀 Deployed preview to https://gt-scheduler.github.io/website/pr-preview/pr-186/
on branch gh-pages at 2023-04-21 20:34 UTC

Copy link
Contributor

@nhatnghiho nhatnghiho left a comment

Choose a reason for hiding this comment

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

To fix failing CI tests, run yarn test to see which tests are failing and fix them accordingly. Most of these are just because we're adding a new field into ScheduleVersion and some expected values in unit tests do not have this new field yet.

src/components/InvitationModal/index.tsx Outdated Show resolved Hide resolved
src/components/InvitationModal/index.tsx Outdated Show resolved Hide resolved
src/components/InvitationModal/index.tsx Show resolved Hide resolved
@nhatnghiho
Copy link
Contributor

If we're not doing autocomplete anymore, could you remove the code for that? On top of that, allow users to send invitation by pressing Enter when they're done typing.

src/components/InvitationModal/index.tsx Outdated Show resolved Hide resolved
src/components/InvitationModal/index.tsx Outdated Show resolved Hide resolved
src/components/AppDataLoader/index.tsx Outdated Show resolved Hide resolved
@yatharth-b yatharth-b dismissed stale reviews from samarth52 and nhatnghiho March 28, 2023 00:15

changed

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