Handle dbRebuild action in sidebar

This commit is contained in:
ZeroNet 2016-08-10 12:52:48 +02:00
parent 538af99e8c
commit 9a1e1e56b3

View file

@ -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