1
0
mirror of synced 2024-12-04 19:07:58 +01:00
TaikoLocalServer/TaikoWebUI/Pages/Dialogs/UserQrCodeDialog.razor

30 lines
779 B
Plaintext
Raw Normal View History

2024-05-17 00:32:46 +02:00
<MudDialog Class="dialog-user-qr-code">
2023-10-01 14:09:04 +02:00
<DialogContent>
2024-03-09 00:42:56 +01:00
<MudExtensions.MudBarcode Value="@qrCode" BarcodeFormat="ZXing.BarcodeFormat.QR_CODE" Height="300" Width="300" />
2023-10-01 14:09:04 +02:00
</DialogContent>
<DialogActions>
<MudButton Color="Color.Primary" OnClick="Submit">@Localizer["Dialog OK"]</MudButton>
2023-10-01 14:09:04 +02:00
</DialogActions>
</MudDialog>
@code {
[CascadingParameter]
MudDialogInstance MudDialog { get; set; } = null!;
[Parameter]
public User User { get; set; } = new();
private string qrCode = string.Empty;
protected override void OnInitialized()
{
base.OnInitialized();
qrCode = "BNTTCNID" + User.AccessCodes.First();
2023-10-01 14:09:04 +02:00
}
private void Submit()
{
MudDialog.Close(DialogResult.Ok(true));
}
}