diff --git a/Test.UI/Components/App.razor b/Test.UI/Components/App.razor index d98f300..71febac 100644 --- a/Test.UI/Components/App.razor +++ b/Test.UI/Components/App.razor @@ -24,7 +24,7 @@ @* *@ - + diff --git a/WebWindowComplex/Compo/AreaSash.razor b/WebWindowComplex/Compo/AreaSash.razor index 09506c1..dd88553 100644 --- a/WebWindowComplex/Compo/AreaSash.razor +++ b/WebWindowComplex/Compo/AreaSash.razor @@ -3,17 +3,17 @@ @if (!SashDimEditList.Contains(IndexSash)) {
-
+
Sash @(CurrSashGroup.SashList.Count == 1 ? "" : (IndexSash + 1))
-
+
@if(!User && CurrSashGroup.SashList.Count > 1) { +
*@
@for (int i = 0; i < CurrSashGroup.SashList.Count; i++) { diff --git a/WebWindowComplex/Compo/CardSashGroup.razor.cs b/WebWindowComplex/Compo/CardSashGroup.razor.cs index 2d1724b..b1c61bf 100644 --- a/WebWindowComplex/Compo/CardSashGroup.razor.cs +++ b/WebWindowComplex/Compo/CardSashGroup.razor.cs @@ -194,14 +194,74 @@ namespace WebWindowComplex.Compo } } + protected MeasureTypes MeasureType + { + get + { + MeasureTypes type = CurrSashGroup.SashList.First().SelMeasureType; + for (int i = 1; i < CurrSashGroup.SashList.Count; i++) + { + if(CurrSashGroup.SashList.ElementAt(i).SelMeasureType != type) + return MeasureTypes.NULL; + } + return type; + } + set + { + for (int i = 0; i < CurrSashGroup.SashList.Count; i++) + { + CurrSashGroup.SashList.ElementAt(i).SelMeasureTypeIndex = (int)value; + } + var args = new DataUpdateSash + { + currSash = CurrSashGroup, + noSvg = true + }; + _= EC_UpdateSashGroup.InvokeAsync(args); + } + } + + protected int ChangeType + { + get + { + return CurrSashGroup.bIsDimensionLight ? 1 : 0; + } + set + { + if (value == 1) + CurrSashGroup.bIsDimensionLight = true; + else + CurrSashGroup.bIsDimensionLight = false; + foreach (var CurrSashDim in CurrSashGroup.SashList) + { + if (CurrSashDim.SelMeasureType is MeasureTypes.ABSOLUTE) + { + if (CurrSashGroup.bIsDimensionLight) + { + CurrSashDim.SetDimensionLight(CurrSashDim.dDimension - + CurrSashDim.ElementDimensionList.ElementAt(1).dDimension - + CurrSashDim.ElementDimensionList.Last().dDimension); + } + else + { + CurrSashDim.SetDimensionLight(CurrSashDim.dDimension + + CurrSashDim.ElementDimensionList.ElementAt(1).dDimension + + CurrSashDim.ElementDimensionList.Last().dDimension); + } + } + } + } + } + #endregion Protected Properties #region Protected Methods - /// - /// Metodo per rimuovere area corrente - /// - /// + /// + /// Metodo per rimuovere area corrente + /// + /// protected async Task RemoveArea() { CurrSashGroup.Remove(); @@ -264,20 +324,20 @@ namespace WebWindowComplex.Compo /// /// /// - protected Task SetMeasureType(MeasureTypes type) - { - //isOpen = !isOpen; - for (int i = 0; i < CurrSashGroup.SashList.Count; i++) - { - CurrSashGroup.SashList.ElementAt(i).SelMeasureTypeIndex = (int)type; - } - var args = new DataUpdateSash - { - currSash = CurrSashGroup, - noSvg = true - }; - return EC_UpdateSashGroup.InvokeAsync(args); - } + //protected Task SetMeasureType(MeasureTypes type) + //{ + // //isOpen = !isOpen; + // for (int i = 0; i < CurrSashGroup.SashList.Count; i++) + // { + // CurrSashGroup.SashList.ElementAt(i).SelMeasureTypeIndex = (int)type; + // } + // var args = new DataUpdateSash + // { + // currSash = CurrSashGroup, + // noSvg = true + // }; + // return EC_UpdateSashGroup.InvokeAsync(args); + //} /// /// Metodo per aggiornare la sash dimension diff --git a/WebWindowComplex/Compo/CardSplit.razor b/WebWindowComplex/Compo/CardSplit.razor index 0a8c083..11a8b3d 100644 --- a/WebWindowComplex/Compo/CardSplit.razor +++ b/WebWindowComplex/Compo/CardSplit.razor @@ -12,6 +12,41 @@
+ @*
+
+ Misure: +
+
+ +
+
+ +
+ + +
*@
Split
@if (!User) @@ -26,23 +61,34 @@
} - -
diff --git a/WebWindowComplex/Compo/CardSplit.razor.cs b/WebWindowComplex/Compo/CardSplit.razor.cs index afded47..e4980ac 100644 --- a/WebWindowComplex/Compo/CardSplit.razor.cs +++ b/WebWindowComplex/Compo/CardSplit.razor.cs @@ -261,6 +261,21 @@ namespace WebWindowComplex.Compo } } + protected async Task UpdateSplit(DataUpdateSplit updRec) + { + if (updRec.currSplit != null) + { + CurrSplit = updRec.currSplit; + var args = new DataUpdateSplit() + { + currSplit = CurrSplit, + noSvg = updRec.noSvg + }; + //await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape }); + await EC_UpdateSplit.InvokeAsync(args); + } + } + /// /// Metodo per cambiare la dimensione principale /// @@ -332,6 +347,48 @@ namespace WebWindowComplex.Compo isOpen = !isOpen; } + protected MeasureTypes MeasureType + { + get + { + MeasureTypes type = MeasureTypes.NULL; + if (CurrSplit.SplitVertList.Count > 0) + type = CurrSplit.SplitVertList.First().SelMeasureType; + else + type = CurrSplit.SplitHorizList.First().SelMeasureType; + for (int i = 1; i < CurrSplit.SplitVertList.Count; i++) + { + if (CurrSplit.SplitVertList.ElementAt(i).SelMeasureType != type) + return MeasureTypes.NULL; + } + for (int i = 1; i < CurrSplit.SplitHorizList.Count; i++) + { + if (CurrSplit.SplitHorizList.ElementAt(i).SelMeasureType != type) + return MeasureTypes.NULL; + } + return type; + } + set + { + foreach (var item in CurrSplit.SplitVertList) + { + item.SelMeasureType = value; + //item.SetSelMeasureType(type); + } + foreach (var item in CurrSplit.SplitHorizList) + { + item.SelMeasureType = value; + //item.SetSelMeasureType(type); + } + var args = new DataUpdateSplit() + { + currSplit = CurrSplit, + noSvg = true + }; + _= EC_UpdateSplit.InvokeAsync(args); + } + } + /// /// Metodo per cambiare il tipo di misura di tutti gli SplitDimension /// diff --git a/WebWindowComplex/TableComp.razor.cs b/WebWindowComplex/TableComp.razor.cs index cbb56e6..01d5263 100644 --- a/WebWindowComplex/TableComp.razor.cs +++ b/WebWindowComplex/TableComp.razor.cs @@ -397,7 +397,7 @@ namespace WebWindowComplex protected Task DoClose() { editLock = false; - Log.Info("Richietsa Chiusura"); + Log.Info("Richiesta Chiusura"); //return EC_OnClose.InvokeAsync(false); if (m_CurrWindow != null) { @@ -437,7 +437,7 @@ namespace WebWindowComplex // verifico variazione JWD if (!prevJwd.Equals(CurrJwd) || doForce || prevReq != (int)DataReq.ReqSvg) { - Log.Info("Richietsa svg"); + Log.Info("Richiesta svg"); prevJwd = CurrJwd; prevReq = (int)DataReq.ReqSvg; Dictionary Args = new Dictionary(); @@ -466,7 +466,7 @@ namespace WebWindowComplex // verifico variazione JWD if (!prevJwd.Equals(CurrJwd) || isFirst || prevReq != (int)DataReq.ReqHwOpt) { - Log.Info("Richietsa Hardware option"); + Log.Info("Richiesta Hardware option"); prevJwd = CurrJwd; prevReq = (int)DataReq.ReqHwOpt; Dictionary Args = new Dictionary(); @@ -498,7 +498,7 @@ namespace WebWindowComplex if (!prevJwd.Equals(CurrJwd) || prevReq != (int)DataReq.ReqShape) //if (!prevLiveData.CurrJwd.Equals(CurrJwd)) { - Log.Info("Richietsa shape"); + Log.Info("Richiesta shape"); prevJwd = CurrJwd; prevReq = (int)DataReq.ReqShape; Dictionary Args = new Dictionary(); @@ -528,7 +528,7 @@ namespace WebWindowComplex // verifico variazione JWD if (!prevJwd.Equals(CurrJwd) || prevReq != (int)DataReq.ReqElement) { - Log.Info("Richietsa Profili Elementi"); + Log.Info("Richiesta Profili Elementi"); prevJwd = CurrJwd; prevReq = (int)DataReq.ReqElement; Dictionary Args = new Dictionary(); @@ -547,7 +547,7 @@ namespace WebWindowComplex /// protected Task DoReset() { - Log.Info("Richietsa reset"); + Log.Info("Richiesta reset"); return Task.CompletedTask; // Da fare } @@ -559,7 +559,7 @@ namespace WebWindowComplex protected Task DoSave() { editLock = false; - Log.Info("Richietsa Salvataggio"); + Log.Info("Richiesta Salvataggio"); //return EC_OnClose.InvokeAsync(false); if (m_CurrWindow != null) { @@ -654,7 +654,7 @@ namespace WebWindowComplex { listErrLink.Add("Window", $"Deserializing Error:{Environment.NewLine}{ex}"); Log.Error($"Errore nel deserializzare jwd: {ex.Message}"); - // uso un oggetto "basico" per non fermarmi + // costruisco una finestra base WindowFromJson = BuildFrameDefault(); await DoPreviewSvg(true); } diff --git a/WebWindowComplex/WebWindowComplex.csproj b/WebWindowComplex/WebWindowComplex.csproj index 4410efe..d3f70a6 100644 --- a/WebWindowComplex/WebWindowComplex.csproj +++ b/WebWindowComplex/WebWindowComplex.csproj @@ -6,7 +6,7 @@ net8.0 enable enable - 3.1.3.616 + 3.1.3.915 Annamaria Sassi Egalware Componente gestione Configurazioni avanzate Window per LUX @@ -316,6 +316,8 @@ + + diff --git a/WebWindowConfigurator/WebWindowConfigurator.csproj b/WebWindowConfigurator/WebWindowConfigurator.csproj index 5e2f2e7..2234894 100644 --- a/WebWindowConfigurator/WebWindowConfigurator.csproj +++ b/WebWindowConfigurator/WebWindowConfigurator.csproj @@ -6,7 +6,7 @@ net8.0 enable enable - 3.1.3.616 + 3.1.3.915 Annamaria Sassi Egalware Componente gestione JWD per LUX @@ -297,6 +297,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +