adding pilots

This commit is contained in:
2024-07-27 21:42:54 -05:00
parent 1e5f6a72d8
commit d550c90184
3 changed files with 5 additions and 6 deletions

View File

@@ -83,12 +83,15 @@ const PilotForm: React.FC<PilotFormProps> = ({
<DrawerHeader text="Add Pilot" onClose={onOpenCloseDrawer} />
<form onSubmit={methods.handleSubmit(onSubmit)}>
<DrawerBody>
<div className="grid grid-cols-1 gap-4">
<div className="grid grid-cols-3 gap-4">
<div className="col-span-1">
<Typography variant="h5">Info</Typography>
<hr className="my-3" />
</div>
<div className="col-span-1">
<Typography>Name</Typography>
</div>
<div className="col-span-2">
<Controller
name="name"
control={methods.control}
@@ -97,7 +100,7 @@ const PilotForm: React.FC<PilotFormProps> = ({
results={peoplePickerResults}
inputProps={{
disabled: disabled,
label: 'Name',
// label: 'Name',
onChange: (event) => handlePeoplePickerOnChange(event),
value: value
}}

View File

@@ -28,7 +28,6 @@ const PilotFormCertificates: React.FC<IPilotFormCertificates> = ({
{fields.map((field, index) => {
return (
<>
{/* // <div key={field.id}> */}
<div>
<Controller
name={`certificates.${index}.type`}
@@ -86,7 +85,6 @@ const PilotFormCertificates: React.FC<IPilotFormCertificates> = ({
<div>
<Button onClick={() => remove(index)}>Remove</Button>
</div>
{/* </div> */}
</>
);
})}

View File

@@ -28,7 +28,6 @@ const PilotFormEndorsements: React.FC<IPilotFormEndorsements> = ({
{fields.map((field, index) => {
return (
<>
{/* // <div key={field.id}> */}
<div>
<Controller
name={`endorsements.${index}.type`}
@@ -74,7 +73,6 @@ const PilotFormEndorsements: React.FC<IPilotFormEndorsements> = ({
<div>
<Button onClick={() => remove(index)}>Remove</Button>
</div>
{/* </div> */}
</>
);
})}