class Category(models.Model):
cate_name = models.CharField(max_length = 120)
class Tags(models.Model):
tag_name = models.Charfield(max_length = 120)
class Article(models.Model):
cate = models.ForeignKey(Category):
tags = models.ManyToManyField(Tags,blank=True)
art_title = models.CharField(max_length = 200)
{% for c in cate %}
{{ c.cate_name}}#想在分类名称后面显示该分类下文章的数量模板该怎么写,view又该怎么写
{%endfor%}