2021-04-28 06:14:15 +02:00
|
|
|
@model BTCPayServer.Fido2.Models.Fido2AuthenticationViewModel
|
2021-04-20 07:06:32 +02:00
|
|
|
@{
|
|
|
|
ViewData.SetActivePageAndTitle(ManageNavPages.Fido2, "Registered FIDO2 Credentials");
|
|
|
|
}
|
|
|
|
|
|
|
|
<table class="table table-lg mb-4">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Name</th>
|
2021-05-19 04:39:27 +02:00
|
|
|
<th class="text-end">Actions</th>
|
2021-04-20 07:06:32 +02:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
@foreach (var device in Model.Credentials)
|
|
|
|
{
|
|
|
|
<tr>
|
|
|
|
<td>@(string.IsNullOrEmpty(device.Name)? "Unnamed FIDO2 credential": device.Name)</td>
|
2021-05-19 04:39:27 +02:00
|
|
|
<td class="text-end">
|
2021-04-20 07:06:32 +02:00
|
|
|
<a asp-action="Remove" asp-route-id="@device.Id">Remove</a>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
}
|
|
|
|
@if (!Model.Credentials.Any())
|
|
|
|
{
|
|
|
|
<tr>
|
|
|
|
<td colspan="2" class="text-center h5 py-2">
|
|
|
|
No registered credentials
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2021-05-19 04:39:27 +02:00
|
|
|
|
|
|
|
<form asp-action="Create" method="get">
|
|
|
|
<div class="row g-1">
|
|
|
|
<div class="col">
|
|
|
|
<input type="text" class="form-control" name="Name" placeholder="New Credential Name"/>
|
|
|
|
</div>
|
|
|
|
<div class="col">
|
|
|
|
<button type="submit" class="btn btn-primary ms-2">
|
|
|
|
<span class="fa fa-plus"></span>
|
|
|
|
Add New Credential
|
|
|
|
</button>
|
|
|
|
</div>
|
2021-04-20 07:06:32 +02:00
|
|
|
</div>
|
|
|
|
</form>
|