pythonBug:解决 AttributeError: 'ForeignKey' object has no attribute 're'

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/qq_27695659/article/details/87952496

解决办法

#data_list =filter_field_obj.rel.to.objects.all()这个不行换成以下代码
data_list = filter_field_obj.remote_field.model.objects.all() 

猜你喜欢

转载自blog.csdn.net/qq_27695659/article/details/87952496