2011-07-08 47 views

回答

195

是的。

obj = get_object_or_404(MyModel.objects.select_related(), whatever=whatever)