Skip to content

Commit 8cc282a

Browse files
Merge pull request #5229 from OneCommunityGlobal/Diya_Fix_UnassignTasks
Diya fix(permission): Unassign Tasks from Members
2 parents dc19298 + a61cff8 commit 8cc282a

2 files changed

Lines changed: 2 additions & 7 deletions

File tree

src/components/PermissionsManagement/Permissions.json

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -325,11 +325,6 @@
325325
"label": "View and Interact with Task \"X\" on Dashboards",
326326
"key": "canDeleteTask",
327327
"description": "Gives the user permission to DELETE tasks from the Management Dashboard showing all their team members."
328-
},
329-
{
330-
"label": "Unassign Team Members from Tasks",
331-
"key": "deleteDashboardTask",
332-
"description": "Gives the user permission to UNASSIGN tasks from only their TEAM members through the Dashboard -> task -> red X."
333328
}
334329
]
335330
}

src/components/TeamMemberTasks/TeamMemberTask.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ const TeamMemberTask = React.memo(
154154
const canSeeReports =
155155
rolesAllowedToResolveTasks.includes(userRole) || dispatch(hasPermission('getReports'));
156156
const canUpdateTask = dispatch(hasPermission('updateTask'));
157-
const canDeleteTask = dispatch(hasPermission('canDeleteTask'));
157+
const canUnassignTask = dispatch(hasPermission('removeUserFromTask'));
158158
const numTasksToShow = isTruncated ? NUM_TASKS_SHOW_TRUNCATE : activeTasks.length;
159159

160160
const colorsObjs = {
@@ -625,7 +625,7 @@ const TeamMemberTask = React.memo(
625625
/>
626626
)}
627627

628-
{(canUpdateTask || canDeleteTask) && (
628+
{canUnassignTask && (
629629
<FontAwesomeIcon
630630
className={styles['team-member-task-remove']}
631631
icon={faTimesCircle}

0 commit comments

Comments
 (0)