Hello,
May be you want to subclass GenericForeignKey:
class GenericOneToOne(GenericForeignKey):
many_to_one = False
one_to_many = False
one_to_one = True
Though have not tried it so YMMV.
Kind regards
On Thu, May 31, 2018 at 8:59 PM, Vitor Barbosa wrote:
> Hello! This is my first
Hello! This is my first question, so please excuse any mistakes.
I'm using django 1.8 (working on migration to 2.0).
I need to implement a one-to-one generic relation. To illustrate suppose I
have three classes, the first representing and abstract class in a store
and the other specific products
2 matches
Mail list logo