We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'd like to submit a pull request to be able to overwrite get_queryset. Code below, would this be welcome?
def get_geojson_data(self, context): # Might even take object_list from context by default return self.get_queryset() def render_to_response(self, context, **response_kwargs): """ Returns a JSON response, transforming 'context' to make the payload. """ serializer = GeoJSONSerializer() response = self.response_class(**response_kwargs) # Might want to rename this to data queryset = self.get_geojson_data(context) options = dict( properties=self.properties, precision=self.precision, simplify=self.simplify, srid=self.srid, geometry_field=self.geometry_field, force2d=self.force2d, bbox=self.bbox, bbox_auto=self.bbox_auto, use_natural_keys=self.use_natural_keys, ) serializer.serialize( queryset, stream=response, ensure_ascii=False, **options, ) return response
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I'd like to submit a pull request to be able to overwrite get_queryset. Code below, would this be welcome?
The text was updated successfully, but these errors were encountered: