Skip to content
Snippets Groups Projects
Commit 58e4a584 authored by Jérome Maes's avatar Jérome Maes
Browse files

[MERGE] hr_timesheet: log timesheet in any time UoM

Since uom management has been extract in a separated module, we
can now add the possibility to use it without product.

This commit brings the ability to record the timesheets in
an different UoM than 'Hours'. The user can now set an encoding
UoM for its timesheet on the company. This will display the
timesheet field `unit_amount` with a different widget.
For instance, timesheeting in hours will still use
the traditionnal float_time widget, when timesheeting in 'Days'
will displayed a toggle button with a range of defined possible
values.
The widget used by UoM is customizable on the UoM. The `unit_amount`
field should now be decorated with the 'timesheet_uom' widget.
This one will bind the correct widget (float_time, float_toggle, ...).
If the encoding UoM has no widget associated, the fallback will
be 'float_factor', using the uoM converstion factor.

Everything will still be stored in the database in 'Hours' (the
UoM set on the `project_mode_time_id` field on the company).

For more details, please have a look at the subcommits.

Task #39079
Closes #24893
parents 8db463d1 cce8e002
No related branches found
No related tags found
Loading
Showing
with 251 additions and 62 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment