Files
egtbeamwall/EgtBEAMWALL.Optimizer/ItemParamList/FeatureInPartInRawPartListVM.vb
T
2025-08-28 18:57:42 +02:00

72 lines
2.2 KiB
VB.net

Imports System.Collections.ObjectModel
Imports EgtBEAMWALL.Core
Imports EgtUILib
Imports EgtWPFLib5
Public Class FeatureInPartInRawPartListVM
Inherits VMBase
Private m_colFeatureInPartInRawPart_Do As EgtDataGridColumn
Public ReadOnly Property colFeatureInPartInRawPart_Do As EgtDataGridColumn
Get
Return m_colFeatureInPartInRawPart_Do
End Get
End Property
Private m_colFeatureInPartInRawPart_Priority As EgtDataGridColumn
Public ReadOnly Property colFeatureInPartInRawPart_Priority As EgtDataGridColumn
Get
Return m_colFeatureInPartInRawPart_Priority
End Get
End Property
Private m_FeatureInPartInRawPartColumns As New ObservableCollection(Of EgtDataGridColumn)
Public Property FeatureInPartInRawPartColumns As ObservableCollection(Of EgtDataGridColumn)
Get
Return m_FeatureInPartInRawPartColumns
End Get
Set(value As ObservableCollection(Of EgtDataGridColumn))
m_FeatureInPartInRawPartColumns = value
End Set
End Property
#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 Priority_Msg As String
Get
Return EgtMsg(61895)
End Get
End Property
#End Region ' Messages
Sub New()
' creo riferimento in Map
Map.SetRefFeatureInPartInRawPartListVM(Me)
' carico le colonne della datagrid
GetPrivateProfileColumns(S_FEATUREINPARTINRAWPARTLIST, FeatureInPartInRawPartColumns)
' recupero riferimento a colonna Do
m_colFeatureInPartInRawPart_Do = FeatureInPartInRawPartColumns.FirstOrDefault(Function(x) x.Name = COL_DO)
m_colFeatureInPartInRawPart_Priority = FeatureInPartInRawPartColumns.FirstOrDefault(Function(x) x.Name = COL_PRIORITY)
End Sub
Friend Sub UpdateColumns(nProjectType As BWType)
If Not IsNothing(m_colFeatureInPartInRawPart_Priority) Then
m_colFeatureInPartInRawPart_Priority.Visible = (nProjectType = BWType.WALL AndAlso CurrentMachine.bIsEnabledPriority)
End If
End Sub
End Class