Back to Blog
The swapper magazine6/1/2023 ![]() Although this capability is currently undocumented while any remaining issues are being sorted out, it has proven to be very stable and useful in our experience. The auth.User swappable code was implemented in a generic way that allows it to be used for any model. This third approach is taken by Django to facilitate swapping the auth.User model. Use swappable models, together with ForeignKeys that read the swappable.Put the foreign key on BaseChild, but make Parent a concrete model that.Avoid putting the foreign key on BaseChild and tell the user they need to.BaseParent and BaseChild) for this, but then you ![]() These models and supplement them with their own additional fields. Suppose further that you want to allow the user to subclass either or both of
0 Comments
Read More
Leave a Reply. |