limiting pilot data for unauthenticated users
This commit is contained in:
@@ -205,7 +205,6 @@ const LogForm: React.FC<ILogFormProps> = ({
|
|||||||
name="pilotId"
|
name="pilotId"
|
||||||
control={methods.control}
|
control={methods.control}
|
||||||
render={({ field: { onChange, value } }) => {
|
render={({ field: { onChange, value } }) => {
|
||||||
console.log(value)
|
|
||||||
return (
|
return (
|
||||||
<Select
|
<Select
|
||||||
disabled={state.isDisabled}
|
disabled={state.isDisabled}
|
||||||
|
|||||||
@@ -177,6 +177,20 @@ const Logbook: React.FC<unknown> = () => {
|
|||||||
accessorKey: 'notes',
|
accessorKey: 'notes',
|
||||||
header: 'Notes'
|
header: 'Notes'
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
header: 'Actions',
|
||||||
|
meta: {
|
||||||
|
align: 'center',
|
||||||
|
headerAlign: 'center'
|
||||||
|
},
|
||||||
|
cell: (info: any) => (
|
||||||
|
<ActionMenu
|
||||||
|
id={info.row.original.rowKey}
|
||||||
|
onDelete={onDeleteEntry}
|
||||||
|
onOpenCloseForm={onOpenCloseEntryForm}
|
||||||
|
/>
|
||||||
|
)
|
||||||
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
const authColumns: ColumnDef<ILogbookEntry>[] = [
|
const authColumns: ColumnDef<ILogbookEntry>[] = [
|
||||||
|
|||||||
@@ -113,7 +113,6 @@ const PilotForm: React.FC<IPilotFormProps> = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
const onSubmit = async (data: unknown) => {
|
const onSubmit = async (data: unknown) => {
|
||||||
console.log(data)
|
|
||||||
try {
|
try {
|
||||||
setIsLoading(true);
|
setIsLoading(true);
|
||||||
|
|
||||||
@@ -167,7 +166,7 @@ const PilotForm: React.FC<IPilotFormProps> = ({
|
|||||||
|
|
||||||
pilot.certificates = JSON.parse(pilot.certificates);
|
pilot.certificates = JSON.parse(pilot.certificates);
|
||||||
pilot.endorsements = JSON.parse(pilot.endorsements)
|
pilot.endorsements = JSON.parse(pilot.endorsements)
|
||||||
console.log(pilot)
|
|
||||||
setSelectedPerson({
|
setSelectedPerson({
|
||||||
userPrincipalName: pilot.id,
|
userPrincipalName: pilot.id,
|
||||||
displayName: pilot.name
|
displayName: pilot.name
|
||||||
|
|||||||
Reference in New Issue
Block a user