[FIX] project: fixes 'view task' is display once the task is saved in portal

Steps to reproduce:
- Open project share any project which has task.
- My account > project > open that project you can see task .
- Open any task and add new sub-task you can see once the sub-task is saved
  'task view' button is displayed.

Issue:
- Sub-tasks notebook > add a line > 'view task' is displayed at the creation but
  is then hidden once the task is saved.

Solution:
- Correct the attrs and change the condition in able to invisible 'view task'
  once the sub-task is saved

task-3602610

closes odoo/odoo#160117

X-original-commit: cd6ed7f9fd2e0654cfb0672d7a9536dca21035cf
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
This commit is contained in:
lakhichand borse
2024-04-05 14:01:07 +00:00
committed by Prakash Prajapati
parent 89c9396cc3
commit dccca8fe8d
@@ -208,7 +208,7 @@
<field name="stage_id" domain="[('user_id', '=', False), ('project_ids', 'in', [project_id])]"/>
<button name="action_open_task" type="object" title="View Task" string="View Task" class="btn btn-link float-end"
context="{'form_view_ref': 'project.project_sharing_project_task_view_form', 'search_view_ref': 'project.project_sharing_project_task_view_search'}"
invisible="project_id or project_id != id"/>
invisible="project_id != context.get('active_id')"/>
</tree>
</field>
</page>