|
@@ -29,6 +29,18 @@ BlazeComponent.extendComponent({
|
|
|
board.restore();
|
|
|
Utils.goBoardId(board._id);
|
|
|
},
|
|
|
+ 'click .js-delete': Popup.afterConfirm('cardDelete', function() {
|
|
|
+ Popup.close();
|
|
|
+ const isSandstorm = Meteor.settings && Meteor.settings.public &&
|
|
|
+ Meteor.settings.public.sandstorm;
|
|
|
+ if (isSandstorm && Session.get('currentBoard')) {
|
|
|
+ const currentBoard = Boards.findOne(Session.get('currentBoard'));
|
|
|
+ Boards.remove(currentBoard._id);
|
|
|
+ }
|
|
|
+ const board = this.currentData();
|
|
|
+ Boards.remove(board._id);
|
|
|
+ FlowRouter.go('home');
|
|
|
+ }),
|
|
|
}];
|
|
|
},
|
|
|
}).register('archivedBoards');
|