|
@@ -275,6 +275,8 @@ const StaffUtilization: React.FC<Props> = ({ abilities, staff }) => { |
|
|
const [totalLeaveHours, setTotalLeaveHours]: any = React.useState('NA'); |
|
|
const [totalLeaveHours, setTotalLeaveHours]: any = React.useState('NA'); |
|
|
const [currentPage, setCurrentPage] = useState(1); |
|
|
const [currentPage, setCurrentPage] = useState(1); |
|
|
const recordsPerPage = 10; |
|
|
const recordsPerPage = 10; |
|
|
|
|
|
const [datePickerToLabel, setDatePickerToLabel] = React.useState("To"); |
|
|
|
|
|
const [datePickerToLabel2, setDatePickerToLabel2] = React.useState("To"); |
|
|
|
|
|
|
|
|
const fetchComboData = async () => { |
|
|
const fetchComboData = async () => { |
|
|
const staffComboList = [] |
|
|
const staffComboList = [] |
|
@@ -1398,6 +1400,12 @@ const StaffUtilization: React.FC<Props> = ({ abilities, staff }) => { |
|
|
setTeamManhoursTeamId(selectedOption.value); |
|
|
setTeamManhoursTeamId(selectedOption.value); |
|
|
} |
|
|
} |
|
|
}} |
|
|
}} |
|
|
|
|
|
onMenuOpen={() => { |
|
|
|
|
|
setDatePickerToLabel("") |
|
|
|
|
|
}} |
|
|
|
|
|
onMenuClose={() => { |
|
|
|
|
|
setDatePickerToLabel("To") |
|
|
|
|
|
}} |
|
|
/> |
|
|
/> |
|
|
</div> |
|
|
</div> |
|
|
</div>} |
|
|
</div>} |
|
@@ -1449,7 +1457,7 @@ const StaffUtilization: React.FC<Props> = ({ abilities, staff }) => { |
|
|
selectMonthlyPeriodTo(newValue) |
|
|
selectMonthlyPeriodTo(newValue) |
|
|
} |
|
|
} |
|
|
defaultValue={totalManHoursMonthlyToValue} |
|
|
defaultValue={totalManHoursMonthlyToValue} |
|
|
label={"To"} |
|
|
|
|
|
|
|
|
label={datePickerToLabel} |
|
|
views={["month", "year"]} |
|
|
views={["month", "year"]} |
|
|
/> |
|
|
/> |
|
|
</LocalizationProvider> |
|
|
</LocalizationProvider> |
|
@@ -1522,7 +1530,6 @@ const StaffUtilization: React.FC<Props> = ({ abilities, staff }) => { |
|
|
)} |
|
|
)} |
|
|
</div> |
|
|
</div> |
|
|
<div className="inline-block w-fit mt-2"> |
|
|
<div className="inline-block w-fit mt-2"> |
|
|
<div className="inline-block mt-2 ml-6"> |
|
|
|
|
|
{abilityViewDashboardAll && |
|
|
{abilityViewDashboardAll && |
|
|
<div className="inline-block"> |
|
|
<div className="inline-block"> |
|
|
<div className="inline-block ml-6"> |
|
|
<div className="inline-block ml-6"> |
|
@@ -1542,9 +1549,16 @@ const StaffUtilization: React.FC<Props> = ({ abilities, staff }) => { |
|
|
setStaffGradeTeamId(selectedOption.value); |
|
|
setStaffGradeTeamId(selectedOption.value); |
|
|
} |
|
|
} |
|
|
}} |
|
|
}} |
|
|
|
|
|
onMenuOpen={() => { |
|
|
|
|
|
setDatePickerToLabel2("") |
|
|
|
|
|
}} |
|
|
|
|
|
onMenuClose={() => { |
|
|
|
|
|
setDatePickerToLabel2("To") |
|
|
|
|
|
}} |
|
|
/> |
|
|
/> |
|
|
</div> |
|
|
</div> |
|
|
</div>} |
|
|
</div>} |
|
|
|
|
|
<div className="ml-6 mt-2" style={{ verticalAlign: "top" }}> |
|
|
{staffGradeManhoursSpentSelect === "Weekly" && ( |
|
|
{staffGradeManhoursSpentSelect === "Weekly" && ( |
|
|
<LocalizationProvider dateAdapter={AdapterDayjs}> |
|
|
<LocalizationProvider dateAdapter={AdapterDayjs}> |
|
|
<DatePicker |
|
|
<DatePicker |
|
@@ -1572,6 +1586,7 @@ const StaffUtilization: React.FC<Props> = ({ abilities, staff }) => { |
|
|
</LocalizationProvider> |
|
|
</LocalizationProvider> |
|
|
)} |
|
|
)} |
|
|
{staffGradeManhoursSpentSelect === "Monthly" && ( |
|
|
{staffGradeManhoursSpentSelect === "Monthly" && ( |
|
|
|
|
|
|
|
|
<LocalizationProvider dateAdapter={AdapterDayjs}> |
|
|
<LocalizationProvider dateAdapter={AdapterDayjs}> |
|
|
<DatePicker |
|
|
<DatePicker |
|
|
className="w-44 h-10 align-top" |
|
|
className="w-44 h-10 align-top" |
|
@@ -1592,7 +1607,7 @@ const StaffUtilization: React.FC<Props> = ({ abilities, staff }) => { |
|
|
defaultValue={ |
|
|
defaultValue={ |
|
|
totalManHoursByStaffGradeMonthlyToValue |
|
|
totalManHoursByStaffGradeMonthlyToValue |
|
|
} |
|
|
} |
|
|
label={"To"} |
|
|
|
|
|
|
|
|
label={datePickerToLabel2} |
|
|
views={["month", "year"]} |
|
|
views={["month", "year"]} |
|
|
/> |
|
|
/> |
|
|
</LocalizationProvider> |
|
|
</LocalizationProvider> |
|
|