Loading hw option
This commit is contained in:
@@ -9,9 +9,6 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
@if (!hwOptCollapsed)
|
||||
{
|
||||
@* @if (IsLoadingHwOpt && CurrSash.HwOptionList.Count == 0) *@
|
||||
@if (IsLoadingHwOpt)
|
||||
{
|
||||
<EgwCoreLib.Razor.LoadingData DisplaySize="EgwCoreLib.Razor.LoadingData.CtrlSize.Small"></EgwCoreLib.Razor.LoadingData>
|
||||
@@ -37,5 +34,7 @@
|
||||
}
|
||||
}
|
||||
</div>
|
||||
}
|
||||
@* @if (!hwOptCollapsed)
|
||||
{
|
||||
} *@
|
||||
</div>
|
||||
@@ -32,22 +32,22 @@ namespace WebWindowComplex.Compo
|
||||
[Parameter]
|
||||
public EventCallback<int> EC_FirstHwOptionList { get; set; }
|
||||
|
||||
[Parameter]
|
||||
public bool IsLoadingHwOpt { get; set; } = false;
|
||||
[CascadingParameter(Name = "IsLoading")]
|
||||
public List<string> IsLoading { get; set; }
|
||||
|
||||
private bool hwOptCollapsed { get; set; } = true;
|
||||
private bool hwOptCollapsed { get; set; } = false;
|
||||
|
||||
protected override void OnAfterRender(bool firstRender)
|
||||
{
|
||||
if(firstRender)
|
||||
{
|
||||
hwOptCollapsed = true;
|
||||
}
|
||||
}
|
||||
//protected override void OnAfterRender(bool firstRender)
|
||||
//{
|
||||
// if(firstRender)
|
||||
// {
|
||||
// hwOptCollapsed = true;
|
||||
// }
|
||||
//}
|
||||
|
||||
private async Task changeCollapsed()
|
||||
{
|
||||
hwOptCollapsed = !hwOptCollapsed;
|
||||
//hwOptCollapsed = !hwOptCollapsed;
|
||||
if (CurrSash.HwOptionList.Count == 0)
|
||||
{
|
||||
//IsLoadingHwOpt = true;
|
||||
@@ -79,6 +79,9 @@ namespace WebWindowComplex.Compo
|
||||
{
|
||||
await EC_UpdateHwOptText.InvokeAsync(updRec);
|
||||
}
|
||||
|
||||
private bool IsLoadingHwOpt
|
||||
{
|
||||
get => IsLoading != null && IsLoading.Count > 0 && IsLoading.Contains("LoadHwOpt");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -92,7 +92,6 @@
|
||||
</select>
|
||||
</div>
|
||||
<AreaHwOption CurrSash="CurrItem"
|
||||
IsLoadingHwOpt="isLoadingHwOpt"
|
||||
EC_UpdateHwOptCombo="UpdateOptCombo"
|
||||
EC_UpdateHwOptText="UpdateOptText"
|
||||
EC_FirstHwOptionList="FirstHwOptionList">
|
||||
|
||||
@@ -80,9 +80,6 @@ namespace WebWindowComplex.Compo
|
||||
[Parameter]
|
||||
public List<Sash> SashList { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public bool isLoadingHwOpt { get; set; } = false;
|
||||
|
||||
#endregion Public Properties
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
@@ -118,10 +118,10 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
<CardSashGroup CurrIndex="currSash"
|
||||
<CascadingValue Value="currLoading" Name="IsLoading">
|
||||
<CardSashGroup CurrIndex="currSash"
|
||||
CurrItem="SashList[currSash]"
|
||||
SashList="m_SashList"
|
||||
isLoadingHwOpt="isLoadingHwOpt"
|
||||
SashList="SashList"
|
||||
EC_ChangeAllJoints="ChangeAllJoints"
|
||||
EC_ChangeHandle="ChangeHandle"
|
||||
EC_CopyContentSash="CopyContentSash"
|
||||
@@ -131,7 +131,8 @@
|
||||
EC_CallFirstHwOpt="CallFirstHwOpt"
|
||||
EC_ReqResetDictShape="ReqResetDict"
|
||||
EC_ReqClose="ReturnTree">
|
||||
</CardSashGroup>
|
||||
</CardSashGroup>
|
||||
</CascadingValue>
|
||||
}
|
||||
}
|
||||
else if (currStep == CompileStep.Fill)
|
||||
|
||||
@@ -164,6 +164,7 @@ namespace WebWindowComplex
|
||||
get => m_SashList;
|
||||
}
|
||||
|
||||
protected List<string> currLoading = new List<string>();
|
||||
protected string SelColorMaterial { get; set; } = "";
|
||||
protected string SelFamilyHardware { get; set; } = "";
|
||||
protected string SelGlass { get; set; } = "";
|
||||
@@ -502,7 +503,7 @@ namespace WebWindowComplex
|
||||
{
|
||||
if (m_CurrWindow != null)
|
||||
{
|
||||
isLoadingHwOpt = true;
|
||||
currLoading.Add("LoadHwOpt");
|
||||
#if DEBUG
|
||||
var CurrJwd = JsonConvert.SerializeObject(m_CurrWindow.Serialize(), Formatting.Indented);
|
||||
#else
|
||||
@@ -717,7 +718,6 @@ namespace WebWindowComplex
|
||||
}
|
||||
if (SashList.Count > 0)
|
||||
currAnta = 0;
|
||||
isLoadingHwOpt = false;
|
||||
#if false
|
||||
_ = InvokeAsync(StateHasChanged);
|
||||
#endif
|
||||
@@ -744,6 +744,7 @@ namespace WebWindowComplex
|
||||
// se ho le opzioni hw le aggiungo
|
||||
if (LiveData.DictOptionsXml.Count > 0)
|
||||
{
|
||||
currLoading.Remove("LoadHwOpt");
|
||||
foreach (var item in SashList)
|
||||
{
|
||||
if (LiveData.DictOptionsXml.ContainsKey(item.GroupId))
|
||||
@@ -806,8 +807,6 @@ namespace WebWindowComplex
|
||||
|
||||
private bool isRendered = false;
|
||||
|
||||
private bool isLoadingHwOpt = false;
|
||||
|
||||
/// <summary>
|
||||
/// ELenco errori di coerenza/link dati (vanno risolti per disegnare/procedere)
|
||||
/// </summary>
|
||||
@@ -1088,7 +1087,8 @@ namespace WebWindowComplex
|
||||
|
||||
private void M_CurrWindow_OnHwOption(object? sender, OnReqHwOptEventArgs e)
|
||||
{
|
||||
isLoadingHwOpt = true;
|
||||
currLoading.Add("LoadHwOpt");
|
||||
_ = InvokeAsync(StateHasChanged);
|
||||
Dictionary<string, string> Args = new Dictionary<string, string>();
|
||||
Args.Add("Mode", $"{(int)Enums.QuestionModes.HARDWARE}");
|
||||
Args.Add("SubMode", $"{(int)Enums.QuestionHwSubModes.HARDWAREOPTIONS}");
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Version>2.7.11.1016</Version>
|
||||
<Version>2.7.11.1109</Version>
|
||||
<Authors>Annamaria Sassi</Authors>
|
||||
<Company>Egalware</Company>
|
||||
<Description>Componente gestione Configurazioni avanzate Window per LUX</Description>
|
||||
@@ -39,6 +39,16 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user