Skip to content
New issue

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

Add GeoJSON endpoints for shelters and distribution points #70

Merged
merged 2 commits into from
Oct 20, 2018

Conversation

nihonjinrxs
Copy link
Member

Adds the following API endpoints:

  • /api/v1/shelters/geo.json
  • /api/v1/distribution_points/geo.json

Both support filters as with the base routes, and generate GeoJSON output.

Tests are also included.

Closes #44 when merged.

@nihonjinrxs nihonjinrxs self-assigned this Oct 20, 2018
@nihonjinrxs nihonjinrxs requested a review from omnilord October 20, 2018 03:13
Copy link
Collaborator

@omnilord omnilord left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The actual code looks like it works. @nihonjinrxs, Check Slack, I left a message for you there about something else.

db/structure.sql Outdated
@@ -201,10 +202,10 @@ CREATE TABLE public.distribution_points (
updated_by character varying,
notes character varying,
source character varying,
longitude double precision,
latitude double precision,
longitude character varying,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There isn't an accompanying migration for this particular change and I'm not sure why this would change this way. Shelters has double precision for both of these fields which seems to be the standard for latitude and longitude.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, not sure why this is here either. I'll push a commit to remove this change.

@nihonjinrxs
Copy link
Member Author

Saw the note in Slack. Thanks. OK to merge, then?

@omnilord omnilord merged commit 8052ffc into hurricane-response:master Oct 20, 2018
@nihonjinrxs nihonjinrxs deleted the add-geojson branch October 20, 2018 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants