Move guestInfo to hook and reload if posting role
- The hook returns the info for a single guest, and a function to reload that info from the api. - The roles of the guest are now on the roles attribute of the guest object instead of as its own object. - Adding a new role now triggers a reload of the data from the api after the post request has completed. Resolves: GREG-114
Showing
- frontend/src/hooks/useGuest/index.tsx 52 additions, 0 deletionsfrontend/src/hooks/useGuest/index.tsx
- frontend/src/routes/sponsor/guest/guestInfo/index.tsx 2 additions, 4 deletionsfrontend/src/routes/sponsor/guest/guestInfo/index.tsx
- frontend/src/routes/sponsor/guest/guestRoleInfo/index.tsx 3 additions, 4 deletionsfrontend/src/routes/sponsor/guest/guestRoleInfo/index.tsx
- frontend/src/routes/sponsor/guest/index.tsx 6 additions, 50 deletionsfrontend/src/routes/sponsor/guest/index.tsx
- frontend/src/routes/sponsor/guest/newGuestRole/index.tsx 6 additions, 4 deletionsfrontend/src/routes/sponsor/guest/newGuestRole/index.tsx
Loading
Please register or sign in to comment