Django models with variable number of fields

前端 未结 2 1503
[愿得一人]
[愿得一人] 2021-01-13 22:40

I\'m working on a new project and I\'d like to create a django model that will have a variable number of EmailFields depending on another variable. What I\'m tr

2条回答
  •  南方客
    南方客 (楼主)
    2021-01-13 23:28

    No. Put the emails in a separate model and link them back to House with a ForeignKey.

提交回复
热议问题