From 9a1e1e56b372dd15a15d2452916c123e06a57836 Mon Sep 17 00:00:00 2001 From: ZeroNet Date: Wed, 10 Aug 2016 12:52:48 +0200 Subject: [PATCH] Handle dbRebuild action in sidebar --- plugins/Sidebar/media/Sidebar.coffee | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/plugins/Sidebar/media/Sidebar.coffee b/plugins/Sidebar/media/Sidebar.coffee index ed34b4c0..024659bc 100644 --- a/plugins/Sidebar/media/Sidebar.coffee +++ b/plugins/Sidebar/media/Sidebar.coffee @@ -249,6 +249,11 @@ class Sidebar extends Class @tag.find("#button-dbreload").off("click").on "click", => wrapper.ws.cmd "dbReload", [], => wrapper.notifications.add "done-sitelimit", "done", "Database schema reloaded", 5000 + # Database rebuild + @tag.find("#button-dbrebuild").off("click").on "click", => + wrapper.notifications.add "done-dbrebuild", "info", "Database rebuilding...." + wrapper.ws.cmd "dbRebuild", [], => + wrapper.notifications.add "done-dbrebuild", "done", "Database rebuilt!", 5000 @updateHtmlTag() return false