mirror of
https://git.collinwebdesigns.de/oscar.krause/fastapi-dls.git
synced 2024-11-23 23:41:06 +03:00
implemented button for delete all expired leases
This commit is contained in:
parent
77dd0922d8
commit
0e39f1849b
@ -125,3 +125,9 @@ async function deleteLease(lease_ref) {
|
|||||||
xhr.open("DELETE", `/-/lease/${lease_ref}`, true);
|
xhr.open("DELETE", `/-/lease/${lease_ref}`, true);
|
||||||
xhr.send();
|
xhr.send();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async function deleteExpiredLeases() {
|
||||||
|
let xhr = new XMLHttpRequest();
|
||||||
|
xhr.open("DELETE", `/-/leases/expired`, true);
|
||||||
|
xhr.send();
|
||||||
|
}
|
||||||
|
@ -13,6 +13,9 @@
|
|||||||
<button type="button" class="btn btn-sm btn-outline-danger" onclick="deleteLease().finally(() => load())">
|
<button type="button" class="btn btn-sm btn-outline-danger" onclick="deleteLease().finally(() => load())">
|
||||||
delete lease
|
delete lease
|
||||||
</button>
|
</button>
|
||||||
|
<button type="button" class="btn btn-sm btn-outline-danger" onclick="deleteExpiredLeases().finally(() => load())">
|
||||||
|
delete all expired leases
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<button type="button" class="btn btn-sm btn-outline-secondary" onclick="load()" title="refresh">
|
<button type="button" class="btn btn-sm btn-outline-secondary" onclick="load()" title="refresh">
|
||||||
|
Loading…
Reference in New Issue
Block a user