From c35fa9bc0645f082f4f08d2bdc033b8a4fcf5790 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 3 Feb 2009 19:00:45 +0100 Subject: [PATCH] Fix for new field attributes names --- work.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/work.py b/work.py index c5ea4cd429..2705b816ef 100644 --- a/work.py +++ b/work.py @@ -12,15 +12,15 @@ class TimesheetWork(OSV): def __init__(self): super(TimesheetWork, self).__init__() self.parent = copy.copy(self.parent) - if not self.parent._context: - self.parent._context = "{'project_type': locals().get('project_type')}" - elif 'project_type' not in self.parent._context: + if not self.parent.context: + self.parent.context = "{'project_type': locals().get('project_type')}" + elif 'project_type' not in self.parent.context: sep = '' - if self.parent._context[-2] != ',': + if self.parent.context[-2] != ',': sep = ',' - self.parent._context = self.parent._context[:-1] + \ + self.parent.context = self.parent.context[:-1] + \ sep + "'project_type': locals().get('project_type')" + \ - self.parent._context[-1:] + self.parent.context[-1:] self._reset_columns() TimesheetWork()