Advertisement
avaaren

YA ponYal

Apr 7th, 2020
194
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.39 KB | None | 0 0
  1. class ResultView(TemplateView):
  2.  
  3.     template_name = 'game/result.html'
  4.  
  5.     def get_context_data(self, **kwargs):
  6.         game_obj = GameSession.objects.filter(user=self.request.user)[:1]
  7.  
  8.         data = super().get_context_data(**kwargs)
  9.         data['game_result'] = game_obj
  10.         # data['high_scores'] = high_scores
  11.         # data['your_place'] = your_place
  12.         return data
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement