end verification
This commit is contained in:
@@ -29,8 +29,6 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-xl-7 col-lg-6">
|
||||
<Toasts class="p-3" Messages="messages" AutoHide="true" Delay="6000" Placement="ToastsPlacement.TopRight" />
|
||||
|
||||
<div class="contact-form-right-warp">
|
||||
<div class="postbox__comment-form">
|
||||
<EditForm EditContext="editContext" OnValidSubmit="newTicket">
|
||||
@@ -73,7 +71,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</EditForm>
|
||||
<Button Color="ButtonColor.Primary" @onclick="OnShowModalClick">Show Modal</Button>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -82,25 +80,10 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<Modal @ref="_modal"
|
||||
title="Modal title">
|
||||
|
||||
<BodyTemplate>
|
||||
Modal body text goes here.
|
||||
</BodyTemplate>
|
||||
|
||||
<FooterTemplate>
|
||||
<Button Color="ButtonColor.Secondary" @onclick="OnHideModalClick">Close</Button>
|
||||
<Button Color="ButtonColor.Primary" @onclick="testhand">Save changes</Button>
|
||||
</FooterTemplate>
|
||||
|
||||
</Modal>
|
||||
|
||||
@code {
|
||||
List<ToastMessage> messages = new List<ToastMessage>();
|
||||
|
||||
private Modal _modal = default!;
|
||||
//-------------------------------
|
||||
string type = "NewTicketNoAuthentication";
|
||||
private EditContext? editContext;
|
||||
[SupplyParameterFromForm]
|
||||
@@ -127,8 +110,7 @@
|
||||
{
|
||||
messageStore?.Clear();
|
||||
var res = await request.Content.ReadFromJsonAsync<int>();
|
||||
OnShowModalClick();
|
||||
// nav.NavigateTo($"Verification/{res}");
|
||||
nav.NavigateTo($"Verification/{res}");
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -137,28 +119,8 @@
|
||||
|
||||
}
|
||||
}
|
||||
private async Task testhand()
|
||||
{
|
||||
ShowMessage(ToastType.Warning);
|
||||
}
|
||||
private async Task OnShowModalClick()
|
||||
{
|
||||
await _modal.ShowAsync();
|
||||
}
|
||||
private async Task OnHideModalClick()
|
||||
{
|
||||
await _modal.HideAsync();
|
||||
}
|
||||
|
||||
private void ShowMessage(ToastType toastType) => messages.Add(CreateToastMessage(toastType));
|
||||
|
||||
private ToastMessage CreateToastMessage(ToastType toastType)
|
||||
=> new ToastMessage
|
||||
{
|
||||
Type = toastType,
|
||||
Title = "Blazor Bootstrap",
|
||||
HelpText = $"{DateTime.Now}",
|
||||
Message = $"Hello, world! This is a toast message. DateTime: {DateTime.Now}",
|
||||
};
|
||||
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user