Rocky Holms Rocky Holms - 1 year ago 72
Python Question

Top 7 most common tags Taggit

def most_common(self):
return self.get_queryset().annotate(

How would I edit this to only view the top 7 tags. This is a function from taggit and I would only like to see only 7. thanks.

Answer Source

How about most_common()[:7]?… – ozgur

This is the correct asnwer, thanks ozgur

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download