diff --git a/AssemblyManager/AssemblyManagerV.xaml b/AssemblyManager/AssemblyManagerV.xaml
index 6e7bfa6..f50086f 100644
--- a/AssemblyManager/AssemblyManagerV.xaml
+++ b/AssemblyManager/AssemblyManagerV.xaml
@@ -38,7 +38,7 @@
-
+
diff --git a/AssemblyManager/AssemblyManagerV.xaml.vb b/AssemblyManager/AssemblyManagerV.xaml.vb
index c1a5fbf..0d5d230 100644
--- a/AssemblyManager/AssemblyManagerV.xaml.vb
+++ b/AssemblyManager/AssemblyManagerV.xaml.vb
@@ -1,14 +1,24 @@
Public Class AssemblyManagerV
- Private Sub Door_MouseLeftButtonDown(sender As Object, e As MouseButtonEventArgs)
+ Private Sub Door_MouseLeftButtonUp(sender As Object, e As MouseButtonEventArgs)
Dim Item As ListBoxItem = DirectCast(sender, ListBoxItem)
' Gestisco porta corrente modificata
+ Dim IsModified As Boolean = Map.refAssemblyManagerVM.CurrProject.SelAssemblyName.IsModified
If Not Map.refAssemblyManagerVM.ManageModified() Then
- e.Handled = False
Return
End If
- ' Apro altra porta
- e.Handled = Map.refAssemblyManagerVM.Open(DirectCast(Item.DataContext, AssemblyName))
+ 'If Not Map.refAssemblyManagerVM.ManageModified() Then
+ ' e.Handled = False
+ ' Return
+ 'End If
+ ' verifico se il progetto cliccato è quello già selezionato
+ If Map.refAssemblyManagerVM.CurrProject.SelAssemblyName Is DirectCast(Item.DataContext, AssemblyName) Then
+ ' ricarico la porta
+ Map.refAssemblyManagerVM.Open(DirectCast(Item.DataContext, AssemblyName))
+ End If
+ If IsModified Then
+ Map.refAssemblyManagerVM.CurrProject.SelAssemblyName = DirectCast(Item.DataContext, AssemblyName)
+ End If
End Sub
End Class
diff --git a/AssemblyManager/AssemblyManagerVM.vb b/AssemblyManager/AssemblyManagerVM.vb
index 58736b8..5f01562 100644
--- a/AssemblyManager/AssemblyManagerVM.vb
+++ b/AssemblyManager/AssemblyManagerVM.vb
@@ -93,7 +93,7 @@ Public Class AssemblyManagerVM
If IsNothing(OpenedAssName) Then Return False
If Not File.Exists(OpenedAssName.Name) Then Return False
' Seleziono questo AssemblyName
- CurrProject.SelAssemblyName = OpenedAssName
+ 'CurrProject.SelAssemblyName = OpenedAssName
' resetto errori sui bevel edge
Part.FirstReadingEdge = False
' leggo il ddf e creo relativo assemblato
diff --git a/Constants/ConstCompo.vb b/Constants/ConstCompo.vb
index 6605da6..fb4dc2e 100644
--- a/Constants/ConstCompo.vb
+++ b/Constants/ConstCompo.vb
@@ -20,8 +20,9 @@ Module ConstCompo
Public Const S_ORDER As String = "order"
Public Const K_CUSTOMER As String = "customer"
Public Const K_ELEVATION As String = "elevation"
- Public Const K_PROJECT As String = "project"
- Public Const K_PO As String = "PO"
+ Public Const K_PROJECT As String = "project"
+ Public Const K_ORDER As String = "Order"
+ Public Const K_PO As String = "PO"
Public Const K_LINE As String = "Line"
Public Const S_DATE As String = "date"
Public Const S_PIECE As String = "piece"
diff --git a/DoorParameters/Compo.vb b/DoorParameters/Compo.vb
index 291ed00..8567fea 100644
--- a/DoorParameters/Compo.vb
+++ b/DoorParameters/Compo.vb
@@ -128,6 +128,16 @@ Public Class Compo
NotifyPropertyChanged("SelFile")
End Set
End Property
+ Friend Sub SetSelFile(File As String)
+ m_SelFile = File
+ ' ricostruisco il nome del template da passare alle funzioni
+ Dim ModelDir As String = String.Empty
+ If m_SelBrandPart <> RegexFunction.ModelTemplate(m_CompoType.Path) Then ModelDir = m_SelBrandPart & "\"
+ Dim CurrItem As String = ModelDir & m_SelFile
+ ' passo il nome
+ SetSelTemplate(CurrItem)
+ NotifyPropertyChanged("SelFile")
+ End Sub
' nome grafica (potrebbe essere shape o template)
Private m_TemplateName As String
@@ -181,6 +191,10 @@ Public Class Compo
Map.refSceneManagerVM.RefreshBtn()
End Set
End Property
+ Private Sub SetSelTemplate(Template As String)
+ SetTemplateSelItem(Template)
+ Map.refAssemblyManagerVM.CurrProject.SelAssemblyName.IsModified = True
+ End Sub
' setta il valore del template
Friend Sub SetTemplateSelItem(value As String)
diff --git a/DoorParameters/Part.vb b/DoorParameters/Part.vb
index fcd24d1..b2d330d 100644
--- a/DoorParameters/Part.vb
+++ b/DoorParameters/Part.vb
@@ -1095,9 +1095,9 @@ Public Class Part
SelItemIndex += 1
End While
If SelItemIndex < NewCompo.FileList.Count Then
- NewCompo.SelFile = NewCompo.FileList(SelItemIndex)
+ NewCompo.SetSelFile(NewCompo.FileList(SelItemIndex))
Else
- NewCompo.SelFile = String.Empty
+ NewCompo.SetSelFile(String.Empty)
End If
Else
Return False
@@ -1331,16 +1331,24 @@ Public Class Part
Dim Elevation As String = GetValueWithKey(RemoveComment(FileContent(Index)), K_ELEVATION)
If Not String.IsNullOrWhiteSpace(Elevation) Then m_Elevation = Elevation
Index = NextIndex(Index)
- ' Recupero dati project
+ ' Recupero dati project (opzionale)
If Index > FileContent.Count() - 1 Then Return -1
- Dim Project As String = GetValueWithKey(RemoveComment(FileContent(Index)), K_PROJECT)
- If Not String.IsNullOrWhiteSpace(Project) Then m_Project = Project
- Index = NextIndex(Index)
- ' Recupero dati PO (purchase order)
+ If SearchKey(RemoveComment(FileContent(Index)), K_PROJECT) Then
+ Dim Project As String = GetValueWithKey(RemoveComment(FileContent(Index)), K_PROJECT)
+ If Not String.IsNullOrWhiteSpace(Project) Then m_Project = Project
+ Index = NextIndex(Index)
+ End If
+ ' Recupero dati PO (purchase order)(opzionale)
If Index > FileContent.Count() - 1 Then Return -1
- Dim PO As String = GetValueWithKey(RemoveComment(FileContent(Index)), K_PO)
- If Not String.IsNullOrWhiteSpace(PO) Then m_PO = PO
- Index = NextIndex(Index)
+ If SearchKey(RemoveComment(FileContent(Index)), K_PO) Then
+ Dim PO As String = GetValueWithKey(RemoveComment(FileContent(Index)), K_PO)
+ If Not String.IsNullOrWhiteSpace(PO) Then m_PO = PO
+ Index = NextIndex(Index)
+ ElseIf SearchKey(RemoveComment(FileContent(Index)), K_ORDER) Then
+ Dim Order As String = GetValueWithKey(RemoveComment(FileContent(Index)), K_ORDER)
+ If Not String.IsNullOrWhiteSpace(Order) Then m_PO = Order
+ Index = NextIndex(Index)
+ End If
' Recupero dati line
If Index > FileContent.Count() - 1 Then Return -1
Dim Line As String = GetValueWithKey(RemoveComment(FileContent(Index)), K_LINE)
diff --git a/Doors.vb b/Doors.vb
index 845b7c7..903e488 100644
--- a/Doors.vb
+++ b/Doors.vb
@@ -61,6 +61,10 @@ Public Module Doors
GetMainPrivateProfileString(S_DOORS, K_DDFEXEC, "", sExecName)
sExecPath = IniFile.m_sDoorsDirPath & "\" & sExecName
If Not EgtLuaExecFile(sExecPath) Then Return False
+ ' Setto variabili per quotatura
+ 'For Each HardwareDimension In Map.refDimensioningPanelVM.HardwareDimensionList
+ ' EgtLuaSetGlobBoolVar("DGD.EN_L_" & HardwareDimension.NameHardware.ToUpper(), HardwareDimension.SelectedLayer)
+ 'Next
' Lancio la creazione
EgtLuaSetGlobStringVar("DGD.FILE", sDdfFile)
EgtLuaSetGlobBoolVar("DGD.NCGEN", bNcGen)
diff --git a/My Project/AssemblyInfo.vb b/My Project/AssemblyInfo.vb
index 6ed62c4..d42c8c8 100644
--- a/My Project/AssemblyInfo.vb
+++ b/My Project/AssemblyInfo.vb
@@ -72,5 +72,5 @@ Imports System.Windows
' by using the '*' as shown below:
'
-
-
+
+
diff --git a/ProjectManager/Project.vb b/ProjectManager/Project.vb
index 7d627b9..43789e2 100644
--- a/ProjectManager/Project.vb
+++ b/ProjectManager/Project.vb
@@ -34,6 +34,7 @@ Public Class Project
End Get
Set(value As AssemblyName)
m_SelAssemblyName = value
+ Map.refAssemblyManagerVM.Open(m_SelAssemblyName)
NotifyPropertyChanged("SelAssemblyName")
End Set
End Property
diff --git a/ProjectManager/ProjectManagerVM.vb b/ProjectManager/ProjectManagerVM.vb
index 0db0a24..ce4f2a2 100644
--- a/ProjectManager/ProjectManagerVM.vb
+++ b/ProjectManager/ProjectManagerVM.vb
@@ -398,7 +398,7 @@ Public Class ProjectManagerVM
End If
Next
End If
- Map.refAssemblyManagerVM.Open(CurrProject.AssemblyList(0))
+ CurrProject.SelAssemblyName = CurrProject.AssemblyList(0)
Else
Map.refMainWindowVM.SelectedPage = MainWindowVM.ListPageEnum.nNothingSelected
End If
diff --git a/SceneManager/DimensioningPanel/DimensioningPanelV.xaml b/SceneManager/DimensioningPanel/DimensioningPanelV.xaml
index 39d0eaf..1ee9445 100644
--- a/SceneManager/DimensioningPanel/DimensioningPanelV.xaml
+++ b/SceneManager/DimensioningPanel/DimensioningPanelV.xaml
@@ -18,11 +18,6 @@
Background="{StaticResource EgaltechBlue2}"
CornerRadius="2"
Padding="1">
-