code-corps / code-corps/code-corps-api

Implement basic task matcher module

未关闭
#736 2 条评论 0 个 reaction 已指派 1 人 已被 @ignu 认领 在 GitHub 查看
Difficulty: Easy good first issue hacktoberfest in progress needs estimate
主要语言
Elixir
星标
234
派生
82
PR 合并指标
30 天内没有已合并 PR

描述

# Problem

From #668 we need a very basic task matcher module.

We would require a module, for example, `UserTaskMatcher` with a `&match_user/2`

```Elixir
defmodule CodeCorps.UserTaskMatcher do
@default_task_count
def match_user(%CodeCorps.User{} = user, task_count // @default_task_count) do
get_list_of_tasks_with_most_overlapping_skills(tasks_count)
end

defp get_list_of_tasks_with_most_overlapping_skills(amount) do
# implementation goes here. probably a simple query initially
# join user skills and tasks skills, group and count by task, order by count
# limit the number of results to amount
end
end
```

## Subtasks

- write described module
- write tests for it

# References

- taken from #668

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。