摘要: items = ( XModel.objects.all() .values(field_name) .annotate(Count(field_name)) .order_by('-{}__count'.format(field_name)) ) 阅读全文
posted @ 2022-08-24 09:24 twfb 阅读(107) 评论(0) 推荐(0) 编辑