mirror of
https://github.com/wekan/wekan.git
synced 2026-01-03 08:08:49 +01:00
Import board: map team permission, and refactor code to share with card import
This commit is contained in:
parent
ec304de811
commit
8e0ad91191
2 changed files with 83 additions and 135 deletions
|
|
@ -111,6 +111,14 @@ Boards.helpers({
|
|||
colorClass() {
|
||||
return `board-color-${this.color}`;
|
||||
},
|
||||
|
||||
// XXX currently mutations return no value so we have an issue when using addLabel in import
|
||||
// XXX waiting on https://github.com/mquandalle/meteor-collection-mutations/issues/1 to remove...
|
||||
pushLabel(name, color) {
|
||||
const _id = Random.id(6);
|
||||
Boards.direct.update(this._id, { $push: {labels: { _id, name, color }}});
|
||||
return _id;
|
||||
},
|
||||
});
|
||||
|
||||
Boards.mutations({
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue