Añadidos módulos de OCA/e-commerce para la tienda online
This commit is contained in:
parent
10bfdb5a49
commit
c14ed5b4ef
99 changed files with 5359 additions and 0 deletions
17
website_sale_stock_available/models/product_template.py
Normal file
17
website_sale_stock_available/models/product_template.py
Normal file
|
@ -0,0 +1,17 @@
|
|||
# Copyright 2020 Tecnativa - Ernesto Tejeda
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from odoo import models, api
|
||||
|
||||
|
||||
class ProductTemplate(models.Model):
|
||||
_inherit = 'product.template'
|
||||
|
||||
@api.multi
|
||||
def _get_combination_info(self, combination=False, product_id=False,
|
||||
add_qty=1, pricelist=False,
|
||||
parent_combination=False, only_template=False):
|
||||
template = self.with_context(website_sale_stock_available=True)
|
||||
return super(ProductTemplate, template)._get_combination_info(
|
||||
combination, product_id, add_qty, pricelist, parent_combination,
|
||||
only_template)
|
Loading…
Add table
Add a link
Reference in a new issue