Skip to content

Commit fc54eba

Browse files
committed
[ADD] Time Off - Time off types
closes #17985 X-original-commit: 8710c1f Signed-off-by: Lara Martini (larm) <larm@odoo.com>
1 parent 51af3bf commit fc54eba

14 files changed

Lines changed: 217 additions & 211 deletions

content/applications/hr/attendances.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,7 @@ when extra time is counted and what time is not logged.
144144
employee when they check out with a kiosk, or when a user checks out in the database.
145145

146146
.. note::
147-
Approved extra hours can be :ref:`deducted from an approved time off request
148-
<time_off/deduct-extra-hours>`.
147+
Approved extra hours can be deducted from an approved time off request.
149148

150149
.. seealso::
151150
- :doc:`attendances/check_in_check_out`

content/applications/hr/employees.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ Extra time off allocation
131131
-------------------------
132132

133133
During salary package negotiations, enable the checkbox in this section if additional time off
134-
requests are allowed. When enabled, select the :ref:`Time Off Type <time_off/time-off-types>`
134+
requests are allowed. When enabled, select the :doc:`Time Off Type <time_off/time_off_types>`
135135
created for the additional days using the drop-down menu.
136136

137137
The default available options are :guilabel:`Paid Time Off`, :guilabel:`Compensatory Days`, and

content/applications/hr/payroll/payroll_localizations/india.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ Sandwich leave
268268

269269
A *sandwich Leave* is a time off policy where weekends and public holidays falling between two applied
270270
leave days are also counted as time off.
271-
To enable this on a :ref:`time off types <time_off/time-off-types>` navigate to
271+
To enable this on a :doc:`time off type <../../time_off/time_off_types>` navigate to
272272
:menuselection:`Time Off app --> Configuration --> Time Off Types`, and click the desired
273273
time off type to enable this feature on. Tick the checkbox next to :guilabel:`Sandwich Leave`
274274
in the :guilabel:`Configuration` section of the :guilabel:`Time Off Type` form.
@@ -290,7 +290,7 @@ on these defined dates.
290290
If an employee attempts to request leave on any other date, a validation
291291
error will be raised.
292292

293-
To enable this on a :ref:`time off types <time_off/time-off-types>` navigate to
293+
To enable this on a :doc:`time off type <../../time_off/time_off_types>` navigate to
294294
:menuselection:`Time Off app --> Configuration --> Time Off Types`, and create a new time off type or
295295
open an existing one, Tick the checkbox next to :guilabel:`Limited to Optional Holiday` in the
296296
:guilabel:`Configuration` section of the :guilabel:`Time Off Type` form.

content/applications/hr/payroll/payroll_localizations/saudi_arabia.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -212,8 +212,9 @@ the drop-down space beneath the :guilabel:`Establishment Bank Account` field, an
212212
Next, enter the company's :guilabel:`MoL Establishment ID`. This ID number is provided by Saudi
213213
Arabia's Ministry of Labor.
214214

215-
Finally, select the :ref:`time off type <time_off/time-off-types>` that is used to calculate the
216-
:guilabel:`Annual Leave Balance` set in the :ref:`employee's profile <payroll/saudi_payroll_info>`.
215+
Finally, select the :doc:`time off yype <../../time_off/time_off_types>` that is used to calculate
216+
the :guilabel:`Annual Leave Balance` set in the :ref:`employee's profile
217+
<payroll/saudi_payroll_info>`.
217218

218219
Salary structures & structure types
219220
-----------------------------------

content/applications/hr/payroll/payroll_localizations/united_arab_emirates.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -206,8 +206,8 @@ Annual remaining leave balance rules
206206
Annual remaining leave balance rules are used for calculating the amount to be paid to or taken from
207207
the employee based on the number of leave days deserved by the employee during the current year.
208208

209-
The annual leave :ref:`time off type <time_off/time-off-types>` is specified using the :guilabel:`Is
210-
Annual Leave` checkbox.
209+
The annual leave :doc:`time off type <../../time_off/time_off_types>` is specified using the
210+
:guilabel:`Is Annual Leave` checkbox.
211211

212212
If enabled, the rule calculates the amount of leave days deserved by the employee up to the current
213213
date and subtracts the number of annual leave days taken, and if the result is positive, this means
@@ -226,8 +226,8 @@ There are **3 cases** for the employee to have:
226226
eligible for **15 days** of this type of leave per calendar year.
227227

228228
.. tip::
229-
The SLI is not mandatory in Odoo but can be done from the setup of the :ref:`time off types
230-
<time_off/time-off-types>`.
229+
The SLI is not mandatory in Odoo but can be done from the setup of the :doc:`time off types
230+
<../../time_off/time_off_types>`.
231231

232232
#. **50% paid sick leave:** Same as the fully paid one, but the employees are eligible for **30
233233
days** from this leave type. These 30 days are counted after the first **15** fully paid days.

content/applications/hr/time_off.rst

Lines changed: 3 additions & 195 deletions
Original file line numberDiff line numberDiff line change
@@ -36,200 +36,6 @@ In order to allocate time off to employees, and for employees to request and use
3636
various time off types must be configured first, then allocated to employees (if allocation is
3737
required).
3838

39-
.. _time_off/time-off-types:
40-
41-
Time off types
42-
--------------
43-
44-
To view the currently configured time off types, navigate to :menuselection:`Time Off app -->
45-
Configuration --> Time Off Types`. The time off types are presented in a list view.
46-
47-
The **Time Off** app comes with four preconfigured time off types: :guilabel:`Paid Time Off`,
48-
:guilabel:`Sick Time Off`, :guilabel:`Unpaid`, :guilabel:`Compensatory Days`, and :guilabel:`Extra
49-
Hours`. These can be modified to suit business needs, or used as-is.
50-
51-
Create time off type
52-
~~~~~~~~~~~~~~~~~~~~
53-
54-
To create a new time off type, navigate to :menuselection:`Time Off app --> Configuration --> Time
55-
Off Types`. From here, click the :guilabel:`New` button to reveal a blank time off type form.
56-
57-
Enter the name for the particular type of time off in the blank line at the top of the form, such as
58-
`Vacation` or `Bereavement`. Then, enter the following information on the form.
59-
60-
.. note::
61-
The only **required** fields on the time off type form are the name of the :guilabel:`Time Off
62-
Type`, the :guilabel:`Take Time Off In`, and the :guilabel:`Kind of Time Off`. In addition, the
63-
:guilabel:`Time Off Requests` and :guilabel:`Allocation Requests` sections **must** be
64-
configured.
65-
66-
.. _time_off/time-off-requests:
67-
68-
Time off requests section
69-
*************************
70-
71-
This section determines how approvals are handled for time off requests for this time off type.
72-
73-
- :guilabel:`Approval`: select what specific kind of approval is required for the time off type. The
74-
options are:
75-
76-
- :guilabel:`No Validation`: No approvals are required when requesting this type of time off. The
77-
time off request is automatically approved.
78-
- :guilabel:`By Time Off Officer`: Only the specified :ref:`Time Off Officer
79-
<time_off/time-off-officer>`, set on this form in the :guilabel:`Notified Time Off Officer`
80-
field, is required to approve the time off request. This option is selected, by default.
81-
- :guilabel:`By Employee's Approver`: Only the employee's specified approver for time off, which
82-
is set on the *Work Information* tab on the :ref:`employee's form <employees/work-info-tab>`, is
83-
required to approve the time off request.
84-
- :guilabel:`By Employee's Approver and Time Off Officer`: Both the employee's :ref:`specified
85-
time off approver <employees/work-info-tab>` and the :ref:`Time Off Officer
86-
<time_off/time-off-officer>` are required to approve the time off request.
87-
88-
Allocation requests section
89-
***************************
90-
91-
This section determines how allocation requests are handled for this time off type.
92-
93-
- :guilabel:`Requires allocation`: If the time off must be allocated to employees, select
94-
:guilabel:`Yes`. If the time off can be requested without time off being previously allocated,
95-
select :guilabel:`No Limit`. If :guilabel:`No Limit` is selected, the following options do not
96-
appear on the form.
97-
- :guilabel:`Employee Requests`: Select :guilabel:`Extra Days Requests Allowed` if the employee is
98-
able to request more time off than was allocated.
99-
100-
If employees should **not** be able to make requests for more time off than what was allocated,
101-
select the :guilabel:`Not Allowed` option.
102-
103-
.. example::
104-
Ten days are allocated to the employee for this particular type of time off, and the
105-
:guilabel:`Extra Days Requests Allowed` option is enabled. The employee wants to take a
106-
vacation for twelve days. They may submit a request for two additional days, since the
107-
:guilabel:`Extra Days Requests Allowed` option is enabled.
108-
109-
.. important::
110-
It is important to note that requesting additional time off does **not** guarantee that time
111-
off is granted.
112-
113-
- :guilabel:`Approval`: Select the type of approvals required for the allocation of this particular
114-
time off type.
115-
116-
- :guilabel:`No Validation`: No approvals are required when requesting additional allocations for
117-
the time off type. The allocation request is automatically approved.
118-
- :guilabel:`By Time Off Officer`: Only the specified :ref:`Time Off Officer
119-
<time_off/time-off-officer>`, set on this form in the :guilabel:`Notified Time Off Officer`
120-
field, is required to approve the allocation request. This option is selected, by default.
121-
- :guilabel:`By Employee's Approver`: Only the employee's specified approver for time off, which
122-
is set on the *Work Information* tab on the :ref:`employee's form <employees/work-info-tab>`, is
123-
required to approve the allocation request.
124-
- :guilabel:`By Employee's Approver and Time Off Officer`: Both the employee's :ref:`specified
125-
time off approver <employees/work-info-tab>` and the :ref:`Time Off Officer
126-
<time_off/time-off-officer>` are required to approve the allocation request.
127-
128-
Configuration section
129-
*********************
130-
131-
This section determines all other details regarding the time off type, aside from approvals and
132-
allocations. This includes how the time off must be taken (hours, half days, or days), if the time
133-
off is visible to other users, and how the time off affects the **Payroll** app.
134-
135-
.. _`time_off/time-off-officer`:
136-
137-
- :guilabel:`Notified Time Off Officer`: Select the user who is notified and responsible for
138-
approving requests and allocations for this specific type of time off.
139-
- :guilabel:`Take Time Off in`: Select the format the time off is requested in from the drop-down
140-
menu. The options are:
141-
142-
- :guilabel:`Day`: if time off can only be requested in full day increments (8 hours).
143-
- :guilabel:`Half Day`: if time off can only be requested in half day increments (4 hours).
144-
- :guilabel:`Hours`: if the time off can be taken in hourly increments.
145-
146-
.. _`time_off/deduct-extra-hours`:
147-
148-
- :guilabel:`Deduct Extra Hours`: Enable this option if the time off request should factor in any
149-
extra time accrued by the employee.
150-
151-
.. example::
152-
If an employee works two extra hours for the week, and requests five hours of time off, the
153-
request would be for three hours, since the two extra worked hours are used first, and deducted
154-
from the request.
155-
156-
- :guilabel:`Public Holiday Included`: Enable this option if public holidays should be included in
157-
time off requests.
158-
159-
.. example::
160-
An employee in the United States requests time off for the week of July 4th, for a total of
161-
five days. Since the 4th of July is a holiday in the United States, the time off request is
162-
automatically modified to use four vacation days and one public holiday, instead of five
163-
vacation days. That is because the holiday is included, and the user does not need to use their
164-
own vacation time for a public holiday.
165-
166-
This option reduces extra work for users, enabling them to make only one time off request for
167-
the entire week, instead of making two separate requests, one for the days *before* the
168-
holiday, and another one for the days *after* the holiday.
169-
170-
- :guilabel:`Allow To Attach Supporting Document`: Enable this option to allow the employee to
171-
attach documents to the time off request. This is useful in situations where documentation is
172-
required, such as long-term medical leave.
173-
- :guilabel:`Kind of Time Off`: From the drop-down menu, select the type of time off, either
174-
:guilabel:`Worked Time` or :guilabel:`Absence`. :guilabel:`Worked Time` indicates the time off
175-
taken counts toward worked time for any type of accrual the employee is working towards, whereas
176-
:guilabel:`Absence` does not count toward any type of accrual.
177-
- :guilabel:`Company`: If multiple companies are created in the database, and this time off type
178-
only applies to one company, select the company from the drop-down menu. If this field is left
179-
blank, the time off type applies to all companies in the database. This field **only** appears in
180-
a multi-company database.
181-
182-
Negative cap section
183-
********************
184-
185-
Enable the :guilabel:`Allow Negative Cap` option if employees are able to request more time off than
186-
they currently have, allowing a negative balance. If enabled, an :guilabel:`Maximum Excess Amount`
187-
field appears. In this field, enter the maximum amount of negative time allowed, in days.
188-
189-
.. example::
190-
Sara currently has three days of the time off type `Vacation`. She is planning a trip that
191-
requires five days of time off.
192-
193-
The `Vacation` time off type has the :guilabel:`Allow Negative Cap` option enabled, and the
194-
:guilabel:`Maximum Excess Amount` is set to five.
195-
196-
These settings allow Sara to submit a request for five days of the `Vacation` time off type. If
197-
approved, her `Vacation` time off balance will be negative two (-2) days.
198-
199-
.. image:: time_off/time-off-type-form-top.png
200-
:alt: The top half of the time off type form, with all the information filled out for sick time
201-
off.
202-
203-
Payroll section
204-
***************
205-
206-
If the time off type should create :doc:`../hr/payroll/work_entries` in the **Payroll** app, select
207-
the :guilabel:`Work Entry Type` from the drop-down list.
208-
209-
Timesheets section
210-
******************
211-
212-
.. note::
213-
The :guilabel:`Timesheets` section only appears if the user is in developer mode. Refer to the
214-
:ref:`developer-mode` document for details on how to access the developer mode.
215-
216-
When an employee takes time off, and is also using timesheets, Odoo creates entries in the
217-
**Timesheets** app for the time off. This section defines how they are entered.
218-
219-
- :guilabel:`Project`: Select the project the time off type entries appear in.
220-
- :guilabel:`Task`: Select the task that appears in the timesheet for this time off type. The
221-
default options are: :guilabel:`Time Off`, :guilabel:`Meeting`, or :guilabel:`Training`.
222-
223-
Display option section
224-
**********************
225-
226-
- :guilabel:`Color`: Select a color to be used in the **Time Off** app dashboard.
227-
- :guilabel:`Cover Image`: Select an icon to be used in the **Time Off** app dashboard.
228-
229-
.. image:: time_off/time-off-type-form-bottom.png
230-
:alt: The lower half of the time off type form, with all the information filled out for sick time
231-
off.
232-
23339
.. _time_off/accrual-plans:
23440

23541
Accrual plans
@@ -278,7 +84,7 @@ Enter the following information on the form:
27884
The employee works standard 40-hour weeks. According to the accrual plan, they should earn four
27985
vacation days per month.
28086

281-
The employee takes five days off using a :ref:`time off type <time_off/time-off-types>` with
87+
The employee takes five days off using a :doc:`time off type <time_off/time_off_types>` with
28288
the :guilabel:`Kind of Time Off` set as an :guilabel:`Absence`. Because the plan grants
28389
vacation only for worked time, those five days do not count toward accrual.
28490

@@ -569,6 +375,7 @@ the time off request in a modal, click the :guilabel:`View` button.
569375
:alt: Overview of the user's team, with time off requests shown.
570376

571377
.. seealso::
378+
- :doc:`time_off/time_off_types`
572379
- :doc:`time_off/allocations`
573380
- :doc:`time_off/request_time_off`
574381
- :doc:`time_off/my_time`
@@ -578,6 +385,7 @@ the time off request in a modal, click the :guilabel:`View` button.
578385
.. toctree::
579386
:titlesonly:
580387

388+
time_off/time_off_types
581389
time_off/allocations
582390
time_off/request_time_off
583391
time_off/my_time

content/applications/hr/time_off/allocations.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Allocations
55
Allocations are amounts of time off given to employees, either granted immediately or earned as the
66
employee works, through an accrual plan.
77

8-
Once :ref:`time off types <time_off/time-off-types>` and :ref:`accrual plans
8+
Once :doc:`time off type <../time_off/time_off_types>` and :ref:`accrual plans
99
<time_off/accrual-plans>` have been configured, the next step is to *allocate*, or give, time off to
1010
employees.
1111

@@ -56,7 +56,7 @@ information:
5656
field is labeled :guilabel:`Run until`.
5757
- :guilabel:`Allocation`: Enter the amount of time that is being allocated to the employees. This
5858
field displays the time in either :guilabel:`Hours` or :guilabel:`Days`, depending on how the
59-
selected :ref:`Time Off Type <time_off/time-off-types>` is configured.
59+
selected :doc:`Time Off Type <../time_off/time_off_types>` is configured.
6060
- :guilabel:`Employee`: Using the drop-down menu, select the employee being allocated the time off.
6161
- :guilabel:`Add a reason...`: If any description or note is necessary to explain the time off
6262
allocation, enter it in this field at the bottom of the form.

content/applications/hr/time_off/request_time_off.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,11 @@ Enter the following information on the :guilabel:`New Time Off` request form:
6363
- :guilabel:`Requested (Days/Hours)`: This field updates automatically once the :guilabel:`Date`
6464
section is completed. If the :guilabel:`Date` section is modified, this section automatically
6565
updates to reflect the total time off requested. This field is in either hours or days, depending
66-
on how the selected :ref:`Time Off Type <time_off/time-off-types>` is configured.
66+
on how the selected :doc:`Time Off Type <../time_off/time_off_types>` is configured.
6767
- :guilabel:`Description`: Enter a description for the time off request. This should include any
6868
details that managers and approvers may need to approve the request.
69-
- :guilabel:`Supporting Document`: This field **only** appears if the :ref:`Time Off Type
70-
<time_off/time-off-types>` selected allows for the attachment of documents. Click the
69+
- :guilabel:`Supporting Document`: This field **only** appears if the :doc:`Time Off Type
70+
<../time_off/time_off_types>` selected allows for the attachment of documents. Click the
7171
:icon:`fa-paperclip` :guilabel:`Attach File` button, and a file explorer window appears.
7272

7373
Navigate to the desired files that should be attached, select them, then click The
-18.2 KB
Binary file not shown.
-26.9 KB
Binary file not shown.

0 commit comments

Comments
 (0)