def get_popular(n):
    last_month = datetime.today() - timedelta(days=30)
    return Article.objects.all().filter(published=True, published_date__gte=last_month).order_by('-clicks')[:n]