From 44a7f8f68ac223e5da2c669ed6507f38fe039c5f Mon Sep 17 00:00:00 2001 From: Peter Rotich <peter@enhancesoft.com> Date: Wed, 22 Aug 2018 02:14:12 +0000 Subject: [PATCH] Tasks: Task visibility Allow ticket assignee to see tasks associated with the ticket. --- include/staff/tasks.inc.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/staff/tasks.inc.php b/include/staff/tasks.inc.php index 712a795af..a83f1cace 100644 --- a/include/staff/tasks.inc.php +++ b/include/staff/tasks.inc.php @@ -130,6 +130,11 @@ if ($filters) $visibility = Q::any( new Q(array('flags__hasbit' => TaskModel::ISOPEN, 'staff_id' => $thisstaff->getId())) ); +// -- Task for tickets assigned to me +$visibility->add(new Q( array( + 'ticket__staff_id' => $thisstaff->getId(), + 'ticket__status__state' => 'open')) + ); // -- Routed to a department of mine if (!$thisstaff->showAssignedOnly() && ($depts=$thisstaff->getDepts())) $visibility->add(new Q(array('dept_id__in' => $depts))); -- GitLab