mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 15:30:13 +01:00
19 lines
483 B
JavaScript
19 lines
483 B
JavaScript
Blaze.registerHelper('currentBoard', () => {
|
|
const boardId = Session.get('currentBoard');
|
|
if (boardId) {
|
|
return Boards.findOne(boardId);
|
|
}
|
|
});
|
|
|
|
Blaze.registerHelper('currentCard', () => {
|
|
const cardId = Session.get('currentCard');
|
|
if (cardId) {
|
|
return Cards.findOne(cardId);
|
|
}
|
|
});
|
|
|
|
Blaze.registerHelper('getUser', (userId) => Users.findOne(userId));
|
|
|
|
UI.registerHelper('concat', function (...args) {
|
|
return Array.prototype.slice.call(args, 0, -1).join('');
|
|
});
|