refactor(EnvelopeHistoryEntry): Umbenennung von EnvelopeHistoryEntry in EnvelopeHistory
This commit is contained in:
parent
1f43dff9f4
commit
c6fe039dd8
@ -1,6 +1,6 @@
|
|||||||
Imports EnvelopeGenerator.Domain
|
Imports EnvelopeGenerator.Domain
|
||||||
|
|
||||||
Public Class EnvelopeHistoryEntry
|
Public Class EnvelopeHistory
|
||||||
Public Property EnvelopeId As Integer
|
Public Property EnvelopeId As Integer
|
||||||
Public Property UserReference As String
|
Public Property UserReference As String
|
||||||
Public Property Status As Constants.EnvelopeStatus
|
Public Property Status As Constants.EnvelopeStatus
|
||||||
@ -280,7 +280,7 @@
|
|||||||
<Compile Include="Jobs\APIBackendJobs\APIEnvelopeJob.vb" />
|
<Compile Include="Jobs\APIBackendJobs\APIEnvelopeJob.vb" />
|
||||||
<Compile Include="Jobs\FinalizeDocument\PDFBurnerParams.vb" />
|
<Compile Include="Jobs\FinalizeDocument\PDFBurnerParams.vb" />
|
||||||
<Compile Include="Services\TemplateService.vb" />
|
<Compile Include="Services\TemplateService.vb" />
|
||||||
<Compile Include="Entities\EnvelopeHistoryEntry.vb" />
|
<Compile Include="Entities\EnvelopeHistory.vb" />
|
||||||
<Compile Include="Entities\EnvelopeReceiver.vb" />
|
<Compile Include="Entities\EnvelopeReceiver.vb" />
|
||||||
<Compile Include="Entities\State.vb" />
|
<Compile Include="Entities\State.vb" />
|
||||||
<Compile Include="Helpers.vb" />
|
<Compile Include="Helpers.vb" />
|
||||||
|
|||||||
@ -8,8 +8,8 @@ Public Class HistoryModel
|
|||||||
MyBase.New(pState)
|
MyBase.New(pState)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Function ToEnvelopeHistoryEntry(pRow As DataRow) As EnvelopeHistoryEntry
|
Private Function ToEnvelopeHistoryEntry(pRow As DataRow) As EnvelopeHistory
|
||||||
Return New EnvelopeHistoryEntry() With {
|
Return New EnvelopeHistory() With {
|
||||||
.ActionDate = pRow.ItemEx(Of Date)("ACTION_DATE", Nothing),
|
.ActionDate = pRow.ItemEx(Of Date)("ACTION_DATE", Nothing),
|
||||||
.EnvelopeId = pRow.Item("ENVELOPE_ID"),
|
.EnvelopeId = pRow.Item("ENVELOPE_ID"),
|
||||||
.Status = pRow.Item("STATUS"),
|
.Status = pRow.Item("STATUS"),
|
||||||
@ -17,7 +17,7 @@ Public Class HistoryModel
|
|||||||
}
|
}
|
||||||
End Function
|
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 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)
|
Dim oTable = Database.GetDatatable(oSql)
|
||||||
Return oTable?.Rows.
|
Return oTable?.Rows.
|
||||||
@ -39,7 +39,7 @@ Public Class HistoryModel
|
|||||||
Return oRowCount > 0
|
Return oRowCount > 0
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Function Insert(pHistory As EnvelopeHistoryEntry) As Boolean
|
Public Function Insert(pHistory As EnvelopeHistory) As Boolean
|
||||||
Try
|
Try
|
||||||
Dim oSql = "INSERT INTO [dbo].[TBSIG_ENVELOPE_HISTORY] "
|
Dim oSql = "INSERT INTO [dbo].[TBSIG_ENVELOPE_HISTORY] "
|
||||||
oSql += " ([ENVELOPE_ID] "
|
oSql += " ([ENVELOPE_ID] "
|
||||||
|
|||||||
@ -18,7 +18,7 @@ Public Class HistoryService
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Function SetEnvelopeStatus(pEnvelope As Envelope, pStatus As EnvelopeStatus, pUserReference As String) As Boolean
|
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,
|
.EnvelopeId = pEnvelope.Id,
|
||||||
.ActionDate = Now(),
|
.ActionDate = Now(),
|
||||||
.Status = pStatus,
|
.Status = pStatus,
|
||||||
|
|||||||
@ -76,7 +76,7 @@ Public Class EnvelopeEditorController
|
|||||||
|
|
||||||
If EnvelopeModel.Insert(oEnvelope) Then
|
If EnvelopeModel.Insert(oEnvelope) Then
|
||||||
|
|
||||||
Dim newHistoryEntry As New EnvelopeHistoryEntry With {
|
Dim newHistoryEntry As New Common.EnvelopeHistoryWith {
|
||||||
.EnvelopeId = oEnvelope.Id,
|
.EnvelopeId = oEnvelope.Id,
|
||||||
.Status = EnvelopeStatus.EnvelopeCreated,
|
.Status = EnvelopeStatus.EnvelopeCreated,
|
||||||
.UserReference = oEnvelope.User.Email
|
.UserReference = oEnvelope.User.Email
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user