{% for topic in topics %}
<li>
<a href="{% url 'learning_logs:topic' topic.id %}">{{ topic.id }}-{{ topic }}</a>
</li>
{% empty %}
<li>No topic have been added yet.</li>
{% endfor %}
topic.id 查询到的结果是1和2,但是渲染成链接的时候变成10和20
最后发现是自己url正则写错