[MERGE] forward port branch saas-14 up to 98b10f98bb
This commit is contained in:
@@ -372,13 +372,13 @@ class Product(models.Model):
|
||||
return self.mapped('product_tmpl_id').action_view_routes()
|
||||
|
||||
@api.model
|
||||
def search(self, domain=None, *args, **kwargs):
|
||||
def search(self, args, offset=0, limit=None, order=None, count=False):
|
||||
# ONLY FOR 10.0 UP TO SAAS-15
|
||||
# ignore dummy fields used for search context²
|
||||
for index in range(len(domain or [])):
|
||||
if domain[index][0] in ('location_id', 'warehouse_id'):
|
||||
domain[index] = expression.TRUE_LEAF
|
||||
return super(Product, self).search(domain, *args, **kwargs)
|
||||
for index in range(len(args or [])):
|
||||
if args[index][0] in ('location_id', 'warehouse_id'):
|
||||
args[index] = expression.TRUE_LEAF
|
||||
return super(Product, self).search(args, offset=offset, limit=limit, order=order, count=count)
|
||||
|
||||
@api.multi
|
||||
def write(self, values):
|
||||
@@ -518,13 +518,13 @@ class ProductTemplate(models.Model):
|
||||
return self.mapped('product_variant_ids').onchange_tracking()
|
||||
|
||||
@api.model
|
||||
def search(self, domain=None, *args, **kwargs):
|
||||
def search(self, args, offset=0, limit=None, order=None, count=False):
|
||||
# ONLY FOR 10.0 UP TO SAAS-15
|
||||
# ignore dummy fields used for search context
|
||||
for index in range(len(domain or [])):
|
||||
if domain[index][0] in ('location_id', 'warehouse_id'):
|
||||
domain[index] = expression.TRUE_LEAF
|
||||
return super(ProductTemplate, self).search(domain, *args, **kwargs)
|
||||
for index in range(len(args or [])):
|
||||
if args[index][0] in ('location_id', 'warehouse_id'):
|
||||
args[index] = expression.TRUE_LEAF
|
||||
return super(ProductTemplate, self).search(args, offset=offset, limit=limit, order=order, count=count)
|
||||
|
||||
@api.multi
|
||||
def write(self, vals):
|
||||
|
||||
@@ -17,7 +17,7 @@ Rafael Blasco rafael.blasco@tecnativa.com https://github.com/rafaelbn
|
||||
Sergio Teruel sergio.teruel@tecnativa.com https://github.com/sergio-teruel
|
||||
Carlos Dauden carlos.dauden@tecnativa.com https://github.com/carlosdauden
|
||||
Jairo Llopis jairo.llopis@tecnativa.com https://github.com/yajo
|
||||
Vicent Cubells vicent.cubells@tecnativa.com https://github.com/cubells
|
||||
Luis Montalba luis.montalba@tecnativa.com https://github.com/luismontalba
|
||||
David Vidal david.vidal@tecnativa.com https://github.com/chienandalu
|
||||
Cristina Martín cristina.martin@tecnativa.com https://github.com/cristinamartinrod
|
||||
Cristina Martín cristina.martin@tecnativa.com https://github.com/cristinamartinrod (up to 2019-04-30)
|
||||
Ernesto Tejeda ernesto.tejeda@tecnativa.com https://github.com/ernestotejeda
|
||||
Alexandre Díaz alexandre.diaz@tecnativa.com https://github.com/Tardo
|
||||
|
||||
@@ -99,7 +99,7 @@ Extra conditional branching directives ``t-elif`` and ``t-else`` are also
|
||||
available::
|
||||
|
||||
<div>
|
||||
<p t-if="user.birthday == today()">Happy bithday!</p>
|
||||
<p t-if="user.birthday == today()">Happy birthday!</p>
|
||||
<p t-elif="user.login == 'root'">Welcome master!</p>
|
||||
<p t-else="">Welcome!</p>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user