diff options
| author | Helly kapatel <hpl@odoo.com> | 2020-03-13 09:41:47 +0000 |
|---|---|---|
| committer | Barad Mahendra <mba@openerp.com> | 2020-03-25 13:46:11 +0000 |
| commit | e4ebd3e6e3223df2c75ce26beb98b829b5442f7d (patch) | |
| tree | 4023a5126e73b010340a96649377827c9a1c126e /addons/hr_holidays/views | |
| parent | ad69cc13d3f4cdb3565b937b2331c7a7fd50c61d (diff) | |
[IMP] hr_holidays: show the initial duration while the accrual is selected
Purpose of the task is, when the accrual is selected, the field for
duration is hidden but the feature allows to use it.
So in this commit,when accrual is selected, display number of days
(duration) to provide an intial allocation while accrual is selected.
Also change label and tooltip according to allocation type.
closes odoo/odoo#48354
Taskid: 2199324
Closes: #47598
X-original-commit: 74df5cbaf37d3cc6da0b15efa9d7f4a4ec265ec5
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Diffstat (limited to 'addons/hr_holidays/views')
| -rw-r--r-- | addons/hr_holidays/views/hr_leave_allocation_views.xml | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/addons/hr_holidays/views/hr_leave_allocation_views.xml b/addons/hr_holidays/views/hr_leave_allocation_views.xml index 64a6db5c833..68212af9c7f 100644 --- a/addons/hr_holidays/views/hr_leave_allocation_views.xml +++ b/addons/hr_holidays/views/hr_leave_allocation_views.xml @@ -91,8 +91,11 @@ <field name="allocation_type" invisible="1" widget="radio"/> <field name="number_of_days" invisible="1"/> - <label for="number_of_days" string="Duration" attrs="{'invisible': [('allocation_type', '=', 'accrual')]}"/> - <div attrs="{'invisible': [('allocation_type', '=', 'accrual')]}"> + <div class="o_td_label"> + <label for="number_of_days" string="Duration" attrs="{'invisible': [('allocation_type', '=', 'accrual')]}"/> + <label for="number_of_days" string="Extra days" attrs="{'invisible': [('allocation_type', '!=', 'accrual')]}"/> + </div> + <div> <field name="number_of_days_display" class="oe_inline" nolabel="1" attrs="{'readonly': ['|', ('type_request_unit', '=', 'hour'), ('state', 'not in', ('draft', 'confirm'))], 'invisible': [('type_request_unit', '=', 'hour')]}"/> <field name="number_of_hours_display" class="oe_inline" nolabel="1" |
