Skip to content

Commit

Permalink
[MIG] hr_leave_custom_hour_interval: Migration to 17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Duy (Đỗ Anh) committed Jun 11, 2024
1 parent 1835cca commit 17ea0d2
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 12 deletions.
1 change: 1 addition & 0 deletions hr_leave_custom_hour_interval/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ Contributors

- Olga Marco
- Enric Tobella
- Duy Do Anh [email protected]

Maintainers
-----------
Expand Down
2 changes: 1 addition & 1 deletion hr_leave_custom_hour_interval/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"name": "Custom Hour Interval for Holidays",
"summary": """
Edit start and end of leaves using time intervals""",
"version": "15.0.1.0.0",
"version": "17.0.1.0.0",
"license": "AGPL-3",
"author": "Creu Blanca,Odoo Community Association (OCA)",
"website": "https://github.com/OCA/hr-holidays",
Expand Down
3 changes: 2 additions & 1 deletion hr_leave_custom_hour_interval/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
- Creu Blanca
- Creu Blanca
- Olga Marco
- Enric Tobella
- Duy Do Anh <[email protected]>
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,7 @@ <h2><a class="toc-backref" href="#toc-entry-5">Contributors</a></h2>
<li>Creu Blanca<ul>
<li>Olga Marco</li>
<li>Enric Tobella</li>
<li>Duy Do Anh <a class="reference external" href="mailto:duyda&#64;trobz.com">duyda&#64;trobz.com</a></li>
</ul>
</li>
</ul>
Expand Down
16 changes: 6 additions & 10 deletions hr_leave_custom_hour_interval/views/hr_leave.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,30 +9,26 @@
<field name="arch" type="xml">
<field name="request_hour_from" position="attributes">
<attribute name="invisible">1</attribute>
<attribute name="attrs">{}</attribute>
</field>
<field name="request_hour_from" position="after">
<field
name="request_time_hour_from"
widget="float_time"
attrs="{
'readonly': [('state', '=', 'validate')],
'required': [('request_unit_hours', '=', True)],
'invisible': [('request_unit_hours', '=', False)]}"
readonly="state == 'validate'"
required="request_unit_hours"
invisible="not request_unit_hours"
/>
</field>
<field name="request_hour_to" position="attributes">
<attribute name="invisible">1</attribute>
<attribute name="attrs">{}</attribute>
</field>
<field name="request_hour_to" position="after">
<field
name="request_time_hour_to"
widget="float_time"
attrs="{
'readonly': [('state', '=', 'validate')],
'required': [('request_unit_hours', '=', True)],
'invisible': [('request_unit_hours', '=', False)]}"
readonly="state == 'validate'"
required="request_unit_hours"
invisible="not request_unit_hours"
/>
</field>
</field>
Expand Down

0 comments on commit 17ea0d2

Please sign in to comment.