Skip to content

[POST]: post_type filter on index close #86 - #163

Merged
begedin merged 3 commits into
developfrom
post-type-filter
Aug 31, 2016
Merged

[POST]: post_type filter on index close #86#163
begedin merged 3 commits into
developfrom
post-type-filter

Conversation

@snewcomer

@snewcomer snewcomer commented Aug 31, 2016

Copy link
Copy Markdown
Contributor

Added post_type filtering on the index route for the post controller.

@joshsmith

Copy link
Copy Markdown
Contributor

@snewcomer would you mind adding summary here to the description?

@joshsmith joshsmith mentioned this pull request Aug 31, 2016
85 tasks
@begedin

begedin commented Aug 31, 2016

Copy link
Copy Markdown
Contributor

Looks good to go

Completely missed the fact that we should be able to provide multiple post types in the filter. Not ready yet.

@begedin

begedin commented Aug 31, 2016

Copy link
Copy Markdown
Contributor

Should be good to go now, I changed the filter.

Could use a review by someone else.

post_types =
json["data"]
|> Enum.map(fn(r) -> r["attributes"] end)
|> Enum.map(fn(atts) -> atts["post-type"] end)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

r and atts could be better named.

@begedin

begedin commented Aug 31, 2016

Copy link
Copy Markdown
Contributor

@joshsmith Merging this, since you took a look, so I can focus on ember

@begedin
begedin merged commit 2424297 into develop Aug 31, 2016
@begedin
begedin deleted the post-type-filter branch August 31, 2016 08:11
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.

3 participants