Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ADD] l10n_ar_loyalty: Nuevo modelo para productos de bonificacion
Task: 32083
- Loading branch information
Showing
4 changed files
with
34 additions
and
0 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 |
---|---|---|
@@ -0,0 +1 @@ | ||
from . import models |
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,18 @@ | ||
{ | ||
'name': 'l10n_ar Loyalty', | ||
'version': "16.0.1.0.0", | ||
'description': '', | ||
'author': 'ADHOC SA', | ||
'depends': [ | ||
'l10n_ar', | ||
'loyalty', | ||
], | ||
'data': [ | ||
], | ||
'demo': [ | ||
], | ||
'installable': True, | ||
'assets': { | ||
}, | ||
'license': 'LGPL-3', | ||
} |
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 @@ | ||
from . import loyalty_reward |
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,14 @@ | ||
from odoo import models | ||
|
||
|
||
class LoyaltyReward(models.Model): | ||
_inherit = 'loyalty.reward' | ||
|
||
def _get_discount_product_values(self): | ||
res = super()._get_discount_product_values() | ||
for values in res: | ||
values.update({ | ||
'uom_id' : self.env.ref('l10n_ar.product_uom_afip_bo').id, | ||
'uom_po_id' : self.env.ref('l10n_ar.product_uom_afip_bo').id | ||
}) | ||
return res |