|
@@ -13,12 +13,14 @@ interface Props { |
|
|
leaveTypes: LeaveType[]; |
|
|
leaveTypes: LeaveType[]; |
|
|
timesheetRecords: RecordTimesheetInput; |
|
|
timesheetRecords: RecordTimesheetInput; |
|
|
companyHolidays: HolidaysResult[]; |
|
|
companyHolidays: HolidaysResult[]; |
|
|
|
|
|
isSaturdayWorker: boolean; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
const LeaveTable: React.FC<Props> = ({ |
|
|
const LeaveTable: React.FC<Props> = ({ |
|
|
leaveTypes, |
|
|
leaveTypes, |
|
|
timesheetRecords, |
|
|
timesheetRecords, |
|
|
companyHolidays, |
|
|
companyHolidays, |
|
|
|
|
|
isSaturdayWorker |
|
|
}) => { |
|
|
}) => { |
|
|
const { watch } = useFormContext<RecordLeaveInput>(); |
|
|
const { watch } = useFormContext<RecordLeaveInput>(); |
|
|
const currentInput = watch(); |
|
|
const currentInput = watch(); |
|
@@ -32,6 +34,7 @@ const LeaveTable: React.FC<Props> = ({ |
|
|
timesheetEntries={timesheetRecords} |
|
|
timesheetEntries={timesheetRecords} |
|
|
EntryTableComponent={LeaveEntryTable} |
|
|
EntryTableComponent={LeaveEntryTable} |
|
|
entryTableProps={{ leaveTypes }} |
|
|
entryTableProps={{ leaveTypes }} |
|
|
|
|
|
isSaturdayWorker={isSaturdayWorker} |
|
|
/> |
|
|
/> |
|
|
); |
|
|
); |
|
|
}; |
|
|
}; |
|
|