Skip to content

Instantly share code, notes, and snippets.

@sfmskywalker sfmskywalker/Index.razor
Last active Nov 3, 2019

What would you like to do?
Index.razor - Building Workflow Driven .NET Core Applications with Elsa
@page "/"
<div class="form-signup">
<EditForm Model="@RegistrationModel" OnValidSubmit="@HandleFormSubmission" hidden="@ShowConfirmation">
<h1 class="h3 mb-3 font-weight-normal">Please register</h1>
<InputText type="text" id="name" @bind-Value="@RegistrationModel.Name" placeholder="Name" class="form-control" />
<InputText type="email" id="email" @bind-Value="@RegistrationModel.Email" placeholder="Email" class="form-control" />
<InputText type="password" id="password" @bind-Value="@RegistrationModel.Password" placeholder="Password" class="form-control" />
<InputText type="password" id="repeatPassword" @bind-Value="@RegistrationModel.RepeatPassword" placeholder="Repeat password" class="form-control" />
<button type="submit" class="btn btn-lg btn-primary btn-block">Submit</button>
<div hidden="@(!ShowConfirmation)">
Thanks for signing up! Please check your email.
@code {
private RegistrationModel RegistrationModel { get; set; } = new RegistrationModel();
private bool ShowConfirmation { get; set; } = false;
private async Task HandleFormSubmission()
// TODO: Invoke workflow.
ShowConfirmation = true;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.