mirror of
https://github.com/OCA/web.git
synced 2025-02-22 13:21:25 +02:00
[IMP] do not call search_read if no fields are set
This commit is contained in:
@@ -157,7 +157,8 @@ class TileTile(models.Model):
|
||||
return
|
||||
fields = [f.name for f in [
|
||||
self.primary_field_id, self.secondary_field_id] if f]
|
||||
read_vals = model.search_read(eval(domain, eval_context), fields)
|
||||
read_vals = fields and\
|
||||
model.search_read(eval(domain, eval_context), fields) or []
|
||||
for f in ['primary_', 'secondary_']:
|
||||
f_function = f+'function'
|
||||
f_field_id = f+'field_id'
|
||||
|
||||
Reference in New Issue
Block a user