Add "close" button to shutdown the server

This commit is contained in:
Andrei Pohilko
2022-09-08 12:11:21 +01:00
parent 8fa3d9b960
commit 4bd510962a
3 changed files with 11 additions and 2 deletions
-1
View File
@@ -70,4 +70,3 @@ Adding new repository
Recognise & show ArgoCD-originating charts/objects
Have cleaner idea on the web API structure
See if we can build in Chechov or Validkube validation
Add "close" button to shutdown the server, wherever it is
+1
View File
@@ -47,6 +47,7 @@
<label for="cluster" style="margin-top: 0.5rem">K8s Context:</label>
<select id="cluster" class="form-control"></select>
</form>
<i class="btn fa fa-power-off text-muted" title="Shut down the Helm Dashboard application"></i>
</div>
</div>
</nav>
+10 -1
View File
@@ -346,4 +346,13 @@ function showResources(namespace, chart, revision) {
}
})
}
}
$(".fa-power-off").click(function () {
$.ajax({
url: "/",
type: 'DELETE',
}).done(function () {
window.close();
})
})