From 78f4cf0e3c1bb082cac6da8e3098cba565ac06ae Mon Sep 17 00:00:00 2001 From: Pierre Masereel Date: Tue, 30 Aug 2016 17:42:38 +0200 Subject: [PATCH] [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'. --- addons/project/report/project_cumulative.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/project/report/project_cumulative.py b/addons/project/report/project_cumulative.py index eed808dbc9a..2cf36749595 100644 --- a/addons/project/report/project_cumulative.py +++ b/addons/project/report/project_cumulative.py @@ -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')