Django form with ManyToMany field with 500,000 objects times out

前端 未结 4 2200
走了就别回头了
走了就别回头了 2021-02-13 05:03

Lets say for example I have a Model called \"Client\" and a model called \"PhoneNumbers\"

class PhoneNumbers(models.Model):
    number = forms.IntegerField()

cl         


        
4条回答
  •  北恋
    北恋 (楼主)
    2021-02-13 05:59

    Out of the box, the model admin has a raw_id_fields option that let your page load much quicker. However, the user interface of raw id fields isn't very intuitive, so you might have to roll your own solution.

提交回复
热议问题