[FIX] hr_timesheet: display subtask hours in project sharing form view

Before this commit, the portal user cannot see the subtask planned hours
because the portal user has not the group implied by the res config
settings of Project App.

This commit removes the check of this group for project sharing feature
to only use the `allow_subtasks` field.

task-2633229

closes #77156

X-original-commit: 466ac140587811f1ca5c8a5f3960a40710ac635d
This commit is contained in:
Xavier BOL (xbo)
2021-11-05 17:14:30 +01:00
parent 5eddca2ace
commit 6e53c8e1d5
@@ -25,11 +25,11 @@
<label for="planned_hours" string="Initially Planned Days" attrs="{'invisible': [('encode_uom_in_days', '=', False)]}"/>
</div>
<field name="planned_hours" widget="timesheet_uom_no_toggle" nolabel="1"/>
<div class="o_td_label" groups="project.group_subtask_project" attrs="{'invisible': ['|', ('allow_subtasks', '=', False), ('subtask_count', '=', 0)]}">
<div class="o_td_label" attrs="{'invisible': ['|', ('allow_subtasks', '=', False), ('subtask_count', '=', 0)]}">
<label for="subtask_planned_hours" string="Sub-tasks Planned Hours" attrs="{'invisible': [('encode_uom_in_days', '=', True)]}"/>
<label for="subtask_planned_hours" string="Sub-tasks Planned Days" attrs="{'invisible': [('encode_uom_in_days', '=', False)]}"/>
</div>
<field name="subtask_planned_hours" widget="timesheet_uom_no_toggle" nolabel="1" groups="project.group_subtask_project" attrs="{'invisible': ['|', ('allow_subtasks', '=', False), ('subtask_count', '=', 0)]}"/>
<field name="subtask_planned_hours" widget="timesheet_uom_no_toggle" nolabel="1" attrs="{'invisible': ['|', ('allow_subtasks', '=', False), ('subtask_count', '=', 0)]}"/>
</group>
<group>
<field name="progress" widget="progressbar"/>