> > Bug (new)

client does not get updates on assigned tasks


Jun 15, 2006
2 hours ... 10 hours
Jun 15, 2006 / pixtur
Jan 5, 2009 / phsouzacruz

Attached files

No files uploaded
This problem is really tricky, because Project::getChanges() only checks for visible items but the visibility of tasks is also affected by assignments. So even if the client could see "assigned tasks" the query in Project::getChanges ignores it:

from db/class_project.inc.php

            "SELECT i.* from
                                    {$prefix}item i,
                                    {$prefix}projectperson upp
                    upp.person = {$auth->cur_user->id}
                AND upp.project = i.project

                AND ( i.pub_level >= upp.level_view
                      i.created_by = {$auth->cur_user->id}
            " . getOrderByString($order_by);

Maybe we could add some fragment of Task::getAll() to this...

from db/class_task.inc.php

                    AND i.id = tp.task
                           AND tp.person = $assigned_to_person
                           AND itp.id = tp.id
                           AND itp.state = 1
                                   AND (itp.pub_level >= upp.level_view
                                       itp.created_by = {$auth->cur_user->id}

... but that would cause other problems, because it ignores all other item-types. Another method might be to query all assigned task that are not catched in the first query and and them. But this exceeds my mySQL-knowledge.

Issue report

Not available
  1. create project
  2. create person client with profil client and notifictions ON
  3. add person client
  4. create task1 with pub-level "open"
  5. assign task1 to client
  6. Flush notifications for client

although task1 is visibile in client's assigned task list it is not listed in the notification mail.

No Comments