添加工艺站发布站包历史表;允许用户选择测试站时选择历史发布站包

This commit is contained in:
2024-05-08 21:59:31 +08:00
parent ec4c447b01
commit e475a06eb5
254 changed files with 928 additions and 242730 deletions

View File

@@ -37,8 +37,9 @@ Namespace UTSModule.Project
End Enum
#Region "New"
Sub New(userId As Integer, projectName As String)
Sub New(userId As Integer, userName As String, projectName As String)
Me.UserId = userId
Me.UserName = userName
Index = -1
ProductTypeId = 0
Name = projectName
@@ -53,8 +54,9 @@ Namespace UTSModule.Project
End Sub
Sub New(userId As Integer, projectName As String, mode As InitializeModeEnum)
Sub New(userId As Integer, userName As String, projectName As String, mode As InitializeModeEnum)
Me.UserId = userId
Me.UserName = userName
Index = -1
ProductTypeId = 0
Name = projectName
@@ -71,8 +73,10 @@ Namespace UTSModule.Project
End Sub
Sub New(userId As Integer, projectId As Integer, mode As InitializeModeEnum)
Sub New(userId As Integer, userName As String, projectId As Integer, mode As InitializeModeEnum)
Me.UserId = userId
Me.UserName = userName
Index = projectId
ProductTypeId = 0
Name = String.Empty
@@ -189,6 +193,12 @@ Namespace UTSModule.Project
''' <returns></returns>
Public Property UserId() As Integer
''' <summary>
''' 项目当前操作人名称
''' </summary>
''' <returns></returns>
Public Property UserName() As String
Private _masterImg As Image
@@ -530,6 +540,46 @@ Namespace UTSModule.Project
End Sub
Private Function LoadStationPackets(db As DbExecutor, pid As Integer, sid As Integer) As List(Of StationPacketVo)
Dim tableName As String = DbTableModel.Customer.StationPacketReleaseLogTable.TableName
Dim condition As String = $"`{DbTableModel.Customer.StationPacketReleaseLogTable.ColNames.ProjectID}` = {pid} && `{DbTableModel.Customer.StationPacketReleaseLogTable.ColNames.StationID}` = {sid}"
Dim dtProject As DataTable = db.ExecuteDataTable(db.CmdHelper.SearchAll(tableName, condition))
Dim packetList As New List(Of StationPacketVo)
For Each row As DataRow In dtProject.Rows
Dim packet As New StationPacketVo With {
.ProjectID = CInt(row(DbTableModel.Customer.StationPacketReleaseLogTable.ColNames.ProjectID.ToString())),
.StationID = CInt(row(DbTableModel.Customer.StationPacketReleaseLogTable.ColNames.StationID.ToString())),
.PacketName = row(DbTableModel.Customer.StationPacketReleaseLogTable.ColNames.StationID.ToString()).ToString(),
.PacketMd5 = row(DbTableModel.Customer.StationPacketReleaseLogTable.ColNames.StationID.ToString()).ToString(),
.Description = row(DbTableModel.Customer.StationPacketReleaseLogTable.ColNames.StationID.ToString()).ToString()
}
packetList.Insert(0, packet)
Next
Return packetList
End Function
''' <summary>
''' 获取当前站位所有站包
''' </summary>
''' <param name="pid"></param>
''' <param name="sid"></param>
''' <returns></returns>
Public Function LoadLocalDbStationPackets(pid As Integer, sid As Integer) As List(Of StationPacketVo)
Dim packetList As New List(Of StationPacketVo)
Using db As New DbExecutor(UtsDb.LocalDbType, UtsDb.LocalConnString)
db.Open()
packetList.AddRange(LoadStationPackets(db, pid, sid))
db.Close()
End Using
Return packetList
End Function
''' <summary>
''' 通过项目索引初始化项目信息
''' </summary>