summaryrefslogtreecommitdiffstats
path: root/client/components/boards/boardHeader.js
diff options
context:
space:
mode:
authorRJevnikar <12701645+rjevnikar@users.noreply.github.com>2018-06-05 21:21:14 +0000
committerRJevnikar <12701645+rjevnikar@users.noreply.github.com>2018-06-05 21:21:14 +0000
commit78b9436f38d55c9c7497e16d9c4ffc320bf26a45 (patch)
tree0cad5e85666a2ff1f60eeeeaed50526ca85a64c7 /client/components/boards/boardHeader.js
parent3ce3fa74b350ff1af73b0fffddaeff4b0f126e2c (diff)
downloadwekan-78b9436f38d55c9c7497e16d9c4ffc320bf26a45.tar.gz
wekan-78b9436f38d55c9c7497e16d9c4ffc320bf26a45.tar.bz2
wekan-78b9436f38d55c9c7497e16d9c4ffc320bf26a45.zip
Fix problems highlighted by Codacy/PR Quality Review
Diffstat (limited to 'client/components/boards/boardHeader.js')
-rw-r--r--client/components/boards/boardHeader.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/client/components/boards/boardHeader.js b/client/components/boards/boardHeader.js
index e0b19246..b2640474 100644
--- a/client/components/boards/boardHeader.js
+++ b/client/components/boards/boardHeader.js
@@ -17,6 +17,12 @@ Template.boardMenuPopup.events({
// confirm that the board was successfully archived.
FlowRouter.go('home');
}),
+ 'click .js-delete-board': Popup.afterConfirm('deleteBoard', function() {
+ const currentBoard = Boards.findOne(Session.get('currentBoard'));
+ Popup.close();
+ Boards.remove(currentBoard._id);
+ FlowRouter.go('home');
+ }),
'click .js-outgoing-webhooks': Popup.open('outgoingWebhooks'),
'click .js-import-board': Popup.open('chooseBoardSource'),
});