Module: Teambition2::API::Task
- Included in:
- Client
- Defined in:
- lib/teambition2/api/task.rb
Instance Method Summary collapse
- #create_task(group_id, content, tag_id: []) ⇒ Object
- #edit_task_tags(task_id, tags: []) ⇒ Object
- #project_tasks(project_id) ⇒ Object
- #stage_tasks(stage_id) ⇒ Object
Instance Method Details
#create_task(group_id, content, tag_id: []) ⇒ Object
4 5 6 7 8 9 10 |
# File 'lib/teambition2/api/task.rb', line 4 def create_task(group_id, content, tag_id: []) post('/api/tasks', { '_tasklistId' => group_id, 'content' => content, 'tagIds' => tag_id, }) end |
#edit_task_tags(task_id, tags: []) ⇒ Object
20 21 22 |
# File 'lib/teambition2/api/task.rb', line 20 def (task_id, tags: []) put("/api/tasks/#{task_id}/tagIds", 'tagIds[]' => ) end |
#project_tasks(project_id) ⇒ Object
12 13 14 |
# File 'lib/teambition2/api/task.rb', line 12 def project_tasks(project_id) get("/api/projects/#{project_id}") end |
#stage_tasks(stage_id) ⇒ Object
16 17 18 |
# File 'lib/teambition2/api/task.rb', line 16 def stage_tasks(stage_id) get("/api/stages/#{stage_id}/tasks") end |