(self)
return counter.most_common()
Returns all podcast licenses
Returns all podcast licenses
Returns all podcast licenses
def licenses(self):
        """Returns all podcast licenses"""
        query = Podcast.objects.exclude(license__isnull=True)
        values = query.values("license").annotate(Count("id")).order_by()

        counter = Counter({l["license"]: l["id__count"] for l in values})
        return counter.most_common()
def licenses ( self ) : query = Podcast . objects . exclude ( license__isnull = True ) values = query . values ( "license" ) . annotate ( Count ( "id" ) ) . order_by ( ) counter = Counter ( { l [ "license" ] : l [ "id__count" ] for l in values } ) return counter . most_common ( )