The values method problems are:
I want to create my custom values method using django Manager
class MyModelManager(models.Manager): def values(self, *fields): # I want to get model belong to this manger # then I want to check the fields if its in models (we have fields came from annotate) # after that I want to exclude to the fields that has choices # next I want to call the super values method and passed to it the values that does not have choices # finally I want to reorder query according to passed fields class MyModel(models.model): # An example model objects = MyModelManager()
1.4m articles
1.4m replys
5 comments
57.0k users