mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-19 14:32:16 +00:00
begin work on perms
This commit is contained in:
@@ -5,7 +5,6 @@ from django.views import generic
|
||||
from django.views.decorators.csrf import csrf_exempt
|
||||
|
||||
from RIGS import models
|
||||
from training.models import Trainee
|
||||
|
||||
|
||||
# This view should be exempt from requiring CSRF token.
|
||||
@@ -43,7 +42,7 @@ class ProfileDetail(generic.DetailView):
|
||||
def get_context_data(self, **kwargs):
|
||||
context = super(ProfileDetail, self).get_context_data(**kwargs)
|
||||
context['page_title'] = "Profile: {}".format(self.object)
|
||||
context["completed_levels"] = Trainee.objects.get(pk=self.object.pk).level_qualifications()
|
||||
context["completed_levels"] = self.object.as_trainee.level_qualifications()
|
||||
return context
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user