-
-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[MIG] hr_holidays_credit: Migration to 15.0
- Loading branch information
1 parent
fe1ff30
commit f59764c
Showing
9 changed files
with
108 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -63,6 +63,8 @@ Contributors | |
* Watcharaporn Charamrum <[email protected]> | ||
* Tharathip Chaweewongphan <[email protected]> | ||
|
||
* Dhara Solanki <[email protected]> | ||
|
||
Maintainers | ||
~~~~~~~~~~~ | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ | |
|
||
from . import hr_leave_type | ||
from . import hr_leave | ||
from . import hr_leave_allocation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Copyright (C) 2018 Brainbean Apps (https://brainbeanapps.com) | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from odoo import fields, models | ||
from odoo.osv import expression | ||
|
||
|
||
class HolidaysAllocation(models.Model): | ||
_inherit = "hr.leave.allocation" | ||
|
||
def _domain_holiday_status_id(self): | ||
res = super(HolidaysAllocation, self)._domain_holiday_status_id() | ||
return expression.OR([[("allow_credit", "=", True)], res]) | ||
|
||
holiday_status_id = fields.Many2one( | ||
"hr.leave.type", domain=_domain_holiday_status_id | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,3 +6,5 @@ | |
|
||
* Watcharaporn Charamrum <[email protected]> | ||
* Tharathip Chaweewongphan <[email protected]> | ||
|
||
* Dhara Solanki <[email protected]> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters