Browse Source

[FIX] fix default value at creation of the computed field comparison_mode

pull/189/head
Sébastien BEAU 9 years ago
parent
commit
6c39d21273
  1. 3
      mis_builder/models/mis_builder.py

3
mis_builder/models/mis_builder.py

@ -1116,7 +1116,8 @@ class MisReportInstance(models.Model):
@api.depends('date_from')
def _compute_comparison_mode(self):
for instance in self:
instance.comparison_mode = not bool(instance.date_from)
instance.comparison_mode = bool(instance.period_ids) and\
not bool(instance.date_from)
@api.multi
def _inverse_comparison_mode(self):

Loading…
Cancel
Save