diff --git a/apps/mobile/app/components/Task/DetailsBlock/components/ManageAssignees.tsx b/apps/mobile/app/components/Task/DetailsBlock/components/ManageAssignees.tsx index d79f576c0..3a655faad 100644 --- a/apps/mobile/app/components/Task/DetailsBlock/components/ManageAssignees.tsx +++ b/apps/mobile/app/components/Task/DetailsBlock/components/ManageAssignees.tsx @@ -42,7 +42,10 @@ const ManageAssignees: React.FC = ({ memberList, task }) => { const assignedToTaskMembers = useMemo( () => memberList?.filter((member) => - member.employee ? task?.members.map((item) => item.userId).includes(member.employee?.userId) : false + member.employee + ? task?.members.map((item) => item.userId).includes(member.employee?.userId) && + member.employee?.isActive + : false ), [memberList, task?.members] ); @@ -50,7 +53,10 @@ const ManageAssignees: React.FC = ({ memberList, task }) => { const unassignedMembers = useMemo( () => memberList?.filter((member) => - member.employee ? !task?.members.map((item) => item.userId).includes(member.employee.userId) : false + member.employee + ? !task?.members.map((item) => item.userId).includes(member.employee.userId) && + member.employee?.isActive + : false ), [memberList, task?.members] ); diff --git a/apps/web/components/pages/task/details-section/blocks/task-main-info.tsx b/apps/web/components/pages/task/details-section/blocks/task-main-info.tsx index cc08ecc02..bc86add07 100644 --- a/apps/web/components/pages/task/details-section/blocks/task-main-info.tsx +++ b/apps/web/components/pages/task/details-section/blocks/task-main-info.tsx @@ -1,3 +1,4 @@ +/* eslint-disable no-mixed-spaces-and-tabs */ import { calculateRemainingDays, formatDateString } from '@app/helpers'; import { useOrganizationTeams, useSyncRef, useTeamMemberCard, useTeamTasks } from '@app/hooks'; import { ITeamTask, OT_Member } from '@app/interfaces'; @@ -217,7 +218,10 @@ const ManageMembersPopover = (memberList: OT_Member[], task: ITeamTask | null) = const unassignedMembers = useMemo( () => memberList.filter((member) => - member.employee ? !task?.members.map((item) => item.userId).includes(member.employee.userId) : false + member.employee + ? !task?.members.map((item) => item.userId).includes(member.employee.userId) && + member.employee?.isActive + : false ), [memberList, task?.members] ); @@ -225,7 +229,10 @@ const ManageMembersPopover = (memberList: OT_Member[], task: ITeamTask | null) = const assignedTaskMembers = useMemo( () => memberList.filter((member) => - member.employee ? task?.members.map((item) => item.userId).includes(member.employee?.userId) : false + member.employee + ? task?.members.map((item) => item.userId).includes(member.employee?.userId) && + member.employee?.isActive + : false ), [memberList, task?.members] );