How can I add a constraint to a Django model that forces two fields to match?

前端 未结 0 1912
Happy的楠姐
Happy的楠姐 2020-12-06 23:27

I need to add a constraint to my Company model that makes sure that if state is defined that country is also defined and that state__country<

相关标签:
回答
  • 消灭零回复
提交回复
热议问题