[FIX] project: history cumulative bad compute inherit

When we were trying to delete a stage in project where there were
some tasks, an error was raised because of the 'project.task.history.cumulative'
records that inherit 'project.task.history' which have a compute method on
on end_date.
To fix this, we set the 'compute' attribute to 'None' and the readonly
'attribute' to 'True'.
This commit is contained in:
Pierre Masereel
2016-08-31 10:19:52 +02:00
parent 1bdca992c1
commit 78f4cf0e3c
+1 -1
View File
@@ -9,7 +9,7 @@ class ProjectTaskHistoryCumulative(models.Model):
_inherit = 'project.task.history'
_auto = False
end_date = fields.Date(string='End Date')
end_date = fields.Date(string='End Date', compute=None, readonly=True)
nbr_tasks = fields.Integer(string='# of Tasks', readonly=True)
project_id = fields.Many2one('project.project', string='Project')