diff --git a/EnvelopeGenerator.Common/Entities/EnvelopeHistoryEntry.vb b/EnvelopeGenerator.Common/Entities/EnvelopeHistory.vb similarity index 93% rename from EnvelopeGenerator.Common/Entities/EnvelopeHistoryEntry.vb rename to EnvelopeGenerator.Common/Entities/EnvelopeHistory.vb index 1bceb12f..251b2608 100644 --- a/EnvelopeGenerator.Common/Entities/EnvelopeHistoryEntry.vb +++ b/EnvelopeGenerator.Common/Entities/EnvelopeHistory.vb @@ -1,6 +1,6 @@ Imports EnvelopeGenerator.Domain -Public Class EnvelopeHistoryEntry +Public Class EnvelopeHistory Public Property EnvelopeId As Integer Public Property UserReference As String Public Property Status As Constants.EnvelopeStatus diff --git a/EnvelopeGenerator.Common/EnvelopeGenerator.Common.vbproj b/EnvelopeGenerator.Common/EnvelopeGenerator.Common.vbproj index d9e9efa4..8e4e0182 100644 --- a/EnvelopeGenerator.Common/EnvelopeGenerator.Common.vbproj +++ b/EnvelopeGenerator.Common/EnvelopeGenerator.Common.vbproj @@ -280,7 +280,7 @@ - + diff --git a/EnvelopeGenerator.Common/Models/HistoryModel.vb b/EnvelopeGenerator.Common/Models/HistoryModel.vb index a4476be6..f61dd62d 100644 --- a/EnvelopeGenerator.Common/Models/HistoryModel.vb +++ b/EnvelopeGenerator.Common/Models/HistoryModel.vb @@ -8,8 +8,8 @@ Public Class HistoryModel MyBase.New(pState) End Sub - Private Function ToEnvelopeHistoryEntry(pRow As DataRow) As EnvelopeHistoryEntry - Return New EnvelopeHistoryEntry() With { + Private Function ToEnvelopeHistoryEntry(pRow As DataRow) As EnvelopeHistory + Return New EnvelopeHistory() With { .ActionDate = pRow.ItemEx(Of Date)("ACTION_DATE", Nothing), .EnvelopeId = pRow.Item("ENVELOPE_ID"), .Status = pRow.Item("STATUS"), @@ -17,7 +17,7 @@ Public Class HistoryModel } End Function - Public Function List(pEnvelopeId As Integer) As List(Of EnvelopeHistoryEntry) + Public Function List(pEnvelopeId As Integer) As List(Of EnvelopeHistory) Dim oSql = $"SELECT * FROM TBSIG_ENVELOPE_HISTORY WHERE ENVELOPE_ID = {pEnvelopeId} AND ACTION_DATE IS NOT NULL ORDER BY GUID DESC" Dim oTable = Database.GetDatatable(oSql) Return oTable?.Rows. @@ -39,7 +39,7 @@ Public Class HistoryModel Return oRowCount > 0 End Function - Public Function Insert(pHistory As EnvelopeHistoryEntry) As Boolean + Public Function Insert(pHistory As EnvelopeHistory) As Boolean Try Dim oSql = "INSERT INTO [dbo].[TBSIG_ENVELOPE_HISTORY] " oSql += " ([ENVELOPE_ID] " diff --git a/EnvelopeGenerator.Common/Services/HistoryService.vb b/EnvelopeGenerator.Common/Services/HistoryService.vb index c082883b..1a4c49c3 100644 --- a/EnvelopeGenerator.Common/Services/HistoryService.vb +++ b/EnvelopeGenerator.Common/Services/HistoryService.vb @@ -18,7 +18,7 @@ Public Class HistoryService End Sub Public Function SetEnvelopeStatus(pEnvelope As Envelope, pStatus As EnvelopeStatus, pUserReference As String) As Boolean - Dim oResult = HistoryModel.Insert(New EnvelopeHistoryEntry() With { + Dim oResult = HistoryModel.Insert(New EnvelopeHistory() With { .EnvelopeId = pEnvelope.Id, .ActionDate = Now(), .Status = pStatus, diff --git a/EnvelopeGenerator.Form/Controllers/EnvelopeEditorController.vb b/EnvelopeGenerator.Form/Controllers/EnvelopeEditorController.vb index daba997e..31e69d95 100644 --- a/EnvelopeGenerator.Form/Controllers/EnvelopeEditorController.vb +++ b/EnvelopeGenerator.Form/Controllers/EnvelopeEditorController.vb @@ -76,7 +76,7 @@ Public Class EnvelopeEditorController If EnvelopeModel.Insert(oEnvelope) Then - Dim newHistoryEntry As New EnvelopeHistoryEntry With { + Dim newHistoryEntry As New Common.EnvelopeHistoryWith { .EnvelopeId = oEnvelope.Id, .Status = EnvelopeStatus.EnvelopeCreated, .UserReference = oEnvelope.User.Email