Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我无法使用 django 评论将评论拉入我的模板。我想在外壳中测试一些东西 - 即。拉入一个对象并获得一组评论 - 但我不知道该怎么做。
是否可以在 shell 中访问模型的评论?
python manage.py shell from django.contrib.comments import Comment c = Comment.objects.filter(...) ...