lib/pt/client.rb in pt-0.7.1 vs lib/pt/client.rb in pt-0.7.2
- old
+ new
@@ -108,9 +108,19 @@
def assign_task(project, task, owner)
task = PivotalTracker::Story.find(task.id, project.id)
task.update(:owned_by => owner)
end
+ def add_label(project, task, label)
+ task = PivotalTracker::Story.find(task.id, project.id)
+ if task.labels
+ task.labels += "," + label;
+ task.update(:labels => task.labels)
+ else
+ task.update(:labels => label)
+ end
+ end
+
def comment_task(project, task, comment)
task = PivotalTracker::Story.find(task.id, project.id)
task.notes.create(:text => comment)
end