Optimizer 2.7.10.7
-creato nuove tabelle statistiche con nuovo metodo
This commit is contained in:
@@ -48,7 +48,7 @@
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type GroupItem}">
|
||||
<Expander IsExpanded="True"
|
||||
<Expander IsExpanded="True" HorizontalAlignment="Left"
|
||||
Width="{Binding ActualWidth, Converter={StaticResource ExpanderWidthConverter}, RelativeSource={RelativeSource AncestorType={x:Type EgwWPFBaseLib:EgwDataGrid}}}">
|
||||
<Expander.Header>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
|
||||
@@ -1,138 +0,0 @@
|
||||
<UserControl x:Class="FeatureListV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
|
||||
<Grid Margin="5">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<EgtBEAMWALLCORE:EgtDataGrid ItemsSource="{Binding Tag.BTLFeatureVMList, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureListV}}}"
|
||||
SelectedItem="{Binding Tag.SelBTLFeatureVM, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureListV}}}"
|
||||
SelectionMode="Single"
|
||||
Margin="0,0,0,5"
|
||||
IsEnabled="{Binding FeatureList_IsEnabled}"
|
||||
BindingColumns="{Binding FeatureColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderStyle="{StaticResource Feature_DataGridColumnHeader}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
Style="{StaticResource DataGrid_OnlyProd}">
|
||||
|
||||
<DataGrid.Resources>
|
||||
<!--DO - Abilitazione-->
|
||||
<DataGridTemplateColumn x:Key="colDO">
|
||||
<DataGridTemplateColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<CheckBox IsChecked="{Binding Path=Tag.bDOALL, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureListV}}}"
|
||||
VerticalAlignment="Center"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.HeaderTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<CheckBox IsChecked="{Binding bDO, UpdateSourceTrigger=PropertyChanged}"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Validità feature-->
|
||||
<DataGridTemplateColumn x:Key="colCALC">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="10"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Border Width="{Binding ActualHeight, RelativeSource={RelativeSource self}}"
|
||||
Background="{Binding Calc_Background}"/>
|
||||
<Grid Grid.Column="1">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Ellipse Visibility="{Binding CALC_ROT_Visibility}"
|
||||
Style="{StaticResource OnlyProdFeatureInPartInRawPartList_Ellipse}"/>
|
||||
<TextBlock Grid.Row="1"
|
||||
Text="{Binding CALC_ERR_Letter}"
|
||||
Style="{StaticResource OnlyProdFeatureInPartInRawPartList_TextBlock}"/>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Descrizione-->
|
||||
<DataGridTextColumn x:Key="colDESC" Binding="{Binding sDesc}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding DataContext.Description_Msg,RelativeSource={RelativeSource AncestorType={x:Type DataGrid}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
<DataGridTextColumn.CellStyle>
|
||||
<Style TargetType="{x:Type DataGridCell}" BasedOn="{StaticResource CellDataGrid_CustomHighLight}">
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type DataGridCell}">
|
||||
<TextBlock Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Content.Text}"
|
||||
Style="{StaticResource OnlyProd_TextBlock}">
|
||||
<TextBlock.ToolTip>
|
||||
<ToolTip Style="{StaticResource OnlyProd_ToolTip}">
|
||||
<ToolTip.Content>
|
||||
<StackPanel Orientation="Vertical">
|
||||
<TextBlock Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Content.Text}"/>
|
||||
<Image Source="{Binding sDrawPath}"
|
||||
Style="{StaticResource OnlyProdFeatureList_Image}"/>
|
||||
</StackPanel>
|
||||
</ToolTip.Content>
|
||||
</ToolTip>
|
||||
</TextBlock.ToolTip>
|
||||
</TextBlock>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
</DataGridTextColumn.CellStyle>
|
||||
</DataGridTextColumn>
|
||||
<!-- Menu' tasto destro -->
|
||||
<ContextMenu x:Key="RowMenu" ItemsSource="{Binding MenuList}">
|
||||
<ContextMenu.ItemContainerStyle>
|
||||
<Style TargetType="MenuItem">
|
||||
<Setter Property="Command" Value="{Binding MenuItem_Command}"/>
|
||||
<Setter Property="Header" Value="{Binding sMsg}"/>
|
||||
</Style>
|
||||
</ContextMenu.ItemContainerStyle>
|
||||
</ContextMenu>
|
||||
</DataGrid.Resources>
|
||||
<DataGrid.InputBindings>
|
||||
<KeyBinding Key="Delete" Command="{Binding Tag.SelBTLFeatureVM.DeleteFeature_Command,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureListV}}}" />
|
||||
</DataGrid.InputBindings>
|
||||
<DataGrid.RowStyle>
|
||||
<Style TargetType="DataGridRow" BasedOn="{StaticResource RowDataGrid_CustomHighLight}">
|
||||
<Setter Property="ContextMenu" Value="{StaticResource RowMenu}" />
|
||||
<EventSetter Event="PreviewMouseDown" Handler="FeatureList_PreviewMouseDown"/>
|
||||
</Style>
|
||||
</DataGrid.RowStyle>
|
||||
|
||||
</EgtBEAMWALLCORE:EgtDataGrid>
|
||||
|
||||
<StackPanel Grid.Row="1"
|
||||
HorizontalAlignment="Right"
|
||||
Style="{StaticResource OnlyProdPartManager_StackPanel}">
|
||||
<Button Command="{Binding Ok_Command}"
|
||||
ToolTip="{Binding Ok_Msg}"
|
||||
Style="{StaticResource ToolBarViewPanel_Button}">
|
||||
<Image Source="/Resources/NewPage/Ok.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button Command="{Binding Cancel_Command}"
|
||||
ToolTip="{Binding Cancel_Msg}"
|
||||
Style="{StaticResource ToolBarViewPanel_Button}">
|
||||
<Image Source="/Resources/PDFEditor/Delete.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
|
||||
</UserControl>
|
||||
@@ -1,12 +0,0 @@
|
||||
Public Class FeatureListV
|
||||
|
||||
Private Sub FeatureList_PreviewMouseDown(sender As Object, e As MouseButtonEventArgs)
|
||||
If TypeOf sender Is DataGridRow Then
|
||||
Dim Row As DataGridRow = DirectCast(sender, DataGridRow)
|
||||
If Not IsNothing(Row) AndAlso Row.IsSelected AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then
|
||||
Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM = Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
@@ -1,145 +0,0 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class FeatureListVM
|
||||
Inherits VMBase
|
||||
|
||||
#Region "FIELDS & PROPERTIES"
|
||||
|
||||
Private m_colFeature_Do As EgtDataGridColumn
|
||||
Public ReadOnly Property colFeature_Do As EgtDataGridColumn
|
||||
Get
|
||||
Return m_colFeature_Do
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_FeatureColumns As New ObservableCollection(Of EgtDataGridColumn)
|
||||
Public Property FeatureColumns As ObservableCollection(Of EgtDataGridColumn)
|
||||
Get
|
||||
Return m_FeatureColumns
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of EgtDataGridColumn))
|
||||
m_FeatureColumns = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_FeatureList_IsEnabled As Boolean = True
|
||||
Public Property FeatureList_IsEnabled As Boolean
|
||||
Get
|
||||
Return m_FeatureList_IsEnabled
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_FeatureList_IsEnabled = value
|
||||
End Set
|
||||
End Property
|
||||
Friend Sub SetBTLFeatureListIsEnabled(bIsEnabled As Boolean)
|
||||
m_FeatureList_IsEnabled = bIsEnabled
|
||||
NotifyPropertyChanged(NameOf(FeatureList_IsEnabled))
|
||||
End Sub
|
||||
|
||||
#Region "Messages"
|
||||
|
||||
Public ReadOnly Property Description_Msg As String
|
||||
Get
|
||||
Return EgtMsg(61603)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property DO_Msg As String
|
||||
Get
|
||||
Return EgtMsg(61610)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property Ok_Msg As String
|
||||
Get
|
||||
Return EgtMsg(61761)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property Cancel_Msg_Msg As String
|
||||
Get
|
||||
Return EgtMsg(61763)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
#End Region ' Messages
|
||||
|
||||
' Definizione Comandi
|
||||
Private m_cmdOk As ICommand
|
||||
Private m_cmdCancel As ICommand
|
||||
|
||||
#End Region ' Fields & Properties
|
||||
|
||||
#Region "CONSTRUCTOR"
|
||||
|
||||
Sub New()
|
||||
' creo riferimento in Map
|
||||
Map.SetRefFeatureListVM(Me)
|
||||
' carico le colonne della datagrid
|
||||
GetPrivateProfileColumns(S_FEATURELIST, FeatureColumns)
|
||||
' recupero riferimento a colonna Do
|
||||
m_colFeature_Do = FeatureColumns.FirstOrDefault(Function(x) x.Name = COL_DO)
|
||||
End Sub
|
||||
|
||||
#End Region ' Constructor
|
||||
|
||||
#Region "COMMANDS"
|
||||
|
||||
#Region "Ok_Command"
|
||||
|
||||
Public ReadOnly Property Ok_Command As ICommand
|
||||
Get
|
||||
If m_cmdOk Is Nothing Then
|
||||
m_cmdOk = New Command(AddressOf Ok)
|
||||
End If
|
||||
Return m_cmdOk
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public Sub Ok()
|
||||
'Map.refForcedStrategyBTLVM.ForcedStrategy()
|
||||
Map.refForcedStrategyPanelVM.ForcedStrategy()
|
||||
|
||||
Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM.ResetCalcFeature()
|
||||
Map.refProjectVM.BTLStructureVM.SelBTLPart.ResetCalcPart()
|
||||
|
||||
Map.refProjectVM.SetRawPartManagerVisibility(Visibility.Visible)
|
||||
Map.refProjectVM.SetStrategyManagerVisibility(Visibility.Collapsed)
|
||||
Map.refProjectVM.SetSelManagerTab(ProjectVM.StrategyManagerTab.RAWPARTMANAGER)
|
||||
Map.refProjectVM.SetSelFeatureManagerTab(ProjectVM.FeatureManagerTab.FEATURERAWPARTMANAGER)
|
||||
' Abilito LeftPanel
|
||||
Map.refProjectVM.SetOnlyProdLeftPanel_IsEnabled(True)
|
||||
Map.refProjectVM.SetOnlyProdLeftPanel_Opacity(1)
|
||||
End Sub
|
||||
|
||||
#End Region ' Ok_Command
|
||||
|
||||
#Region "Cancel_Command"
|
||||
|
||||
Public ReadOnly Property Cancel_Command As ICommand
|
||||
Get
|
||||
If m_cmdCancel Is Nothing Then
|
||||
m_cmdCancel = New Command(AddressOf Cancel)
|
||||
End If
|
||||
Return m_cmdCancel
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public Sub Cancel()
|
||||
Map.refProjectVM.SetRawPartManagerVisibility(Visibility.Visible)
|
||||
Map.refProjectVM.SetStrategyManagerVisibility(Visibility.Collapsed)
|
||||
Map.refProjectVM.SetSelManagerTab(ProjectVM.StrategyManagerTab.RAWPARTMANAGER)
|
||||
Map.refProjectVM.SetSelFeatureManagerTab(ProjectVM.FeatureManagerTab.FEATURERAWPARTMANAGER)
|
||||
' Abilito LeftPanel
|
||||
Map.refProjectVM.SetOnlyProdLeftPanel_IsEnabled(True)
|
||||
Map.refProjectVM.SetOnlyProdLeftPanel_Opacity(1)
|
||||
End Sub
|
||||
|
||||
#End Region ' Cancel_Command
|
||||
|
||||
#End Region ' Commands
|
||||
|
||||
End Class
|
||||
@@ -408,7 +408,10 @@ Public Class MainWindowVM
|
||||
{S_RAWPARTLIST_BEAM, Map.refRawPartListVM.RawPartColumns},
|
||||
{S_PARTINRAWPARTLIST_BEAM, Map.refRawPartListVM.PartInRawPartColumns},
|
||||
{S_FEATUREINPARTINRAWPARTLIST, Map.refFeatureInPartInRawPartListVM.FeatureInPartInRawPartColumns},
|
||||
{S_PARAMETERLIST_P, Map.refPParameterListVM.PParameterListColumns}}
|
||||
{S_PARAMETERLIST_P, Map.refPParameterListVM.PParameterListColumns},
|
||||
{S_STATISTICS, Map.refStatisticsVM.StatisticsColumns},
|
||||
{S_OPTIMIZERSTATISTICS, Map.refStatisticsVM.OptimizerStatisticsColumns},
|
||||
{S_RAWPARTSTATISTICS, Map.refStatisticsVM.RawPartStatisticsColumns}}
|
||||
EgwWPFBaseLib.EgwDataGrid.WriteColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), DataGridColumnDictionary)
|
||||
' Termino il Model
|
||||
m_MainWindowM.Close()
|
||||
|
||||
@@ -67,5 +67,5 @@ Imports System.Windows
|
||||
' Revision
|
||||
'
|
||||
|
||||
<Assembly: AssemblyVersion("2.7.10.6")>
|
||||
<Assembly: AssemblyVersion("2.7.10.7")>
|
||||
<Assembly: AssemblyFileVersion("2.7.10.6")>
|
||||
|
||||
@@ -528,9 +528,6 @@ Public Class ProjectVM
|
||||
|
||||
#Region "Visualization"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Open.
|
||||
''' </summary>
|
||||
Public ReadOnly Property Visualization_Command As ICommand
|
||||
Get
|
||||
If m_cmdVisualization Is Nothing Then
|
||||
@@ -540,9 +537,6 @@ Public Class ProjectVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Open. This method is invoked by the OpenCommand.
|
||||
''' </summary>
|
||||
Friend Sub Visualization()
|
||||
Dim StatisticsWndV As New StatisticsWndV(Application.Current.MainWindow, New StatisticsVM())
|
||||
StatisticsWndV.ShowDialog()
|
||||
@@ -552,9 +546,6 @@ Public Class ProjectVM
|
||||
|
||||
#Region "Ottimization"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Open.
|
||||
''' </summary>
|
||||
Public ReadOnly Property Optimizer_Command As ICommand
|
||||
Get
|
||||
If m_cmdOptimizer Is Nothing Then
|
||||
@@ -564,9 +555,6 @@ Public Class ProjectVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Open. This method is invoked by the OpenCommand.
|
||||
''' </summary>
|
||||
Friend Sub Optimizer()
|
||||
Dim OptimizerStatisticsWndV As New OptimizerStatisticsWndV(Application.Current.MainWindow, New StatisticsVM())
|
||||
OptimizerStatisticsWndV.ShowDialog()
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<UserControl x:Class="OptimizerStatisticsV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer"
|
||||
xmlns:EgwWPFBaseLib="clr-namespace:EgwWPFBaseLib;assembly=EgwWPFBaseLib">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
@@ -17,24 +17,24 @@
|
||||
|
||||
<TabItem Header="OPTIMIZERSTATS">
|
||||
<TabItem.Content>
|
||||
<EgtBEAMWALLCORE:EgtDataGrid x:Name="dgOptimizerStatistics"
|
||||
ItemsSource="{Binding Tag.MachGroupPanelVM.MachGroupVMList,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:OptimizerStatisticsV}}}"
|
||||
CanUserAddRows="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Extended"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,5"
|
||||
BindingColumns="{Binding OptimizerStatisticsColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
|
||||
Style="{StaticResource DataGrid_OnlyProd}">
|
||||
<EgwWPFBaseLib:EgwDataGrid x:Name="dgOptimizerStatistics"
|
||||
ItemsSource="{Binding Tag.MachGroupPanelVM.MachGroupVMList,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:OptimizerStatisticsV}}}"
|
||||
CanUserAddRows="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Extended"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,5"
|
||||
ColumnLayouts="{Binding OptimizerStatisticsColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
|
||||
Style="{StaticResource DataGrid_OnlyProd}">
|
||||
<DataGrid.Resources>
|
||||
<!--Id - Nome-->
|
||||
<DataGridTextColumn x:Key="colNAME" Binding="{Binding Name}" SortMemberPath="nName">
|
||||
@@ -105,29 +105,29 @@
|
||||
|
||||
</DataGrid.Resources>
|
||||
|
||||
</EgtBEAMWALLCORE:EgtDataGrid>
|
||||
</EgwWPFBaseLib:EgwDataGrid>
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
|
||||
<TabItem Header="RAWPARTSTAT">
|
||||
<TabItem.Content>
|
||||
<EgtBEAMWALLCORE:EgtDataGrid x:Name="dgRawPartStatistics"
|
||||
ItemsSource="{Binding RawPartList}"
|
||||
CanUserAddRows="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Extended"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,5"
|
||||
BindingColumns="{Binding RawPartStatisticsColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
|
||||
Style="{StaticResource DataGrid_OnlyProd}">
|
||||
<EgwWPFBaseLib:EgwDataGrid x:Name="dgRawPartStatistics"
|
||||
ItemsSource="{Binding RawPartList}"
|
||||
CanUserAddRows="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Extended"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,5"
|
||||
ColumnLayouts="{Binding RawPartStatisticsColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
|
||||
Style="{StaticResource DataGrid_OnlyProd}">
|
||||
<DataGrid.Resources>
|
||||
<!--W - Larghezza-->
|
||||
<DataGridTextColumn x:Key="colW" Binding="{Binding sW}">
|
||||
@@ -170,7 +170,7 @@
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
</DataGrid.Resources>
|
||||
</EgtBEAMWALLCORE:EgtDataGrid>
|
||||
</EgwWPFBaseLib:EgwDataGrid>
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
|
||||
|
||||
@@ -2,30 +2,30 @@
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
xmlns:EgwWPFBaseLib="clr-namespace:EgwWPFBaseLib;assembly=EgwWPFBaseLib">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<EgtBEAMWALLCORE:EgtDataGrid x:Name="dgStatistics"
|
||||
ItemsSource="{Binding Tag.BTLPartVMList,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:StatisticsV}}}"
|
||||
CanUserAddRows="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Extended"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,5"
|
||||
BindingColumns="{Binding StatisticsColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
|
||||
Style="{StaticResource DataGrid_OnlyProd}">
|
||||
<EgwWPFBaseLib:EgwDataGrid x:Name="dgStatistics"
|
||||
ItemsSource="{Binding Tag.BTLPartVMList,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:StatisticsV}}}"
|
||||
CanUserAddRows="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Extended"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,5"
|
||||
ColumnLayouts="{Binding StatisticsColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
|
||||
Style="{StaticResource DataGrid_OnlyProd}">
|
||||
<DataGrid.Resources>
|
||||
<!--PDN - Nome-->
|
||||
<DataGridTextColumn x:Key="colPDN" Binding="{Binding nPDN}">
|
||||
@@ -142,7 +142,7 @@
|
||||
|
||||
</DataGrid.Resources>
|
||||
|
||||
</EgtBEAMWALLCORE:EgtDataGrid>
|
||||
</EgwWPFBaseLib:EgwDataGrid>
|
||||
|
||||
<Grid Grid.Row="1" Background="{StaticResource BeamWall_Glacier}">
|
||||
<Grid.ColumnDefinitions>
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.Windows.Forms
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
@@ -11,7 +12,8 @@ Public Class StatisticsVM
|
||||
|
||||
#Region "FIELDS & PROPERTIES"
|
||||
|
||||
Friend Event m_CloseWindow(bDialogResult As Boolean)
|
||||
' Evento per chiusura finestra
|
||||
Public Event m_CloseWindow(bDialogResult As DialogResult)
|
||||
|
||||
Public Enum StatisticsTab As Integer
|
||||
OPTIMIZER = 0
|
||||
@@ -44,32 +46,32 @@ Public Class StatisticsVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_StatisticsColumns As New ObservableCollection(Of EgtDataGridColumn)
|
||||
Public Property StatisticsColumns As ObservableCollection(Of EgtDataGridColumn)
|
||||
Private m_StatisticsColumns As New ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)
|
||||
Public Property StatisticsColumns As ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)
|
||||
Get
|
||||
Return m_StatisticsColumns
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of EgtDataGridColumn))
|
||||
Set(value As ObservableCollection(Of EgwWPFBaseLib.ColumnLayout))
|
||||
m_StatisticsColumns = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_OptimizerStatisticsColumns As New ObservableCollection(Of EgtDataGridColumn)
|
||||
Public Property OptimizerStatisticsColumns As ObservableCollection(Of EgtDataGridColumn)
|
||||
Private m_OptimizerStatisticsColumns As New ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)
|
||||
Public Property OptimizerStatisticsColumns As ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)
|
||||
Get
|
||||
Return m_OptimizerStatisticsColumns
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of EgtDataGridColumn))
|
||||
Set(value As ObservableCollection(Of EgwWPFBaseLib.ColumnLayout))
|
||||
m_OptimizerStatisticsColumns = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_RawPartStatisticsColumns As New ObservableCollection(Of EgtDataGridColumn)
|
||||
Public Property RawPartStatisticsColumns As ObservableCollection(Of EgtDataGridColumn)
|
||||
Private m_RawPartStatisticsColumns As New ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)
|
||||
Public Property RawPartStatisticsColumns As ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)
|
||||
Get
|
||||
Return m_RawPartStatisticsColumns
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of EgtDataGridColumn))
|
||||
Set(value As ObservableCollection(Of EgwWPFBaseLib.ColumnLayout))
|
||||
m_RawPartStatisticsColumns = value
|
||||
End Set
|
||||
End Property
|
||||
@@ -289,10 +291,49 @@ Public Class StatisticsVM
|
||||
Sub New()
|
||||
' Aggiungo riferimento a Map
|
||||
Map.SetRefStatisticsVM(Me)
|
||||
' carico le colonne della datagrid
|
||||
GetPrivateProfileColumns(S_STATISTICS, StatisticsColumns)
|
||||
GetPrivateProfileColumns(S_OPTIMIZERSTATISTICS, OptimizerStatisticsColumns)
|
||||
GetPrivateProfileColumns(S_RAWPARTSTATISTICS, RawPartStatisticsColumns)
|
||||
|
||||
'Dim NewColumnList As New ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)({New EgwWPFBaseLib.ColumnLayout("colPDN", DataGridLengthUnitType.Auto, 1, True, Nothing, False, False, True, True, False, False),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colW", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colH", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colL", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colDESC", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colMATERIAL", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colCNT", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colADDED", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colINPROD", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colDONE", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colUNITVOLUME", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colTOTVOLUME", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colUNITTIME", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colTOTTIME", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True)})
|
||||
'EgwWPFBaseLib.EgwDataGrid.WriteColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_STATISTICS, NewColumnList)
|
||||
|
||||
'Dim NewColumnList1 As New ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)({New EgwWPFBaseLib.ColumnLayout("colNAME", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colW", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colH", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colL", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colMATERIAL", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colUSAGE", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colWASTE", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colUNITTIME", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True)})
|
||||
'EgwWPFBaseLib.EgwDataGrid.WriteColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_OPTIMIZERSTATISTICS, NewColumnList1)
|
||||
|
||||
'Dim NewColumnList2 As New ObservableCollection(Of EgwWPFBaseLib.ColumnLayout)({New EgwWPFBaseLib.ColumnLayout("colW", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colH", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colL", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colMATERIAL", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, False, True),
|
||||
' New EgwWPFBaseLib.ColumnLayout("colQTY", DataGridLengthUnitType.Pixel, 30, True, Nothing, True, True, True, True, True, True)})
|
||||
'EgwWPFBaseLib.EgwDataGrid.WriteColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_RAWPARTSTATISTICS, NewColumnList2)
|
||||
|
||||
'carico le colonne della datagrid
|
||||
EgwWPFBaseLib.EgwDataGrid.ReadColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_STATISTICS, StatisticsColumns)
|
||||
EgwWPFBaseLib.EgwDataGrid.ReadColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_OPTIMIZERSTATISTICS, OptimizerStatisticsColumns)
|
||||
EgwWPFBaseLib.EgwDataGrid.ReadColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_RAWPARTSTATISTICS, RawPartStatisticsColumns)
|
||||
|
||||
'' carico le colonne della datagrid
|
||||
'GetPrivateProfileColumns(S_STATISTICS, StatisticsColumns)
|
||||
'GetPrivateProfileColumns(S_OPTIMIZERSTATISTICS, OptimizerStatisticsColumns)
|
||||
'GetPrivateProfileColumns(S_RAWPARTSTATISTICS, RawPartStatisticsColumns)
|
||||
End Sub
|
||||
|
||||
#End Region ' CONSTRUCTOR
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
Public Class OptimizerStatisticsWndV
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports System.IO
|
||||
|
||||
Public Class OptimizerStatisticsWndV
|
||||
|
||||
Private WithEvents m_StatisticsVM As StatisticsVM
|
||||
|
||||
@@ -14,6 +17,8 @@
|
||||
End Sub
|
||||
|
||||
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_StatisticsVM.m_CloseWindow
|
||||
EgwWPFBaseLib.EgwDataGrid.WriteColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_OPTIMIZERSTATISTICS, Map.refStatisticsVM.OptimizerStatisticsColumns)
|
||||
EgwWPFBaseLib.EgwDataGrid.WriteColumnLayout(Path.ChangeExtension(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, ".json"), S_OPTIMIZERSTATISTICS, Map.refStatisticsVM.RawPartStatisticsColumns)
|
||||
Me.DialogResult = bDialogResult
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
Public Class StatisticsWndV
|
||||
Imports System.Windows.Forms
|
||||
|
||||
Public Class StatisticsWndV
|
||||
|
||||
Private WithEvents m_StatisticsVM As StatisticsVM
|
||||
|
||||
@@ -13,8 +15,4 @@
|
||||
m_StatisticsVM = StatisticsVM
|
||||
End Sub
|
||||
|
||||
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_StatisticsVM.m_CloseWindow
|
||||
Me.DialogResult = bDialogResult
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
Reference in New Issue
Block a user