-
-
Save SmileyChris/143863cd1208ae576c658b7934f4bbc8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class AccountsStatisticsDetail(TemplateView): | |
template_name = 'grow/accountsstatistics.html' | |
def get_context_data(self, **kwargs): | |
context = super().get_context_data(**kwargs) | |
username = self.kwargs.get('username') | |
if username: | |
context['username'] = username | |
context['account_stats'] = ( | |
AccountsStatistics.objects | |
.filter(username__username=username) | |
) | |
return context |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment