def queryset(self, request, **kwargs):
        """
        Returns the queryset (along with ordering) to be used when retrieving object(s).
        """
        qs = self.model._default_manager.all()
        if self.ordering:
            qs = qs.order_by(*self.ordering)
        return qs
def queryset ( self , request , ** kwargs ) : qs = self . model . _default_manager . all ( ) if self . ordering : qs = qs . order_by ( * self . ordering ) return qs
Returns the queryset (along with ordering) to be used when retrieving object(s).