- Moves Redistributables for games to separate panel - Add option override for games - Add Monaco completions for option schema editing - Add UI for editing options for a redistributable - Add config importing to translate from INI, JSON, XML, etc to redist option schema
33 lines
933 B
Text
33 lines
933 B
Text
@page "/Redistributables/{id:guid}/Options"
|
|
@using LANCommander.Server.UI.Pages.Redistributables.Components
|
|
@attribute [Authorize(Roles = RoleService.AdministratorRoleName)]
|
|
@inject NavigationManager NavigationManager
|
|
|
|
<RedistributableEditView @ref="EditView" Id="Id">
|
|
<TitleTemplate>
|
|
<Text>Options</Text>
|
|
</TitleTemplate>
|
|
<TitleExtraTemplate>
|
|
<Button Type="ButtonType.Primary" OnClick="EditView.Save">Save</Button>
|
|
</TitleExtraTemplate>
|
|
<ChildContent>
|
|
<OptionSchemaEditor @bind-Value="context.OptionSchema" OnSave="Save" />
|
|
</ChildContent>
|
|
</RedistributableEditView>
|
|
|
|
@code {
|
|
[Parameter] public Guid Id { get; set; }
|
|
|
|
RedistributableEditView EditView;
|
|
|
|
protected override void OnInitialized()
|
|
{
|
|
if (Id == Guid.Empty)
|
|
NavigationManager.NavigateTo("/Redistributables", true);
|
|
}
|
|
|
|
async Task Save()
|
|
{
|
|
await EditView.Save();
|
|
}
|
|
}
|