Add beam shear converting to DTO
This commit is contained in:
@@ -19,12 +19,18 @@
|
||||
<TabItem Header="General">
|
||||
<StackPanel>
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="25"/>
|
||||
<RowDefinition Height="25"/>
|
||||
<RowDefinition/>
|
||||
</Grid.RowDefinitions>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="100"/>
|
||||
<ColumnDefinition Width="150"/>
|
||||
<ColumnDefinition Width="300"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="Name"/>
|
||||
<TextBox Grid.Column="1" Text="{Binding Name}"/>
|
||||
<CheckBox Grid.Row="1" Content="Show trace data" IsChecked="{Binding ShowTraceData}"/>
|
||||
</Grid>
|
||||
</StackPanel>
|
||||
|
||||
|
||||
@@ -1,14 +1,9 @@
|
||||
using StructureHelper.Infrastructure.UI.DataContexts;
|
||||
using StructureHelper.Windows.ViewModels;
|
||||
using StructureHelperCommon.Infrastructures.Enums;
|
||||
using StructureHelperCommon.Models.Forces;
|
||||
using StructureHelperLogics.NdmCalculations.Cracking;
|
||||
using StructureHelperLogics.NdmCalculations.Primitives;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace StructureHelper.Windows.CalculationWindows.CalculatorsViews
|
||||
{
|
||||
@@ -16,9 +11,6 @@ namespace StructureHelper.Windows.CalculationWindows.CalculatorsViews
|
||||
{
|
||||
private CrackCalculator calculator;
|
||||
ICrackCalculatorInputData crackInputData;
|
||||
private bool setUserValueSofteningFactor;
|
||||
private double softeningFactor;
|
||||
private string name;
|
||||
|
||||
public SourceTargetVM<IForceAction> CombinationViewModel { get; }
|
||||
public SourceTargetVM<PrimitiveBase> PrimitivesViewModel { get; private set; }
|
||||
@@ -33,6 +25,21 @@ namespace StructureHelper.Windows.CalculationWindows.CalculatorsViews
|
||||
OnPropertyChanged(nameof(WindowTitle));
|
||||
}
|
||||
}
|
||||
|
||||
public bool ShowTraceData
|
||||
{
|
||||
get
|
||||
{
|
||||
return calculator.ShowTraceData;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
calculator.ShowTraceData = value;
|
||||
OnPropertyChanged(nameof(ShowTraceData));
|
||||
}
|
||||
}
|
||||
|
||||
public bool SetSofteningFactor
|
||||
{
|
||||
get => crackInputData.UserCrackInputData.SetSofteningFactor;
|
||||
|
||||
@@ -88,16 +88,21 @@
|
||||
</Grid.RowDefinitions>
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="25"/>
|
||||
<RowDefinition Height="50"/>
|
||||
<RowDefinition/>
|
||||
</Grid.RowDefinitions>
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="25"/>
|
||||
<RowDefinition/>
|
||||
</Grid.RowDefinitions>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="100"/>
|
||||
<ColumnDefinition Width="120"/>
|
||||
<ColumnDefinition Width="300"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="Name"/>
|
||||
<TextBox Grid.Column="1" Text="{Binding Name}"/>
|
||||
<CheckBox Grid.Row="1" Content="Show trace data" IsChecked="{Binding ShowTraceData}"/>
|
||||
</Grid>
|
||||
<ContentControl Grid.Row="1" ContentTemplate="{StaticResource InputDataTemplate}" Content="{Binding InputData}" />
|
||||
</Grid>
|
||||
|
||||
@@ -17,11 +17,30 @@ namespace StructureHelper.Windows.ViewModels.Calculations.Calculators
|
||||
public class ForceCalculatorViewModel : OkCancelViewModelBase
|
||||
{
|
||||
IForceCalculator forcesCalculator;
|
||||
private bool showTraceData;
|
||||
|
||||
public string Name
|
||||
{
|
||||
get { return forcesCalculator.Name; }
|
||||
set { forcesCalculator.Name = value; }
|
||||
set
|
||||
{
|
||||
forcesCalculator.Name = value;
|
||||
OnPropertyChanged(nameof(Name));
|
||||
}
|
||||
}
|
||||
|
||||
public bool ShowTraceData
|
||||
{
|
||||
get
|
||||
{
|
||||
return forcesCalculator.ShowTraceData;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
forcesCalculator.ShowTraceData = value;
|
||||
OnPropertyChanged(nameof(ShowTraceData));
|
||||
}
|
||||
}
|
||||
|
||||
public ForceCalculatorInputDataVM InputData { get; }
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
</Grid.RowDefinitions>
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="25"/>
|
||||
<RowDefinition Height="25"/>
|
||||
<RowDefinition/>
|
||||
</Grid.RowDefinitions>
|
||||
@@ -24,7 +25,8 @@
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="Name"/>
|
||||
<TextBox Grid.Column="1" Text="{Binding Name}"/>
|
||||
<fc:LimitCurveControl Grid.Row="1" Grid.ColumnSpan="2" x:Name="CurveData" LimitCurveViewModel="{Binding LimitCurveDataViewModel}"/>
|
||||
<CheckBox Grid.Row="1" Content="Show trace data" IsChecked="{Binding ShowTraceData}"/>
|
||||
<fc:LimitCurveControl Grid.Row="2" Grid.ColumnSpan="2" x:Name="CurveData" LimitCurveViewModel="{Binding LimitCurveDataViewModel}"/>
|
||||
</Grid>
|
||||
<ContentControl Grid.Row="1" ContentTemplate="{StaticResource OkCancelButtons}" Content="{Binding}"/>
|
||||
</Grid>
|
||||
|
||||
@@ -1,13 +1,8 @@
|
||||
using StructureHelper.Windows.CalculationWindows.CalculatorsViews.ForceCalculatorViews.ForceResultLogic;
|
||||
using StructureHelper.Windows.ViewModels;
|
||||
using StructureHelperLogics.NdmCalculations.Analyses.ByForces;
|
||||
using StructureHelperLogics.NdmCalculations.Analyses.ByForces.LimitCurve;
|
||||
using StructureHelperLogics.NdmCalculations.Primitives;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
//Copyright (c) 2023 Redikultsev Evgeny, Ekaterinburg, Russia
|
||||
//All rights reserved.
|
||||
@@ -26,6 +21,20 @@ namespace StructureHelper.Windows.CalculationWindows.CalculatorsViews.ForceCalcu
|
||||
OnPropertyChanged(nameof(Name));
|
||||
}
|
||||
}
|
||||
public bool ShowTraceData
|
||||
{
|
||||
get
|
||||
{
|
||||
return calculator.ShowTraceData;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
calculator.ShowTraceData = value;
|
||||
OnPropertyChanged(nameof(ShowTraceData));
|
||||
}
|
||||
}
|
||||
|
||||
public LimitCurveDataViewModel LimitCurveDataViewModel { get; }
|
||||
public LimitCurveCalculatorViewModel(LimitCurvesCalculator calculator, IEnumerable<INdmPrimitive> allowedPrimitives)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user