41 lines
1.1 KiB
Plaintext
41 lines
1.1 KiB
Plaintext
@page "/_Admin/WTM_AREA/Create"
|
|
@using wtmProject.ViewModel._Admin.WTM_AREAVMs;
|
|
@inherits BasePage
|
|
|
|
<ValidateForm @ref="vform" Model="@Model" OnValidSubmit="@Submit">
|
|
<Row ItemsPerRow="ItemsPerRow.Two" RowType="RowType.Normal">
|
|
|
|
<BootstrapInput @bind-Value="@Model.Entity.AreaCode" />
|
|
<BootstrapInput @bind-Value="@Model.Entity.AreaName" />
|
|
</Row>
|
|
<div class="modal-footer table-modal-footer">
|
|
@*<Button Color="Color.Secondary" Icon="fa fa-close" Text="@WtmBlazor.Localizer["Sys.Close"]" OnClick="OnClose" />*@
|
|
<Button Color="Color.Primary" ButtonType="ButtonType.Submit" Icon="fa fa-save" Text="@WtmBlazor.Localizer["Sys.Save"]" IsAsync="true" />
|
|
</div>
|
|
</ValidateForm>
|
|
|
|
@code {
|
|
|
|
private WTM_AREAVM Model = new WTM_AREAVM();
|
|
private ValidateForm vform { get; set; }
|
|
|
|
|
|
protected override async Task OnInitializedAsync()
|
|
{
|
|
|
|
await base.OnInitializedAsync();
|
|
}
|
|
|
|
|
|
private async Task Submit(EditContext context)
|
|
{
|
|
await PostsForm(vform, "/api/WTM_AREA/add", (s) => "Sys.OprationSuccess");
|
|
}
|
|
|
|
public void OnClose()
|
|
{
|
|
CloseDialog();
|
|
}
|
|
|
|
}
|