From bc97b6a4ef27edc906c165ed633421ecc875c73c Mon Sep 17 00:00:00 2001 From: Roberto Rosario Date: Sat, 13 Sep 2014 02:23:14 -0400 Subject: [PATCH] Add get_extra_context method to ExtraContextMixin --- mayan/apps/common/views.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/mayan/apps/common/views.py b/mayan/apps/common/views.py index 474a41403f..bee81b05b0 100644 --- a/mayan/apps/common/views.py +++ b/mayan/apps/common/views.py @@ -273,9 +273,12 @@ class MayanPermissionCheckMixin(object): class ExtraContextMixin(object): extra_context = {} + def get_extra_context(self): + return self.extra_context + def get_context_data(self, **kwargs): context = super(ExtraContextMixin, self).get_context_data(**kwargs) - context.update(self.extra_context) + context.update(self.get_extra_context()) return context