65 lines
2.6 KiB
Plaintext
65 lines
2.6 KiB
Plaintext
@using TIAM.Entities.Products
|
|
@using TIAM.Entities.ServiceProviders
|
|
@using TIAM.Models.Dtos.Users
|
|
@using TIAMSharedUI.Shared.Components.Grids
|
|
@using TIAMWebApp.Shared.Application.Interfaces
|
|
@using TIAMWebApp.Shared.Application.Services
|
|
@using TIAMWebApp.Shared.Application.Utility
|
|
@using AyCode.Services.Loggers
|
|
@using TIAM.Core.Loggers
|
|
@using AyCode.Core
|
|
@using AyCode.Core.Extensions
|
|
@using AyCode.Interfaces.Profiles.Dtos
|
|
@using TIAM.Entities.Addresses
|
|
@using TIAM.Entities.Profiles
|
|
@using Profile = TIAM.Entities.Profiles.Profile
|
|
@inject IEnumerable<IAcLogWriterClientBase> LogWriters
|
|
@inject AdminSignalRClient AdminSignalRClient
|
|
|
|
<ProfileDetailGrid @ref="_profileGrid"
|
|
ContextIds="@(ParentData.ProfileId.IsNullOrEmpty() ? throw new InvalidDataException($"ParentData.ProfileId.IsNullOrEmpty(); ParentData.ProfileId: {ParentData.ProfileId}") : [ParentData.ProfileId])"
|
|
Logger="_logger"
|
|
SignalRClient="AdminSignalRClient"
|
|
ValidationEnabled="false"
|
|
EditMode="GridEditMode.EditForm"
|
|
ColumnResizeMode="GridColumnResizeMode.NextColumn"
|
|
DetailExpandButtonDisplayMode="DetailExpandButtonDisplayMode">
|
|
<Columns>
|
|
<DxGridCommandColumn NewButtonVisible="false" DeleteButtonVisible="false" Width="70" MinWidth="70" FixedPosition="GridColumnFixedPosition.Left" />
|
|
<DxGridDataColumn FieldName="Id" ShowInColumnChooser="AcDomain.IsDeveloperVersion" Visible="AcDomain.IsDeveloperVersion" DisplayFormat="N" />
|
|
<DxGridDataColumn FieldName="Name" />
|
|
<DxGridDataColumn FieldName="FullName" />
|
|
<DxGridDataColumn FieldName="Created" Width="40%" />
|
|
<DxGridDataColumn FieldName="Modified" />
|
|
</Columns>
|
|
<DetailRowTemplate>
|
|
<DxTabs>
|
|
<DxTabPage Text="Address">
|
|
<AddressDetailGridComponent ParentData="((Profile)context.DataItem)" />
|
|
</DxTabPage>
|
|
</DxTabs>
|
|
</DetailRowTemplate>
|
|
|
|
</ProfileDetailGrid>
|
|
|
|
@code {
|
|
[Parameter] public GridDetailExpandButtonDisplayMode DetailExpandButtonDisplayMode { get; set; } = GridDetailExpandButtonDisplayMode.Never;
|
|
[Parameter] public IProfileForeignKey ParentData { get; set; } = null!;
|
|
|
|
private ProfileDetailGrid _profileGrid = null!;
|
|
private LoggerClient<ProfileGridComponent> _logger = null!;
|
|
|
|
protected override void OnInitialized()
|
|
{
|
|
_logger = new LoggerClient<ProfileGridComponent>(LogWriters.ToArray());
|
|
}
|
|
|
|
protected override void OnParametersSet()
|
|
{
|
|
_logger.DebugConditional(ParentData.ProfileId.ToString());
|
|
|
|
base.OnParametersSet();
|
|
}
|
|
|
|
}
|