Answer the question
In order to leave comments, you need to log in
How to make layered properties of a Django model?
Task: for the model you need to make a ton of properties that are calculated on the fly. Properties can be grouped, and I would like them to be stored in the code as well.
To get something like:
model_instance = ModelType.objects.get(id=9001)
print(model_instance.foo.bar.baz)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question