mirror of
https://github.com/simple-login/app.git
synced 2024-09-28 04:41:28 +02:00
prettify client listing page
This commit is contained in:
parent
5e2fc603cd
commit
84fc5afedb
@ -74,7 +74,7 @@
|
||||
</td>
|
||||
|
||||
<td>
|
||||
<a href="{{ url_for('developer.client_detail', client_id=client.id) }}" class="btn btn-info">
|
||||
<a href="{{ url_for('developer.client_detail', client_id=client.id) }}" class="icon">
|
||||
<i class="fe fe-edit"></i>
|
||||
</a>
|
||||
</td>
|
||||
@ -94,14 +94,15 @@
|
||||
</td>
|
||||
-->
|
||||
|
||||
|
||||
<td>
|
||||
<form method="post"
|
||||
onsubmit="return confirm('Please make sure no user is using this client. This operation is not reversible');">
|
||||
<form method="post" id="delete-client-form">
|
||||
<input type="hidden" name="form-name" value="delete-client">
|
||||
<input type="hidden" name="client-id" value="{{ client.id }}">
|
||||
<button type="submit" class="btn btn-danger">
|
||||
<a href="javascript:{}"
|
||||
class="icon delete-client">
|
||||
<i class="fe fe-trash"></i>
|
||||
</button>
|
||||
</a>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
@ -137,6 +138,18 @@
|
||||
overlayClickDismiss: false,
|
||||
});
|
||||
|
||||
$(".delete-client").on("click", function (e) {
|
||||
notie.confirm({
|
||||
text: "This operation is not reversible, please confirm",
|
||||
cancelCallback: () => {
|
||||
// nothing to do
|
||||
},
|
||||
submitCallback: () => {
|
||||
$(this).closest("form").submit();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
$(".custom-switch-input").change(function (e) {
|
||||
// Only ask for confirmation when publishing, not when un-publishing
|
||||
if (e.target.checked) {
|
||||
|
Loading…
Reference in New Issue
Block a user