Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class MyModel(models.Model):
- some_field = models.CharField()
- class MyManager:
- def __init__(self, model: "MyModel"):
- self.model = model
- def print_some_field(self):
- print(self.model.some_field)
Add Comment
Please, Sign In to add comment