def get(self, request): cs = ClientStats() clients = cs.get_entries() return self.render_to_response({ "clients": clients.most_common(), "max_users": cs.max_users, "total": cs.total_users, })
def get(self, request): cs = ClientStats() clients = cs.get_entries() return self.render_to_response({ 'clients': clients.most_common(), 'max_users': cs.max_users, 'total': cs.total_users, })
def get(self, request): cs = ClientStats() clients = cs.get_entries() return JsonResponse(map(self.to_dict, clients.most_common()))