[성현모] TestList 조회 페이지 개선

This commit is contained in:
SHM
2025-09-17 16:44:33 +09:00
parent bdde95386f
commit a1a6759ea6
5 changed files with 154 additions and 30 deletions

View File

@ -0,0 +1,11 @@
<span style="@($"font-size:1.3rem; width:{MaxWidth}; max-width:{MaxWidth}; display:inline-block;white-space:normal;word-wrap:break-word;")">
@Text
</span>
@code {
[Parameter]
public string Text { get; set; }
[Parameter]
public string MaxWidth { get; set; }
}

View File

@ -0,0 +1,23 @@
<RadzenCard Style="@($"height:100%;{CardStyle};")" class="rz-mb-3 rz-p-0">
<RadzenStack Style="width:100%; height:2.7rem; background-color:var(--rz-primary-lighter);" class="rz-pl-3">
<RadzenLabel class="rz-p-1" Text="@HeaderText">
</RadzenLabel>
</RadzenStack>
<RadzenStack Style="@($"height:{ContentsHeight}")" Orientation="Orientation.Horizontal" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
@ChildContent
</RadzenStack>
</RadzenCard>
@code {
[Parameter]
public RenderFragment? ChildContent { get; set; }
[Parameter]
public string HeaderText { get; set; }
[Parameter]
public string ContentsHeight { get; set; }
[Parameter]
public string CardStyle { get; set; }
}

View File

@ -18,8 +18,9 @@
@foreach (var col in typeof(TDataModel).GetProperties()) @foreach (var col in typeof(TDataModel).GetProperties())
{ {
@* if(DisableColums?.Contains(col.Name.ToLower()) == true) if (col.Name.ToLower().Contains("navigation") || col.Name.ToLower().Contains("stepversion") || col.Name.ToLower().Contains("isglobal")
continue; *@ || col.Name.ToLower().Contains("updatedt") || col.Name.ToLower().Contains("enable"))
continue;
if (col.Name.ToLower().Equals("testdate")) if (col.Name.ToLower().Equals("testdate"))
{ {
@ -71,6 +72,15 @@
</Template> </Template>
</RadzenDataGridColumn> </RadzenDataGridColumn>
} }
else if (col.Name.ToLower().Contains("activate"))
{
<RadzenDataGridColumn Property="@col.Name" Title="@col.Name" Width="20rem">
<Template>
<RadzenCheckBox TValue="bool" Value="@Convert.ToBoolean(col.GetValue(context))">
</RadzenCheckBox>
</Template>
</RadzenDataGridColumn>
}
else else
{ {
<RadzenDataGridColumn Property="@col.Name" Title="@col.Name"> <RadzenDataGridColumn Property="@col.Name" Title="@col.Name">

View File

@ -90,16 +90,11 @@
<ChildContent> <ChildContent>
<RadzenStack Orientation="Orientation.Vertical"> <RadzenStack Orientation="Orientation.Vertical">
<RadzenStack Style="height: 5.6rem; font-size: 1.5rem;"> <RadzenStack Style="height: 5.6rem; font-size: 1.5rem;">
<RadzenCard class="rz-mb-3 rz-p-0"> <TitleCard HeaderText="Summary" ContentsHeight="2.9rem;">
<RadzenStack Style="width:100%; height:2.7rem; background-color:var(--rz-primary-lighter);" class="rz-pl-3"> @* <RadzenLabel class="rz-ml-10" Text="123"></RadzenLabel>
<RadzenLabel class="rz-p-1" Text="Summary"> <RadzenLabel class="rz-ml-10" Text="456"></RadzenLabel>
</RadzenLabel> <RadzenLabel class="rz-ml-10" Text="789"></RadzenLabel> *@
</RadzenStack> </TitleCard>
<RadzenStack Style="height: 2.9rem;" Orientation="Orientation.Horizontal" AlignItems="AlignItems.Center" JustifyContent="JustifyContent.Start">
<RadzenLabel class="rz-ml-10" Text=""></RadzenLabel>
<RadzenLabel class="rz-ml-10" Text=""></RadzenLabel>
</RadzenStack>
</RadzenCard>
</RadzenStack> </RadzenStack>
<RadzenStack Style="height:calc(100vh - 29rem);"> <RadzenStack Style="height:calc(100vh - 29rem);">
@ -140,25 +135,18 @@
<RadzenLabel Style="width:inherit; height: 5rem; min-height:5rem; background:var(--rz-danger); border: solid 2px var(--rz-grid-hover-color); overflow:auto;" class="rz-shadow-1" /> <RadzenLabel Style="width:inherit; height: 5rem; min-height:5rem; background:var(--rz-danger); border: solid 2px var(--rz-grid-hover-color); overflow:auto;" class="rz-shadow-1" />
} }
<RadzenCard Style="height: calc(100% - 5rem); overflow:hidden;" class="rz-p-0 rz-pb-2"> <TitleCard HeaderText="Test Information" ContentsHeight="calc(100% - 5rem);" CardStyle="overflow:auto;">
<RadzenStack Style="height:100%;"> <RadzenStack Style="padding:1rem; color: var(--rz-grid-hover-color); overflow-y:auto; align-items:flex-start;">
<!--header-->
<RadzenStack Style="width:100%; height:2.7rem; background-color:var(--rz-primary-lighter);" class="rz-pl-3">
<RadzenLabel class="rz-p-1" Text="Test Information">
</RadzenLabel>
</RadzenStack>
<!--info with scroll-->
<RadzenStack Style="padding:1rem; color: var(--rz-grid-hover-color); overflow-y:auto;">
@foreach (var prop in history.GetType().GetProperties()) @foreach (var prop in history.GetType().GetProperties())
{ {
<RadzenStack Style="width:100%; background-color:transparent;" class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Horizontal"> <RadzenStack Style="width:100%; background-color:transparent;" class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Horizontal">
<span style="width:12rem; min-width:12rem; font-size: 1.3rem;">@prop.Name</span> <span style="width:12rem; min-width:12rem; font-size: 1.3rem;">@prop.Name</span>
<span style="font-size:1.3rem; width:20rem; max-width:20rem; display:inline-block;white-space:normal;word-wrap:break-word;">@prop.GetValue(history)</span> <BlockLabel Text="@prop.GetValue(history).ToString()" MaxWidth="20rem"></BlockLabel>
</RadzenStack> </RadzenStack>
} }
</RadzenStack> </RadzenStack>
</RadzenStack> </TitleCard>
</RadzenCard>
<!--display TestList--> <!--display TestList-->
<RadzenButton ButtonStyle="ButtonStyle.Warning" Text="Display TestList" Click="@(() => OnClickDisplayTestList(history))"></RadzenButton> <RadzenButton ButtonStyle="ButtonStyle.Warning" Text="Display TestList" Click="@(() => OnClickDisplayTestList(history))"></RadzenButton>
} }

View File

@ -4,12 +4,104 @@
@page "/testlist/{ProductNo}/{TestCode}/{StepVersion}" @page "/testlist/{ProductNo}/{TestCode}/{StepVersion}"
@inject CPXV2LogService CPXV2LogService @inject CPXV2LogService CPXV2LogService
<RadzenStack Style="height:80vh;"> <RadzenStack Orientation="Orientation.Horizontal" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start" class="rz-p-2">
<TraGrid TDataModel="VRFY_TestListFileRelease" DataList="@GetTestList.TestListFile" <RadzenStack Style="font-size: 1.5rem; height:90vh;">
HostColumnMerge="false"> <TitleCard HeaderText="Test List" ContentsHeight="inherits;" CardStyle="overflow-y:auto;overflow-x:hidden;">
</TraGrid> <RadzenStack Style="width:40rem;" class="rz-p-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
@if(GetTestList?.StorTestListFile is not null)
{
<RadzenStack Style="width:40rem;">
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="TestListFileName"></RadzenLabel>
<BlockLabel Text="@GetTestList.StorTestListFile.FileName"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="TestListFileNo"></RadzenLabel>
<BlockLabel Text="@GetTestList.StorTestListFile.No.ToString()"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="TestType"></RadzenLabel>
<BlockLabel Text="@GetTestList.StorTestListFile.TestType"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="TestType"></RadzenLabel>
<BlockLabel Text="@GetTestList.StorTestListFile.Version"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="TestType"></RadzenLabel>
<BlockLabel Text="@GetTestList.StorTestListFile.ProdCode"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="Description"></RadzenLabel>
<BlockLabel Text="@GetTestList.StorTestListFile.Description"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="ProductGroupName"></RadzenLabel>
<BlockLabel Text="@GetTestList.ProdGroup.GroupName"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="ProductModelName"></RadzenLabel>
<BlockLabel Text="@GetTestList.ProdGroup.ModelName"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="ProductNo"></RadzenLabel>
<BlockLabel Text="@GetTestList.ProdRelease.ProdNo_C"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="TestCode"></RadzenLabel>
<BlockLabel Text="@($"{GetTestList.StatTestCode.TestCode} ({GetTestList.StatTestCode.No})")"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="ParentNo"></RadzenLabel>
<BlockLabel Text="@($"{GetTestList.ProdVariant.ProdNo_P}")"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="VariantNo"></RadzenLabel>
<BlockLabel Text="@GetTestList.ProdRelease.VariantNo.ToString()"></BlockLabel>
</RadzenStack>
<RadzenStack class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<RadzenLabel Text="StepVersion"></RadzenLabel>
<BlockLabel Text="@StepVersion"></BlockLabel>
</RadzenStack>
</RadzenStack>
}
else
{
<RadzenStack Style="width:40rem;">
<RadzenStack Style="color:red;" class="rz-border-bottom rz-p-1 rz-pb-2" Orientation="Orientation.Vertical" AlignItems="AlignItems.Start" JustifyContent="JustifyContent.Start">
<BlockLabel Text="Can't find TestList."></BlockLabel>
<BlockLabel Text="Check TestList parameters."></BlockLabel>
<br />
<BlockLabel Text="@($"ProductNo: {ProductNo}")"></BlockLabel>
<BlockLabel Text="@($"TestCode: {TestCode}")"></BlockLabel>
<BlockLabel Text="@($"StepVersion: {StepVersion}")"></BlockLabel>
</RadzenStack>
</RadzenStack>
}
</RadzenStack>
</TitleCard>
</RadzenStack>
<RadzenStack Style="height:90vh;" class="rz-pb-3">
<TraGrid TDataModel="VRFY_TestListFileRelease" DataList="@GetTestList.TestListFile"
HostColumnMerge="false">
</TraGrid>
</RadzenStack>
</RadzenStack> </RadzenStack>
@code { @code {
[Parameter] [Parameter]
public string ProductNo { get; set; } public string ProductNo { get; set; }