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 task to inbox task list when created from GitHub #877

Merged
merged 1 commit into from
Sep 4, 2017

Conversation

joshsmith
Copy link
Contributor

What's in this PR?

This change makes it so a task created on GitHub is synced to the inbox TaskList for the given Project.

Open to thoughts on how to improve the logic or the tests.

References

Fixes #872

@joshsmith joshsmith requested a review from begedin August 30, 2017 17:20
@joshsmith joshsmith force-pushed the add-task-to-task-list branch 3 times, most recently from 15b281a to 7c8931c Compare August 30, 2017 18:38
Copy link
Contributor

@begedin begedin left a comment

Choose a reason for hiding this comment

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

Looks good. Feel free to create an issue for the suggestion I made.

project_ids |> Enum.each(fn project_id ->
project = Project |> Repo.get_by(id: project_id)
insert(:task_list, project: project, inbox: true)
end)
Copy link
Contributor

Choose a reason for hiding this comment

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

Something to consider, I don't believe in a real use scenario, projects can get created without associated task lists. Maybe we should upgrade our project factory so a set of task lists is always created? As a separate issue, of course.

@joshsmith
Copy link
Contributor Author

@begedin can you merge and create that issue?

Fix tests by adding in inbox task list
@joshsmith joshsmith merged commit 72ab01e into develop Sep 4, 2017
@joshsmith joshsmith deleted the add-task-to-task-list branch September 4, 2017 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants