CougarCS / CougarCS-AdminPortal

Our officer admin portal created with React & Typescript
MIT License
6 stars 12 forks source link

Add edit functionality to ViewMemberModal #36

Closed seesjays closed 1 year ago

seesjays commented 1 year ago

We have a modal that works for viewing members, but it'd be nice to edit them also.

image

When the save button is clicked, it should call a function editMember, which can be defined in the same file you put the modal in. Pass the updated member information into the function as a memberType object. There's no need to make the actual api request just yet, since we're still working that out.

type memberType = {
  contact_id: string;
  email: string;
  first_name: string;
  last_name: string;
  phone_number: number;
  shirt_size_id: string;
  timestamp: string;
  uh_id: number;
};

We're waiting on a selection component (#33) so for now you can use a TextInput for the shirt size, and we'll correct it later on.