From 9c6d374b950e8c4bd0c1c905cf36c953581a3156 Mon Sep 17 00:00:00 2001 From: Angelo Gallarello Date: Thu, 16 Aug 2018 16:54:29 +0200 Subject: Labels activities --- models/boards.js | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'models/boards.js') diff --git a/models/boards.js b/models/boards.js index 76a8f704..c77c9de2 100644 --- a/models/boards.js +++ b/models/boards.js @@ -254,6 +254,10 @@ Boards.helpers({ return _.findWhere(this.labels, { name, color }); }, + getLabelById(labelId){ + return _.findWhere(this.labels, { _id: labelId }); + }, + labelIndex(labelId) { return _.pluck(this.labels, '_id').indexOf(labelId); }, -- cgit v1.2.3-1-g7c22