mirror of
https://github.com/wekan/wekan.git
synced 2025-04-22 13:07:17 -04:00
19 lines
420 B
JavaScript
19 lines
420 B
JavaScript
Actions = new Mongo.Collection('actions');
|
|
|
|
Actions.allow({
|
|
insert(userId, doc) {
|
|
return allowIsBoardAdmin(userId, Boards.findOne(doc.boardId));
|
|
},
|
|
update(userId, doc) {
|
|
return allowIsBoardAdmin(userId, Boards.findOne(doc.boardId));
|
|
},
|
|
remove(userId, doc) {
|
|
return allowIsBoardAdmin(userId, Boards.findOne(doc.boardId));
|
|
},
|
|
});
|
|
|
|
Actions.helpers({
|
|
description() {
|
|
return this.desc;
|
|
},
|
|
});
|