This commit is contained in:
Developer 02 2025-05-09 17:00:24 +02:00
commit ea6d80918c
33 changed files with 969 additions and 52 deletions

View File

@ -19,6 +19,7 @@ Public Class EmailData
Public Property EmailAttachment As String = "" Public Property EmailAttachment As String = ""
Public Property ATT1_RELATED_ID As Long Public Property ATT1_RELATED_ID As Long
Public Property ATT1_REL_TYPE As String = "" Public Property ATT1_REL_TYPE As String = ""
Public Property ADDED_WHO_PROCESS As String = "DDEnvelopGenerator"
''' <summary> ''' <summary>
''' Constructor for sending email to receiver ''' Constructor for sending email to receiver

View File

@ -33,6 +33,7 @@
Public Property History As New List(Of EnvelopeHistoryEntry) Public Property History As New List(Of EnvelopeHistoryEntry)
Public Property EnvelopeType As EnvelopeType Public Property EnvelopeType As EnvelopeType
Public Property DOC_RESULT As Byte() Public Property DOC_RESULT As Byte()
Public Property CURRENT_WORK_APP As String = "signFLOW GUI"
Public ReadOnly Property EnvelopeTypeTitle As String Public ReadOnly Property EnvelopeTypeTitle As String
Get Get
Return EnvelopeType?.Title Return EnvelopeType?.Title

View File

@ -281,6 +281,7 @@
<Compile Include="Entities\ElementStatus.vb" /> <Compile Include="Entities\ElementStatus.vb" />
<Compile Include="Entities\EmailData.vb" /> <Compile Include="Entities\EmailData.vb" />
<Compile Include="Entities\EmailTemplate.vb" /> <Compile Include="Entities\EmailTemplate.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\Envelope.vb" /> <Compile Include="Entities\Envelope.vb" />

View File

@ -52,6 +52,7 @@ Public Class Helpers
End Function End Function
Public Shared Function GetEnvelopeURL(pHost As String, pEnvelopeUuid As String, pReceiverSignature As String) As String Public Shared Function GetEnvelopeURL(pHost As String, pEnvelopeUuid As String, pReceiverSignature As String) As String
Dim oEnvelopeUserReference As String = EncodeEnvelopeReceiverId(pEnvelopeUuid, pReceiverSignature) Dim oEnvelopeUserReference As String = EncodeEnvelopeReceiverId(pEnvelopeUuid, pReceiverSignature)
Dim oURL As String = String.Format("{0}/EnvelopeKey/{1}", pHost.Trim(), oEnvelopeUserReference) Dim oURL As String = String.Format("{0}/EnvelopeKey/{1}", pHost.Trim(), oEnvelopeUserReference)
Return oURL Return oURL

View File

@ -0,0 +1,221 @@
Imports DigitalData.Modules.Database
Imports DigitalData.Modules.Logging
Imports DigitalData.Modules.Base
Imports GdPicture14
Imports Quartz
Imports System.Security.Cryptography
Imports System.IO
Imports EnvelopeGenerator.Common.Jobs.FinalizeDocument.FinalizeDocumentExceptions
Imports EnvelopeGenerator.Common.Jobs.FinalizeDocument
Imports EnvelopeGenerator.Common.Constants
Imports DevExpress.DataProcessing
Imports System.Data.SqlClient
Imports DevExpress.XtraRichEdit.Layout.Engine
Namespace Jobs
Public Class APIEnvelopeJob
Implements IJob
Private LogConfig As LogConfig
Private Logger As Logger
Private Database As MSSQLServer
Private Config As DbConfig
Private ConfigModel As ConfigModel
Private EnvelopeModel As EnvelopeModel
Private ReceiverModel As ReceiverModel
Private ActionService As ActionService
Private ReadOnly CompleteWaitTime As Integer = 1
Private myTempFiles As TempFiles
Private Class EnvelopeData
Public EnvelopeId As Integer
Public EnvelopeUUID As String
Public DocumentPath As String
End Class
Public Function Execute(pContext As IJobExecutionContext) As Task Implements IJob.Execute
LogConfig = pContext.MergedJobDataMap.Item(Constants.LOGCONFIG)
Logger = LogConfig.GetLogger()
myTempFiles = New TempFiles(LogConfig)
myTempFiles.Create()
Dim JobId = pContext.JobDetail.Key
Logger.Debug("API Envelopes - Starting job {0}", JobId)
Try
Logger.Debug("API Envelopes - Loading Database..")
Database = GetDatabase(pContext, LogConfig)
Logger.Debug("API Envelopes - Loading Models & Services")
Dim oState = GetState()
InitializeModels(oState)
Logger.Debug("API Envelopes - Loading Configuration..")
Config = ConfigModel.LoadConfiguration()
oState.DbConfig = Config
InitializeServices(oState)
Config.DocumentPath = Config.DocumentPath
Logger.Debug("API Envelopes - ExportPath: [{0}]", Config.ExportPath)
Dim oSql = $"SELECT * FROM TBSIG_ENVELOPE where SOURCE = 'API' AND STATUS = 1003 order by guid"
Dim oDTEnv_invitations = Database.GetDatatable(oSql)
Dim oEnvelopeIds As List(Of Integer) = oDTEnv_invitations.Rows.Cast(Of DataRow).
Select(Function(r) r.Item("GUID")).
Cast(Of Integer).
ToList()
If oEnvelopeIds.Count > 0 Then
Logger.Info("SendInvMail - Found [{0}] envelopes.", oEnvelopeIds.Count)
End If
Dim oTotal As Integer = oEnvelopeIds.Count
Dim oCurrent As Integer = 1
For Each oId In oEnvelopeIds
Logger.Info("SendInvMail - Gathering Info for Envelope [{0}] ({1}/{2})", oId, oCurrent, oTotal)
Try
Dim oEnvelope = EnvelopeModel.GetById(oId)
If oEnvelope Is Nothing Then
Logger.Warn("SendInvMail - Envelope could not be loaded for Id [{0}]!", oId)
Throw New ArgumentNullException("EnvelopeData")
End If
oEnvelope.CURRENT_WORK_APP = "signFLOW_API_EnvJob_InvMail"
Logger.Debug("SendInvMail - Loading Envelope Data..")
Dim oEnvelopeData = GetEnvelopeData(oId)
oEnvelope.Receivers = ReceiverModel.ListEnvelopeReceivers(oEnvelope.Id).ToList()
Logger.Debug("SendInvMail - Created Reveivers!")
If oEnvelopeData Is Nothing Then
Logger.Warn("SendInvMail - EnvelopeData could not be loaded for Id [{0}]!", oId)
Throw New ArgumentNullException("EnvelopeData")
End If
Logger.Info("SendInvMail - Sending InvitationMails for Envelope [{0}]", oId)
If ActionService.SendEnvelope(oEnvelope) = False Then
Logger.Warn("SendInvMail - Could not send the InvitationMails for Envelope [{0}]", oId)
Throw New ArgumentNullException("EnvelopeData")
End If
Catch ex As Exception
Logger.Warn(ex, $"SendInvMail - Unhandled exception while working envelope [{oId}]")
End Try
oCurrent += 1
Logger.Info("SendInvMail - Envelope finalized!")
Next
'Hier nun der Teil um zurückgezogene Envelopes abzuarbeiten
oSql = $"SELECT ENV.GUID,REJ.COMMENT REJECTION_REASON FROM
(SELECT * FROM TBSIG_ENVELOPE where STATUS = 1009 AND SOURCE = 'API') ENV INNER JOIN
(SELECT MAX(GUID) GUID,ENVELOPE_ID,MAX(ADDED_WHEN) ADDED_WHEN,MAX(ACTION_DATE) ACTION_DATE, COMMENT FROM TBSIG_ENVELOPE_HISTORY where STATUS = 1009 GROUP BY ENVELOPE_ID,COMMENT ) REJ ON ENV.GUID = REJ.ENVELOPE_ID LEFT JOIN
(SELECT * FROM TBSIG_ENVELOPE_HISTORY where STATUS = 3004 ) M_Send ON ENV.GUID = M_Send.ENVELOPE_ID
where M_Send.GUID IS NULL"
Dim oDT_EnvWithdrawn = Database.GetDatatable(oSql)
oEnvelopeIds = oDTEnv_invitations.Rows.Cast(Of DataRow).
Select(Function(r) r.Item("GUID")).
Cast(Of Integer).
ToList()
If oEnvelopeIds.Count > 0 Then
Logger.Info("WithdrawnEnv - Found [{0}] envelopes.", oEnvelopeIds.Count)
End If
oTotal = oEnvelopeIds.Count
oCurrent = 1
Dim oEnvID As Integer
For Each oRow As DataRow In oDT_EnvWithdrawn.Rows
oEnvID = oRow.Item("GUID")
Dim oReason = oRow.Item("REJECTION_REASON")
Logger.Info("WithdrawnEnv - Gathering Info for Envelope [{0}] ({1}/{2})", oEnvID, oCurrent, oTotal)
Try
Dim oEnvelope = EnvelopeModel.GetById(oEnvID)
If oEnvelope Is Nothing Then
Logger.Warn("WithdrawnEnv - Envelope could not be loaded for Id [{0}]!", oEnvID)
Throw New ArgumentNullException("EnvelopeData")
End If
oEnvelope.CURRENT_WORK_APP = "signFLOW_API_EnvJob_Withdrawn"
oEnvelope.Receivers = ReceiverModel.ListEnvelopeReceivers(oEnvelope.Id).ToList()
Logger.Debug("WithdrawnEnv - Sending Withdrawn Mails..")
If ActionService.API_SendWithdrawn_Mails(oEnvelope, oReason) = False Then
Logger.Warn("Could not send the Mails for withdrawn Envelope")
Else
Dim oStatInsert = $"INSERT INTO TBSIG_ENVELOPE_HISTORY (ENVELOPE_ID,STATUS,USER_REFERENCE,ADDED_WHEN,ACTION_DATE) VALUES ('{oEnvelope.Id}',3004,'API',GETDATE(),GETDATE())"
Database.ExecuteNonQuery(oStatInsert)
End If
Catch ex As Exception
Logger.Warn(ex, $"WithdrawnEnv - Unhandled exception while working envelope [{oEnvID}]")
End Try
oCurrent += 1
Logger.Info("WithdrawnEnv - Envelope finalized!")
Next
Logger.Debug("API Envelopes - Completed job {0} successfully!", JobId)
Catch ex As Exception
Logger.Warn("API Envelopes job failed!")
Logger.Error(ex)
Finally
Logger.Debug("API Envelopes execution for [{0}] ended", JobId)
End Try
Return Task.FromResult(True)
End Function
Private Sub InitializeModels(pState As State)
ConfigModel = New ConfigModel(pState)
EnvelopeModel = New EnvelopeModel(pState)
ReceiverModel = New ReceiverModel(pState)
End Sub
Private Sub InitializeServices(pState As State)
ActionService = New ActionService(pState, Database)
End Sub
Private Function GetDatabase(pContext As IJobExecutionContext, pLogConfig As LogConfig) As MSSQLServer
Dim oConnectionString As String = pContext.MergedJobDataMap.Item(Constants.DATABASE)
Dim Database = New MSSQLServer(pLogConfig, MSSQLServer.DecryptConnectionString(oConnectionString))
Return Database
End Function
Private Function GetEnvelopeData(pEnvelopeId As Integer) As EnvelopeData
Dim oSql = $"SELECT T.GUID, T.ENVELOPE_UUID,T2.FILEPATH, T2.BYTE_DATA FROM [dbo].[TBSIG_ENVELOPE] T
JOIN TBSIG_ENVELOPE_DOCUMENT T2 ON T.GUID = T2.ENVELOPE_ID
WHERE T.GUID = {pEnvelopeId}"
Dim oTable As DataTable = Database.GetDatatable(oSql)
Dim oRow As DataRow = oTable.Rows.Cast(Of DataRow).SingleOrDefault()
If oRow Is Nothing Then
Return Nothing
End If
Dim oData As New EnvelopeData With {
.EnvelopeId = pEnvelopeId,
.DocumentPath = oRow.ItemEx("FILEPATH", ""),
.EnvelopeUUID = oRow.ItemEx("ENVELOPE_UUID", "")
}
Logger.Debug("Document path: [{0}]", oData.DocumentPath)
Return oData
End Function
Private Function GetState() As State
Return New State With {
.LogConfig = LogConfig,
.Database = Database,
.UserId = 0,
.Config = Nothing,
.DbConfig = Nothing
}
End Function
End Class
End Namespace

View File

@ -53,7 +53,7 @@ Namespace Jobs
myTempFiles = New TempFiles(LogConfig) myTempFiles = New TempFiles(LogConfig)
myTempFiles.Create() myTempFiles.Create()
Dim JobId = pContext.JobDetail.Key Dim JobId = pContext.JobDetail.Key
Logger.Info("Starting job {0}", JobId) Logger.Debug("Starting job {0}", JobId)
Try Try
Logger.Debug("Loading GdViewer..") Logger.Debug("Loading GdViewer..")
@ -108,7 +108,6 @@ Namespace Jobs
For Each oId In oEnvelopeIds For Each oId In oEnvelopeIds
Logger.Info("Finalizing Envelope [{0}] ({1}/{2})", oId, oCurrent, oTotal) Logger.Info("Finalizing Envelope [{0}] ({1}/{2})", oId, oCurrent, oTotal)
Logger.Debug("Loading Envelope..")
Try Try
Dim oEnvelope = EnvelopeModel.GetById(oId) Dim oEnvelope = EnvelopeModel.GetById(oId)
If oEnvelope Is Nothing Then If oEnvelope Is Nothing Then
@ -147,7 +146,7 @@ Namespace Jobs
Directory.CreateDirectory(oOutputDirectoryPath) Directory.CreateDirectory(oOutputDirectoryPath)
End If End If
Dim oOutputFilePath = Path.Combine(oOutputDirectoryPath, $"{oEnvelope.Uuid}.pdf") Dim oOutputFilePath = Path.Combine(oOutputDirectoryPath, $"{oEnvelope.Uuid}.pdf")
Logger.Info("Writing finalized Pdf to disk..") Logger.Debug("Writing finalized Pdf to disk..")
Logger.Info("Output path is [{0}]", oOutputFilePath) Logger.Info("Output path is [{0}]", oOutputFilePath)
Try Try
@ -157,12 +156,14 @@ Namespace Jobs
Throw New ExportDocumentException("Could not export final document to disk!", ex) Throw New ExportDocumentException("Could not export final document to disk!", ex)
End Try End Try
Logger.Info("Writing EB-bytes to database...") Logger.Debug("Writing EB-bytes to database...")
Update_File_DB(oOutputFilePath, oEnvelope.Id) Update_File_DB(oOutputFilePath, oEnvelope.Id)
Logger.Info("Sending finalized report-mails..")
If SendFinalEmails(oEnvelope) = False Then ', oOutputFilePath If SendFinalEmails(oEnvelope) = False Then ', oOutputFilePath
Throw New ApplicationException("Final emails could not be sent!") Throw New ApplicationException("Final emails could not be sent!")
Else
Logger.Info("Report-mails successfully sent!")
End If End If
Logger.Debug("Setting envelope status..") Logger.Debug("Setting envelope status..")
If ActionService.FinalizeEnvelope(oEnvelope) = False Then If ActionService.FinalizeEnvelope(oEnvelope) = False Then
@ -175,7 +176,7 @@ Namespace Jobs
oCurrent += 1 oCurrent += 1
Logger.Info("Envelope finalized!") Logger.Info($"Envelope [{oId}] finalized!")
Next Next
@ -192,7 +193,7 @@ Namespace Jobs
Logger.Warn("Certificate Document job failed!") Logger.Warn("Certificate Document job failed!")
Logger.Error(ex) Logger.Error(ex)
Finally Finally
Logger.Info("Job execution for [{0}] ended", JobId) Logger.Debug("Job execution for [{0}] ended", JobId)
End Try End Try
Return Task.FromResult(True) Return Task.FromResult(True)
@ -290,11 +291,15 @@ Namespace Jobs
If oMailToCreator <> FinalEmailType.No Then If oMailToCreator <> FinalEmailType.No Then
Logger.Debug("Sending email to creator ...") Logger.Debug("Sending email to creator ...")
SendFinalEmailToCreator(pEnvelope) ', pAttachment SendFinalEmailToCreator(pEnvelope) ', pAttachment
Else
Logger.Warn($"No SendFinalEmailToCreator - oMailToCreator [{oMailToCreator}] <> [{FinalEmailType.No}] ")
End If End If
If oMailToReceivers <> FinalEmailType.No Then If oMailToReceivers <> FinalEmailType.No Then
Logger.Debug("Sending emails to receivers..") Logger.Debug("Sending emails to receivers..")
SendFinalEmailToReceivers(pEnvelope) ', pAttachment SendFinalEmailToReceivers(pEnvelope) ', pAttachment
Else
Logger.Warn($"No SendFinalEmailToReceivers - oMailToCreator [{oMailToReceivers}] <> [{FinalEmailType.No}] ")
End If End If
Return True Return True
@ -355,9 +360,9 @@ Namespace Jobs
oInputPath = pEnvelopeData.DocumentPath oInputPath = pEnvelopeData.DocumentPath
Logger.Info($"Input path: [{oInputPath}]") Logger.Info($"Input path: [{oInputPath}]")
Else Else
Logger.Info($"we got bytes..") Logger.Debug($"we got bytes..")
oInputPath = Config.DocumentPathOrigin oInputPath = Config.DocumentPathOrigin
Logger.Info($"oInputPath: {Config.DocumentPathOrigin}") Logger.Debug($"oInputPath: {Config.DocumentPathOrigin}")
End If End If
@ -421,7 +426,7 @@ Namespace Jobs
End Function End Function
Private Sub InitializeServices(pState As State) Private Sub InitializeServices(pState As State)
ActionService = New ActionService(pState) ActionService = New ActionService(pState, Database)
End Sub End Sub
Private Sub InitializeModels(pState As State) Private Sub InitializeModels(pState As State)

View File

@ -18,7 +18,7 @@ Public Class EmailModel
oCommand.Parameters.Add("EMAIL_ADRESS", SqlDbType.NVarChar).Value = pEmail.EmailAdress oCommand.Parameters.Add("EMAIL_ADRESS", SqlDbType.NVarChar).Value = pEmail.EmailAdress
oCommand.Parameters.Add("EMAIL_SUBJ", SqlDbType.NVarChar).Value = pEmail.EmailSubject oCommand.Parameters.Add("EMAIL_SUBJ", SqlDbType.NVarChar).Value = pEmail.EmailSubject
oCommand.Parameters.Add("EMAIL_BODY", SqlDbType.NVarChar).Value = pEmail.EmailBody oCommand.Parameters.Add("EMAIL_BODY", SqlDbType.NVarChar).Value = pEmail.EmailBody
oCommand.Parameters.Add("ADDED_WHO", SqlDbType.NVarChar).Value = "DDEnvelopGenerator" oCommand.Parameters.Add("ADDED_WHO", SqlDbType.NVarChar).Value = pEmail.ADDED_WHO_PROCESS
oCommand.Parameters.Add("SENDING_PROFILE", SqlDbType.Int).Value = State.DbConfig.SendingProfile oCommand.Parameters.Add("SENDING_PROFILE", SqlDbType.Int).Value = State.DbConfig.SendingProfile
oCommand.Parameters.Add("REFERENCE_ID", SqlDbType.Int).Value = pEmail.ReferenceID oCommand.Parameters.Add("REFERENCE_ID", SqlDbType.Int).Value = pEmail.ReferenceID
oCommand.Parameters.Add("REFERENCE_STRING", SqlDbType.NVarChar).Value = pEmail.ReferenceString oCommand.Parameters.Add("REFERENCE_STRING", SqlDbType.NVarChar).Value = pEmail.ReferenceString

View File

@ -35,7 +35,7 @@ Public Class EnvelopeModel
.Language = pRow.ItemEx("LANGUAGE", "de-DE"), .Language = pRow.ItemEx("LANGUAGE", "de-DE"),
.Status = ObjectEx.ToEnum(Of Constants.EnvelopeStatus)(pRow.ItemEx("STATUS", Constants.EnvelopeStatus.EnvelopeCreated.ToString())), .Status = ObjectEx.ToEnum(Of Constants.EnvelopeStatus)(pRow.ItemEx("STATUS", Constants.EnvelopeStatus.EnvelopeCreated.ToString())),
.AddedWhen = pRow.Item("ADDED_WHEN"), .AddedWhen = pRow.Item("ADDED_WHEN"),
.ChangedWhen = pRow.Item("CHANGED_WHEN"), .ChangedWhen = pRow.ItemEx(Of Date)("CHANGED_WHEN", Nothing),
.CertificationType = ObjectEx.ToEnum(Of Constants.CertificationType)(pRow.ItemEx("CERTIFICATION_TYPE", Constants.CertificationType.AdvancedElectronicSignature.ToString())), .CertificationType = ObjectEx.ToEnum(Of Constants.CertificationType)(pRow.ItemEx("CERTIFICATION_TYPE", Constants.CertificationType.AdvancedElectronicSignature.ToString())),
.User = New User(), .User = New User(),
.ExpiresWhen = pRow.ItemEx(Of Date)("EXPIRES_WHEN", Nothing), .ExpiresWhen = pRow.ItemEx(Of Date)("EXPIRES_WHEN", Nothing),

View File

@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' indem Sie "*" wie unten gezeigt eingeben: ' indem Sie "*" wie unten gezeigt eingeben:
' <Assembly: AssemblyVersion("1.0.*")> ' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("2.5.0.0")> <Assembly: AssemblyVersion("2.7.0.0")>
<Assembly: AssemblyFileVersion("2.5.0.0")> <Assembly: AssemblyFileVersion("2.7.0.0")>

View File

@ -2,19 +2,24 @@
Imports DigitalData.Modules.Base Imports DigitalData.Modules.Base
Imports EnvelopeGenerator.Common.Constants Imports EnvelopeGenerator.Common.Constants
Imports EnvelopeGenerator.Common.My.Resources Imports EnvelopeGenerator.Common.My.Resources
Imports DigitalData.Modules.Database
Imports System.ComponentModel
Public Class ActionService Public Class ActionService
Inherits BaseService Inherits BaseService
Private ReadOnly EmailService As EmailService Private ReadOnly EmailService As EmailService
Private ReadOnly HistoryService As HistoryService Private ReadOnly HistoryService As HistoryService
Private ReadOnly ReceiverModel As ReceiverModel Private ReadOnly ReceiverModel As ReceiverModel
Private myDatabase As MSSQLServer
Public Sub New(pState As State)
Public Sub New(pState As State, pDD_ECM As MSSQLServer)
MyBase.New(pState) MyBase.New(pState)
myDatabase = pDD_ECM
EmailService = New EmailService(pState) EmailService = New EmailService(pState)
HistoryService = New HistoryService(pState) HistoryService = New HistoryService(pState)
ReceiverModel = New ReceiverModel(pState) ReceiverModel = New ReceiverModel(pState)
@ -63,6 +68,8 @@ Public Class ActionService
Else Else
oStatus = Constants.EnvelopeStatus.EnvelopeDeleted oStatus = Constants.EnvelopeStatus.EnvelopeDeleted
End If End If
Dim oUpd = $"UPDATE TBSIG_ENVELOPE SET REJECTION_REASON = '{pReason}' WHERE GUID = {pEnvelope.Id}"
myDatabase.ExecuteNonQuery(oUpd)
If HistoryService.SetEnvelopeStatus(pEnvelope, oStatus, pEnvelope.User.Email) = False Then If HistoryService.SetEnvelopeStatus(pEnvelope, oStatus, pEnvelope.User.Email) = False Then
Return False Return False
End If End If
@ -77,6 +84,15 @@ Public Class ActionService
Return True Return True
End Function End Function
Public Function API_SendWithdrawn_Mails(pEnvelope As Envelope, pReason As String) As Boolean
Dim oSendResult As Boolean = False
For Each oReceiver As EnvelopeReceiver In pEnvelope.Receivers
If EmailService.SendEnvelopeDeletedEmail(pEnvelope, oReceiver, pReason) = False Then
Return False
End If
Next
Return True
End Function
Public Function OpenEnvelope(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As Boolean Public Function OpenEnvelope(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As Boolean
Dim oUserReference = pReceiver.Email Dim oUserReference = pReceiver.Email

View File

@ -1,13 +1,10 @@
Imports DigitalData.Modules.Base Imports DigitalData.Modules.Base
Public Class BaseService Public Class BaseService
Inherits BaseClass Inherits BaseClass
Friend Property State As State Friend Property State As State
Public Sub New(pState As State) Public Sub New(pState As State)
MyBase.New(pState.LogConfig) MyBase.New(pState.LogConfig)
State = pState State = pState
End Sub End Sub
End Class End Class

View File

@ -17,10 +17,11 @@ Public Class EmailService
End Sub End Sub
Public Function SendEnvelopeDeletedEmail(pEnvelope As Envelope, pReceiver As EnvelopeReceiver, pReason As String) As Boolean Public Function SendEnvelopeDeletedEmail(pEnvelope As Envelope, pReceiver As EnvelopeReceiver, pReason As String) As Boolean
Logger.Debug("Creating email data object.") Logger.Debug("SendEnvelopeDeletedEmail - Creating email data object...")
Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageDeletionSent) With Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageDeletionSent) With
{ {
.SignatureLink = "" .SignatureLink = "",
.ADDED_WHO_PROCESS = pEnvelope.CURRENT_WORK_APP
} }
EmailTemplate.FillEnvelopeDeletedEmailBody(oEmailData, pReason) EmailTemplate.FillEnvelopeDeletedEmailBody(oEmailData, pReason)
@ -37,7 +38,8 @@ Public Class EmailService
Logger.Debug("Creating email data object.") Logger.Debug("Creating email data object.")
Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageInvitationSent) With Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageInvitationSent) With
{ {
.SignatureLink = Helpers.GetEnvelopeURL(State.DbConfig.SignatureHost, pEnvelope.Uuid, pReceiver.Signature) .SignatureLink = Helpers.GetEnvelopeURL(State.DbConfig.SignatureHost, pEnvelope.Uuid, pReceiver.Signature),
.ADDED_WHO_PROCESS = pEnvelope.CURRENT_WORK_APP
} }
EmailTemplate.FillDocumentReceivedEmailBody(oEmailData) EmailTemplate.FillDocumentReceivedEmailBody(oEmailData)
@ -51,9 +53,13 @@ Public Class EmailService
End Function End Function
Public Function GetReceiverUrl(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As String Public Function GetReceiverUrl(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As String
Logger.Debug($"State.DbConfig.SignatureHost: {State.DbConfig.SignatureHost}")
Logger.Debug($" pEnvelope.Uuid: {pEnvelope.Uuid}")
Logger.Debug($" pReceiver.Signature: {pReceiver.Signature}")
Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageInvitationSent) With Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageInvitationSent) With
{ {
.SignatureLink = Helpers.GetEnvelopeURL(State.DbConfig.SignatureHost, pEnvelope.Uuid, pReceiver.Signature) .SignatureLink = Helpers.GetEnvelopeURL(State.DbConfig.SignatureHost, pEnvelope.Uuid, pReceiver.Signature),
.ADDED_WHO_PROCESS = pEnvelope.CURRENT_WORK_APP
} }
Return oEmailData.SignatureLink Return oEmailData.SignatureLink
End Function End Function
@ -61,9 +67,13 @@ Public Class EmailService
Public Function SendDocumentAccessCodeReceivedEmail(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As Boolean Public Function SendDocumentAccessCodeReceivedEmail(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As Boolean
Logger.Debug("Creating email data object.") Logger.Debug("Creating email data object.")
Logger.Debug($"State.DbConfig.SignatureHost: {State.DbConfig.SignatureHost}")
Logger.Debug($" pEnvelope.Uuid: {pEnvelope.Uuid}")
Logger.Debug($" pReceiver.Signature: {pReceiver.Signature}")
Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageAccessCodeSent) With Dim oEmailData As New EmailData(pEnvelope, pReceiver, Constants.EnvelopeStatus.MessageAccessCodeSent) With
{ {
.SignatureLink = Helpers.GetEnvelopeURL(State.DbConfig.SignatureHost, pEnvelope.Uuid, pReceiver.Signature) .SignatureLink = Helpers.GetEnvelopeURL(State.DbConfig.SignatureHost, pEnvelope.Uuid, pReceiver.Signature),
.ADDED_WHO_PROCESS = pEnvelope.CURRENT_WORK_APP
} }
EmailTemplate.FillDocumentAccessCodeReceivedEmailBody(oEmailData) EmailTemplate.FillDocumentAccessCodeReceivedEmailBody(oEmailData)

View File

@ -325,15 +325,6 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Sucht eine lokalisierte Zeichenfolge, die ähnelt.
'''</summary>
Public Shared ReadOnly Property ModificationOriginFile_FormFields() As String
Get
Return ResourceManager.GetString("ModificationOriginFile_FormFields", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Sucht eine lokalisierte Zeichenfolge, die Nein ähnelt. ''' Sucht eine lokalisierte Zeichenfolge, die Nein ähnelt.
'''</summary> '''</summary>
@ -370,6 +361,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Sucht eine lokalisierte Zeichenfolge, die Wollen Sie die 2-Faktor Definition für diesen Empfänger zurücksetzen. Der Empfänger muss sich dann neu identifizieren! ähnelt.
'''</summary>
Public Shared ReadOnly Property ResetTOTPUser() As String
Get
Return ResourceManager.GetString("ResetTOTPUser", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Sucht eine lokalisierte Zeichenfolge, die Gespeichert ähnelt. ''' Sucht eine lokalisierte Zeichenfolge, die Gespeichert ähnelt.
'''</summary> '''</summary>
@ -415,6 +415,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Sucht eine lokalisierte Zeichenfolge, die Erfolgreich! Dialog wird geschlossen. ähnelt.
'''</summary>
Public Shared ReadOnly Property Success_FormClose() As String
Get
Return ResourceManager.GetString("Success_FormClose", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Sucht eine lokalisierte Zeichenfolge, die Unsigniert ähnelt. ''' Sucht eine lokalisierte Zeichenfolge, die Unsigniert ähnelt.
'''</summary> '''</summary>

View File

@ -210,6 +210,9 @@
<data name="ReadAndSign" xml:space="preserve"> <data name="ReadAndSign" xml:space="preserve">
<value>Read and Sign</value> <value>Read and Sign</value>
</data> </data>
<data name="ResetTOTPUser" xml:space="preserve">
<value>Do you want to reset the 2-factor definition for this receiver? The receiver must then identify itself again!</value>
</data>
<data name="Saved" xml:space="preserve"> <data name="Saved" xml:space="preserve">
<value>Saved</value> <value>Saved</value>
</data> </data>
@ -225,6 +228,9 @@
<data name="Signed" xml:space="preserve"> <data name="Signed" xml:space="preserve">
<value>Signed</value> <value>Signed</value>
</data> </data>
<data name="Success_FormClose" xml:space="preserve">
<value>Successful! Dialog is closed.successful! Dialog is closed.</value>
</data>
<data name="Unsigned" xml:space="preserve"> <data name="Unsigned" xml:space="preserve">
<value>Unsigned</value> <value>Unsigned</value>
</data> </data>

View File

@ -216,6 +216,9 @@
<data name="ReadAndSign" xml:space="preserve"> <data name="ReadAndSign" xml:space="preserve">
<value>Arbeitsanweisung</value> <value>Arbeitsanweisung</value>
</data> </data>
<data name="ResetTOTPUser" xml:space="preserve">
<value>Wollen Sie die 2-Faktor Definition für diesen Empfänger zurücksetzen. Der Empfänger muss sich dann neu identifizieren!</value>
</data>
<data name="Saved" xml:space="preserve"> <data name="Saved" xml:space="preserve">
<value>Gespeichert</value> <value>Gespeichert</value>
</data> </data>
@ -231,6 +234,9 @@
<data name="Signed" xml:space="preserve"> <data name="Signed" xml:space="preserve">
<value>Signiert</value> <value>Signiert</value>
</data> </data>
<data name="Success_FormClose" xml:space="preserve">
<value>Erfolgreich! Dialog wird geschlossen.</value>
</data>
<data name="Unsigned" xml:space="preserve"> <data name="Unsigned" xml:space="preserve">
<value>Unsigniert</value> <value>Unsigniert</value>
</data> </data>

View File

@ -28,7 +28,7 @@ Public MustInherit Class BaseController
State = pState State = pState
Database = pState.Database Database = pState.Database
InitializeModels(pState) InitializeModels(pState)
ActionService = New ActionService(pState) ActionService = New ActionService(pState, Database)
End Sub End Sub
Private Sub InitializeModels(pState As State) Private Sub InitializeModels(pState As State)

View File

@ -22,7 +22,7 @@ Public Class EnvelopeEditorController
Envelope = CreateEnvelope() Envelope = CreateEnvelope()
Thumbnail = New Thumbnail(pState.LogConfig) Thumbnail = New Thumbnail(pState.LogConfig)
EmailService = New EmailService(pState) EmailService = New EmailService(pState)
ActionService = New ActionService(pState) ActionService = New ActionService(pState, Nothing)
End Sub End Sub
Public Sub New(pState As State, pEnvelope As Envelope) Public Sub New(pState As State, pEnvelope As Envelope)
@ -33,7 +33,7 @@ Public Class EnvelopeEditorController
Envelope.Receivers = ReceiverModel.ListEnvelopeReceivers(pEnvelope.Id).ToList() Envelope.Receivers = ReceiverModel.ListEnvelopeReceivers(pEnvelope.Id).ToList()
Thumbnail = New Thumbnail(pState.LogConfig) Thumbnail = New Thumbnail(pState.LogConfig)
ActionService = New ActionService(pState) ActionService = New ActionService(pState, Nothing)
End Sub End Sub
#Region "Public" #Region "Public"

View File

@ -319,6 +319,12 @@
<Compile Include="Controllers\EnvelopeListController.vb" /> <Compile Include="Controllers\EnvelopeListController.vb" />
<Compile Include="Controllers\FieldEditorController.vb" /> <Compile Include="Controllers\FieldEditorController.vb" />
<Compile Include="Controllers\BaseController.vb" /> <Compile Include="Controllers\BaseController.vb" />
<Compile Include="frm2Factor_Properties.Designer.vb">
<DependentUpon>frm2Factor_Properties.vb</DependentUpon>
</Compile>
<Compile Include="frm2Factor_Properties.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmEnvelopeEditor.vb"> <Compile Include="frmEnvelopeEditor.vb">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
@ -381,6 +387,9 @@
<DesignTime>True</DesignTime> <DesignTime>True</DesignTime>
</Compile> </Compile>
<Compile Include="My Project\AssemblyInfo.vb" /> <Compile Include="My Project\AssemblyInfo.vb" />
<EmbeddedResource Include="frm2Factor_Properties.resx">
<DependentUpon>frm2Factor_Properties.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmEnvelopeEditor.en.resx"> <EmbeddedResource Include="frmEnvelopeEditor.en.resx">
<DependentUpon>frmEnvelopeEditor.vb</DependentUpon> <DependentUpon>frmEnvelopeEditor.vb</DependentUpon>
<SubType>Designer</SubType> <SubType>Designer</SubType>

View File

@ -0,0 +1,121 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class frm2Factor_Properties
Inherits System.Windows.Forms.Form
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
Try
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
Finally
MyBase.Dispose(disposing)
End Try
End Sub
'Wird vom Windows Form-Designer benötigt.
Private components As System.ComponentModel.IContainer
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frm2Factor_Properties))
Me.txtMail = New System.Windows.Forms.TextBox()
Me.txtValid = New System.Windows.Forms.TextBox()
Me.chkTOTP = New System.Windows.Forms.CheckBox()
Me.Label1 = New System.Windows.Forms.Label()
Me.Label3 = New System.Windows.Forms.Label()
Me.SimpleButton1 = New DevExpress.XtraEditors.SimpleButton()
Me.SuspendLayout()
'
'txtMail
'
Me.txtMail.Font = New System.Drawing.Font("Tahoma", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.txtMail.Location = New System.Drawing.Point(85, 24)
Me.txtMail.Name = "txtMail"
Me.txtMail.ReadOnly = True
Me.txtMail.Size = New System.Drawing.Size(342, 23)
Me.txtMail.TabIndex = 0
'
'txtValid
'
Me.txtValid.Font = New System.Drawing.Font("Tahoma", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.txtValid.Location = New System.Drawing.Point(85, 79)
Me.txtValid.Name = "txtValid"
Me.txtValid.ReadOnly = True
Me.txtValid.Size = New System.Drawing.Size(202, 23)
Me.txtValid.TabIndex = 1
'
'chkTOTP
'
Me.chkTOTP.AutoSize = True
Me.chkTOTP.Font = New System.Drawing.Font("Tahoma", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.chkTOTP.Location = New System.Drawing.Point(85, 53)
Me.chkTOTP.Name = "chkTOTP"
Me.chkTOTP.Size = New System.Drawing.Size(151, 20)
Me.chkTOTP.TabIndex = 2
Me.chkTOTP.Text = "Secret Key vorhanden"
Me.chkTOTP.UseVisualStyleBackColor = True
'
'Label1
'
Me.Label1.AutoSize = True
Me.Label1.Font = New System.Drawing.Font("Tahoma", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label1.Location = New System.Drawing.Point(12, 27)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(47, 16)
Me.Label1.TabIndex = 3
Me.Label1.Text = "E-Mail:"
'
'Label3
'
Me.Label3.AutoSize = True
Me.Label3.Font = New System.Drawing.Font("Tahoma", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label3.Location = New System.Drawing.Point(15, 82)
Me.Label3.Name = "Label3"
Me.Label3.Size = New System.Drawing.Size(64, 16)
Me.Label3.TabIndex = 5
Me.Label3.Text = "Gültig bis:"
'
'SimpleButton1
'
Me.SimpleButton1.Appearance.Font = New System.Drawing.Font("Tahoma", 9.75!)
Me.SimpleButton1.Appearance.Options.UseFont = True
Me.SimpleButton1.ImageOptions.SvgImage = CType(resources.GetObject("SimpleButton1.ImageOptions.SvgImage"), DevExpress.Utils.Svg.SvgImage)
Me.SimpleButton1.Location = New System.Drawing.Point(18, 121)
Me.SimpleButton1.Name = "SimpleButton1"
Me.SimpleButton1.Size = New System.Drawing.Size(116, 40)
Me.SimpleButton1.TabIndex = 6
Me.SimpleButton1.Text = "Zurücksetzen"
'
'frm2Factor_Properties
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(443, 170)
Me.Controls.Add(Me.SimpleButton1)
Me.Controls.Add(Me.Label3)
Me.Controls.Add(Me.Label1)
Me.Controls.Add(Me.chkTOTP)
Me.Controls.Add(Me.txtValid)
Me.Controls.Add(Me.txtMail)
Me.MaximizeBox = False
Me.MinimizeBox = False
Me.Name = "frm2Factor_Properties"
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
Me.Text = "Zwei-Faktor Eigenschaften Empfänger:"
Me.ResumeLayout(False)
Me.PerformLayout()
End Sub
Friend WithEvents txtMail As TextBox
Friend WithEvents txtValid As TextBox
Friend WithEvents chkTOTP As CheckBox
Friend WithEvents Label1 As Label
Friend WithEvents Label3 As Label
Friend WithEvents SimpleButton1 As DevExpress.XtraEditors.SimpleButton
End Class

View File

@ -0,0 +1,141 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<assembly alias="DevExpress.Data.v21.2" name="DevExpress.Data.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<data name="SimpleButton1.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v21.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjIxLjIsIFZlcnNpb249MjEuMi40
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAANcCAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLkdyZWVue2ZpbGw6IzAzOUMyMzt9Cgku
QmxhY2t7ZmlsbDojNzI3MjcyO30KCS5SZWR7ZmlsbDojRDExQzFDO30KCS5ZZWxsb3d7ZmlsbDojRkZC
MTE1O30KCS5CbHVle2ZpbGw6IzExNzdENzt9CgkuV2hpdGV7ZmlsbDojRkZGRkZGO30KCS5zdDB7b3Bh
Y2l0eTowLjU7fQoJLnN0MXtvcGFjaXR5OjAuNzU7fQo8L3N0eWxlPg0KICA8ZyBpZD0iUmVzZXRMYXlv
dXRPcHRpb25zIj4NCiAgICA8cGF0aCBkPSJNMTYsNGMtMy4zLDAtNi4zLDEuMy04LjUsMy41TDQsNHYx
MGgwLjJoNC4xSDE0bC0zLjYtMy42QzExLjgsOC45LDEzLjgsOCwxNiw4YzQuNCwwLDgsMy42LDgsOHMt
My42LDgtOCw4ICAgYy0zLjcsMC02LjgtMi42LTcuNy02SDQuMmMxLDUuNyw1LjksMTAsMTEuOCwxMGM2
LjYsMCwxMi01LjQsMTItMTJTMjIuNiw0LDE2LDR6IiBjbGFzcz0iR3JlZW4iIC8+DQogIDwvZz4NCjwv
c3ZnPgs=
</value>
</data>
</root>

View File

@ -0,0 +1,43 @@
Imports DigitalData.Modules.Database
Imports EnvelopeGenerator.Common.My
Public Class frm2Factor_Properties
Private Sub SimpleButton1_Click(sender As Object, e As EventArgs) Handles SimpleButton1.Click
If MsgBox(Resources.Model.ResetTOTPUser, MsgBoxStyle.Question Or MsgBoxStyle.YesNo, Text) = MsgBoxResult.Yes Then
Dim oupdSQL = $"UPDATE TBSIG_RECEIVER SET TOTP_SECRET_KEY = NULL, TFA_REG_DEADLINE = NULL WHERE EMAIL_ADDRESS = '{txtMail.Text}'"
If DD_ECM.ExecuteNonQuery(oupdSQL) = True Then
MsgBox(Resources.Model.Success_FormClose, MsgBoxStyle.Information)
Me.Close()
Else
MsgBox("Something went wrong. Check the log", MsgBoxStyle.Exclamation)
End If
End If
End Sub
Dim TOTP As String
Dim mail As String
Dim Deadline As DateTime
Dim DD_ECM As MSSQLServer
Public Sub New(pmail As String, pTOTP As String, pDeadline As DateTime, pDD_ECM As MSSQLServer)
' Dieser Aufruf ist für den Designer erforderlich.
InitializeComponent()
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
mail = pmail
TOTP = pTOTP
Deadline = pDeadline
DD_ECM = pDD_ECM
End Sub
Private Sub frm2Faktor_Load(sender As Object, e As EventArgs) Handles Me.Load
chkTOTP.Checked = False
If Not IsNothing(TOTP) Then
If TOTP.Length > 1 Then
chkTOTP.Checked = True
End If
End If
txtMail.Text = mail
txtValid.Text = Deadline.ToString
End Sub
End Class

View File

@ -939,7 +939,7 @@
<value>0</value> <value>0</value>
</data> </data>
<metadata name="FrmEditorBindingSource.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> <metadata name="FrmEditorBindingSource.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 54</value> <value>792, 17</value>
</metadata> </metadata>
<metadata name="EnvelopeDocumentBindingSource.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> <metadata name="EnvelopeDocumentBindingSource.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>557, 17</value> <value>557, 17</value>

View File

@ -763,4 +763,6 @@ Partial Public Class frmEnvelopeEditor
Process.Start(Documents.Item(0).Filepath) Process.Start(Documents.Item(0).Filepath)
End If End If
End Sub End Sub
End Class End Class

View File

@ -65,6 +65,9 @@ Public Class frmEnvelopeMainData
chked_2Faktor.EditValue = DEF_TF_ENABLED chked_2Faktor.EditValue = DEF_TF_ENABLED
Else Else
If IsNothing(Envelope.EnvelopeType) Then
Envelope.EnvelopeType = EnvelopeType
End If
If Envelope.EnvelopeType.ContractType = 0 Then If Envelope.EnvelopeType.ContractType = 0 Then
cmbEnvelopeType.EditValue = EnvelopeType cmbEnvelopeType.EditValue = EnvelopeType
Else Else

View File

@ -66,6 +66,7 @@ Partial Class frmMain
Me.BarButtonItem3 = New DevExpress.XtraBars.BarButtonItem() Me.BarButtonItem3 = New DevExpress.XtraBars.BarButtonItem()
Me.BarButtonItem4 = New DevExpress.XtraBars.BarButtonItem() Me.BarButtonItem4 = New DevExpress.XtraBars.BarButtonItem()
Me.BarStaticItemGhost = New DevExpress.XtraBars.BarStaticItem() Me.BarStaticItemGhost = New DevExpress.XtraBars.BarStaticItem()
Me.bbtnitm2Faktor = New DevExpress.XtraBars.BarButtonItem()
Me.RibbonPage1 = New DevExpress.XtraBars.Ribbon.RibbonPage() Me.RibbonPage1 = New DevExpress.XtraBars.Ribbon.RibbonPage()
Me.RibbonPageEnvelopeActions = New DevExpress.XtraBars.Ribbon.RibbonPageGroup() Me.RibbonPageEnvelopeActions = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
Me.RibbonPageGroup1 = New DevExpress.XtraBars.Ribbon.RibbonPageGroup() Me.RibbonPageGroup1 = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
@ -103,6 +104,10 @@ Partial Class frmMain
Me.btnEnvelopes_thisYear = New DevExpress.XtraEditors.SimpleButton() Me.btnEnvelopes_thisYear = New DevExpress.XtraEditors.SimpleButton()
Me.btnEnvelopes_lastmonth = New DevExpress.XtraEditors.SimpleButton() Me.btnEnvelopes_lastmonth = New DevExpress.XtraEditors.SimpleButton()
Me.btnEnvelopes_thismonth = New DevExpress.XtraEditors.SimpleButton() Me.btnEnvelopes_thismonth = New DevExpress.XtraEditors.SimpleButton()
Me.XtraTabPage3 = New DevExpress.XtraTab.XtraTabPage()
Me.Label1 = New System.Windows.Forms.Label()
Me.Button1 = New System.Windows.Forms.Button()
Me.txtEnvID = New System.Windows.Forms.TextBox()
Me.RefreshTimer = New System.Windows.Forms.Timer(Me.components) Me.RefreshTimer = New System.Windows.Forms.Timer(Me.components)
Me.SaveFileDialog1 = New System.Windows.Forms.SaveFileDialog() Me.SaveFileDialog1 = New System.Windows.Forms.SaveFileDialog()
Me.XtraSaveFileDialog1 = New DevExpress.XtraEditors.XtraSaveFileDialog(Me.components) Me.XtraSaveFileDialog1 = New DevExpress.XtraEditors.XtraSaveFileDialog(Me.components)
@ -138,6 +143,7 @@ Partial Class frmMain
Me.GroupControl2.SuspendLayout() Me.GroupControl2.SuspendLayout()
CType(Me.GroupControl1, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.GroupControl1, System.ComponentModel.ISupportInitialize).BeginInit()
Me.GroupControl1.SuspendLayout() Me.GroupControl1.SuspendLayout()
Me.XtraTabPage3.SuspendLayout()
Me.SuspendLayout() Me.SuspendLayout()
' '
'SplashScreenManager1 'SplashScreenManager1
@ -167,7 +173,7 @@ Partial Class frmMain
resources.ApplyResources(Me.XtraTabControlMain, "XtraTabControlMain") resources.ApplyResources(Me.XtraTabControlMain, "XtraTabControlMain")
Me.XtraTabControlMain.Name = "XtraTabControlMain" Me.XtraTabControlMain.Name = "XtraTabControlMain"
Me.XtraTabControlMain.SelectedTabPage = Me.XtraTabPage1 Me.XtraTabControlMain.SelectedTabPage = Me.XtraTabPage1
Me.XtraTabControlMain.TabPages.AddRange(New DevExpress.XtraTab.XtraTabPage() {Me.XtraTabPage1, Me.XtraTabPage2, Me.XtraTabPageAdmin}) Me.XtraTabControlMain.TabPages.AddRange(New DevExpress.XtraTab.XtraTabPage() {Me.XtraTabPage1, Me.XtraTabPage2, Me.XtraTabPageAdmin, Me.XtraTabPage3})
' '
'XtraTabPage1 'XtraTabPage1
' '
@ -334,9 +340,9 @@ Partial Class frmMain
Me.RibbonControl.ExpandCollapseItem.Id = 0 Me.RibbonControl.ExpandCollapseItem.Id = 0
Me.RibbonControl.ExpandCollapseItem.ImageOptions.ImageIndex = CType(resources.GetObject("RibbonControl.ExpandCollapseItem.ImageOptions.ImageIndex"), Integer) Me.RibbonControl.ExpandCollapseItem.ImageOptions.ImageIndex = CType(resources.GetObject("RibbonControl.ExpandCollapseItem.ImageOptions.ImageIndex"), Integer)
Me.RibbonControl.ExpandCollapseItem.ImageOptions.LargeImageIndex = CType(resources.GetObject("RibbonControl.ExpandCollapseItem.ImageOptions.LargeImageIndex"), Integer) Me.RibbonControl.ExpandCollapseItem.ImageOptions.LargeImageIndex = CType(resources.GetObject("RibbonControl.ExpandCollapseItem.ImageOptions.LargeImageIndex"), Integer)
Me.RibbonControl.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.RibbonControl.ExpandCollapseItem, Me.RibbonControl.SearchEditItem, Me.btnCreateEnvelope, Me.btnEditEnvelope, Me.btnDeleteEnvelope, Me.BarButtonItem1, Me.txtRefreshLabel, Me.btnShowDocument, Me.btnContactReceiver, Me.txtEnvelopeIdLabel, Me.btnOpenLogDirectory, Me.BarCheckItem1, Me.bsitmInfo, Me.bbtnitmEB, Me.bbtnitmInfoMail, Me.bbtnitm_ResendInvitation, Me.BarButtonItem3, Me.BarButtonItem4, Me.BarStaticItemGhost}) Me.RibbonControl.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.RibbonControl.ExpandCollapseItem, Me.RibbonControl.SearchEditItem, Me.btnCreateEnvelope, Me.btnEditEnvelope, Me.btnDeleteEnvelope, Me.BarButtonItem1, Me.txtRefreshLabel, Me.btnShowDocument, Me.btnContactReceiver, Me.txtEnvelopeIdLabel, Me.btnOpenLogDirectory, Me.BarCheckItem1, Me.bsitmInfo, Me.bbtnitmEB, Me.bbtnitmInfoMail, Me.bbtnitm_ResendInvitation, Me.BarButtonItem3, Me.BarButtonItem4, Me.BarStaticItemGhost, Me.bbtnitm2Faktor})
resources.ApplyResources(Me.RibbonControl, "RibbonControl") resources.ApplyResources(Me.RibbonControl, "RibbonControl")
Me.RibbonControl.MaxItemId = 20 Me.RibbonControl.MaxItemId = 21
Me.RibbonControl.Name = "RibbonControl" Me.RibbonControl.Name = "RibbonControl"
Me.RibbonControl.Pages.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPage() {Me.RibbonPage1, Me.RibbonPage2}) Me.RibbonControl.Pages.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPage() {Me.RibbonPage1, Me.RibbonPage2})
Me.RibbonControl.ShowApplicationButton = DevExpress.Utils.DefaultBoolean.[False] Me.RibbonControl.ShowApplicationButton = DevExpress.Utils.DefaultBoolean.[False]
@ -494,6 +500,13 @@ Partial Class frmMain
Me.BarStaticItemGhost.Name = "BarStaticItemGhost" Me.BarStaticItemGhost.Name = "BarStaticItemGhost"
Me.BarStaticItemGhost.Visibility = DevExpress.XtraBars.BarItemVisibility.Never Me.BarStaticItemGhost.Visibility = DevExpress.XtraBars.BarItemVisibility.Never
' '
'bbtnitm2Faktor
'
resources.ApplyResources(Me.bbtnitm2Faktor, "bbtnitm2Faktor")
Me.bbtnitm2Faktor.Id = 20
Me.bbtnitm2Faktor.ImageOptions.SvgImage = CType(resources.GetObject("bbtnitm2Faktor.ImageOptions.SvgImage"), DevExpress.Utils.Svg.SvgImage)
Me.bbtnitm2Faktor.Name = "bbtnitm2Faktor"
'
'RibbonPage1 'RibbonPage1
' '
Me.RibbonPage1.Groups.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPageGroup() {Me.RibbonPageEnvelopeActions, Me.RibbonPageGroup1, Me.RibbonPageGroupFunctions}) Me.RibbonPage1.Groups.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPageGroup() {Me.RibbonPageEnvelopeActions, Me.RibbonPageGroup1, Me.RibbonPageGroupFunctions})
@ -521,6 +534,7 @@ Partial Class frmMain
Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.btnShowDocument) Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.btnShowDocument)
Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.bbtnitm_ResendInvitation) Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.bbtnitm_ResendInvitation)
Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.btnContactReceiver) Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.btnContactReceiver)
Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.bbtnitm2Faktor)
Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.bbtnitmEB) Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.bbtnitmEB)
Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.bbtnitmInfoMail) Me.RibbonPageGroupFunctions.ItemLinks.Add(Me.bbtnitmInfoMail)
Me.RibbonPageGroupFunctions.Name = "RibbonPageGroupFunctions" Me.RibbonPageGroupFunctions.Name = "RibbonPageGroupFunctions"
@ -791,6 +805,30 @@ Partial Class frmMain
resources.ApplyResources(Me.btnEnvelopes_thismonth, "btnEnvelopes_thismonth") resources.ApplyResources(Me.btnEnvelopes_thismonth, "btnEnvelopes_thismonth")
Me.btnEnvelopes_thismonth.Name = "btnEnvelopes_thismonth" Me.btnEnvelopes_thismonth.Name = "btnEnvelopes_thismonth"
' '
'XtraTabPage3
'
Me.XtraTabPage3.Controls.Add(Me.Label1)
Me.XtraTabPage3.Controls.Add(Me.Button1)
Me.XtraTabPage3.Controls.Add(Me.txtEnvID)
Me.XtraTabPage3.Name = "XtraTabPage3"
resources.ApplyResources(Me.XtraTabPage3, "XtraTabPage3")
'
'Label1
'
resources.ApplyResources(Me.Label1, "Label1")
Me.Label1.Name = "Label1"
'
'Button1
'
resources.ApplyResources(Me.Button1, "Button1")
Me.Button1.Name = "Button1"
Me.Button1.UseVisualStyleBackColor = True
'
'txtEnvID
'
resources.ApplyResources(Me.txtEnvID, "txtEnvID")
Me.txtEnvID.Name = "txtEnvID"
'
'RefreshTimer 'RefreshTimer
' '
Me.RefreshTimer.Interval = 120000 Me.RefreshTimer.Interval = 120000
@ -846,6 +884,8 @@ Partial Class frmMain
Me.GroupControl2.ResumeLayout(False) Me.GroupControl2.ResumeLayout(False)
CType(Me.GroupControl1, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.GroupControl1, System.ComponentModel.ISupportInitialize).EndInit()
Me.GroupControl1.ResumeLayout(False) Me.GroupControl1.ResumeLayout(False)
Me.XtraTabPage3.ResumeLayout(False)
Me.XtraTabPage3.PerformLayout()
Me.ResumeLayout(False) Me.ResumeLayout(False)
Me.PerformLayout() Me.PerformLayout()
@ -931,4 +971,9 @@ Partial Class frmMain
Friend WithEvents btnEvvallUs_lastmonth As DevExpress.XtraEditors.SimpleButton Friend WithEvents btnEvvallUs_lastmonth As DevExpress.XtraEditors.SimpleButton
Friend WithEvents GridColumn1 As DevExpress.XtraGrid.Columns.GridColumn Friend WithEvents GridColumn1 As DevExpress.XtraGrid.Columns.GridColumn
Friend WithEvents GridColumn2 As DevExpress.XtraGrid.Columns.GridColumn Friend WithEvents GridColumn2 As DevExpress.XtraGrid.Columns.GridColumn
Friend WithEvents bbtnitm2Faktor As DevExpress.XtraBars.BarButtonItem
Friend WithEvents XtraTabPage3 As DevExpress.XtraTab.XtraTabPage
Friend WithEvents Label1 As Label
Friend WithEvents Button1 As Button
Friend WithEvents txtEnvID As TextBox
End Class End Class

View File

@ -868,6 +868,43 @@
<data name="BarStaticItemGhost.ItemAppearance.Normal.Font" type="System.Drawing.Font, System.Drawing"> <data name="BarStaticItemGhost.ItemAppearance.Normal.Font" type="System.Drawing.Font, System.Drawing">
<value>Tahoma, 8.25pt, style=Bold</value> <value>Tahoma, 8.25pt, style=Bold</value>
</data> </data>
<data name="bbtnitm2Faktor.Caption" xml:space="preserve">
<value>2Faktor Eigenschaften</value>
</data>
<data name="bbtnitm2Faktor.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v21.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjIxLjIsIFZlcnNpb249MjEuMi40
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAC4GAAAC77u/
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLkJsYWNre2ZpbGw6IzcyNzI3Mjt9Cgku
UmVke2ZpbGw6I0QxMUMxQzt9CgkuWWVsbG93e2ZpbGw6I0ZGQjExNTt9CgkuR3JlZW57ZmlsbDojMDM5
QzIzO30KPC9zdHlsZT4NCiAgPGcgaWQ9IkZpbmdlcnByaW50Ij4NCiAgICA8cGF0aCBkPSJNMjMsNmMt
MC4yLDAtMC40LTAuMS0wLjUtMC4yYy0wLjMtMC4yLTYuNi00LjEtMTUsMEM3LDYuMSw2LjQsNS45LDYu
MSw1LjRjLTAuMi0wLjUsMC0xLjEsMC41LTEuMyAgIEMxNi0wLjYsMjMuMiw0LDIzLjUsNC4yYzAuNSww
LjMsMC42LDAuOSwwLjMsMS40QzIzLjYsNS44LDIzLjMsNiwyMyw2eiBNMy43LDEzLjdjMTAuOS0xMS40
LDIyLjItMi4zLDIyLjYtMS45ICAgYzAuNCwwLjQsMS4xLDAuMywxLjQtMC4xYzAuNC0wLjQsMC4zLTEu
MS0wLjEtMS40Yy0wLjEtMC4xLTEzLjEtMTAuNy0yNS40LDIuMWMtMC40LDAuNC0wLjQsMSwwLDEuNEMy
LjUsMTMuOSwyLjgsMTQsMywxNCAgIEMzLjMsMTQsMy41LDEzLjksMy43LDEzLjd6IE0yNCwyN2MwLTAu
Ni0wLjQtMS0xLTFjLTUuMywwLTctMy4zLTcuMS0zLjRjLTAuMi0wLjUtMC44LTAuNy0xLjMtMC40Yy0w
LjUsMC4yLTAuNywwLjgtMC40LDEuMyAgIGMwLjEsMC4yLDIuNCw0LjYsOC45LDQuNkMyMy42LDI4LDI0
LDI3LjYsMjQsMjd6IE0xNS45LDI5LjRjMC4yLTAuNSwwLTEuMS0wLjQtMS4zYzAsMC0zLjUtMS44LTMu
NS01LjFjMC0xLjcsMS4zLTMsMy0zICAgYzEuNiwwLDIuMywwLjgsMy4zLDEuN2MxLDEsMi4zLDIuMyw0
LjcsMi4zYzIuOCwwLDUtMi4yLDUtNWMwLTMuMi00LTktMTItOUM3LjYsMTAsMiwxNiwyLDI1YzAsMC42
LDAuNCwxLDEsMXMxLTAuNCwxLTEgICBjMC03LjksNC43LTEzLDEyLTEzYzYuNiwwLDEwLDQuNiwxMCw3
YzAsMS43LTEuMywzLTMsM2MtMS42LDAtMi4zLTAuOC0zLjMtMS43Yy0xLTEtMi4zLTIuMy00LjctMi4z
Yy0yLjgsMC01LDIuMi01LDUgICBjMCw0LjYsNC40LDYuOCw0LjYsNi45QzE0LjcsMzAsMTQuOCwzMCwx
NSwzMEMxNS40LDMwLDE1LjcsMjkuOCwxNS45LDI5LjR6IE05LjcsMjkuOGMwLjQtMC40LDAuNS0xLDAu
MS0xLjRjMCwwLTEuOC0yLjEtMS44LTUuMyAgIGMwLTIuNCwyLjMtNyw4LTdjNC4zLDAsNiwzLjMsNi4x
LDMuNWMwLjIsMC41LDAuOCwwLjcsMS4zLDAuNGMwLjUtMC4yLDAuNy0wLjgsMC40LTEuM0MyMy44LDE4
LjQsMjEuNiwxNCwxNiwxNCAgIGMtNi41LDAtMTAsNS4yLTEwLDljMCw0LDIuMSw2LjUsMi4yLDYuN0M4
LjQsMjkuOSw4LjcsMzAsOSwzMEM5LjIsMzAsOS41LDI5LjksOS43LDI5Ljh6IiBjbGFzcz0iQmxhY2si
IC8+DQogIDwvZz4NCjwvc3ZnPgs=
</value>
</data>
<data name="RibbonControl.Location" type="System.Drawing.Point, System.Drawing"> <data name="RibbonControl.Location" type="System.Drawing.Point, System.Drawing">
<value>0, 0</value> <value>0, 0</value>
</data> </data>
@ -1462,6 +1499,96 @@
<data name="&gt;&gt;XtraTabPageAdmin.ZOrder" xml:space="preserve"> <data name="&gt;&gt;XtraTabPageAdmin.ZOrder" xml:space="preserve">
<value>2</value> <value>2</value>
</data> </data>
<data name="Label1.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="Label1.Location" type="System.Drawing.Point, System.Drawing">
<value>21, 18</value>
</data>
<data name="Label1.Size" type="System.Drawing.Size, System.Drawing">
<value>66, 13</value>
</data>
<data name="Label1.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="Label1.Text" xml:space="preserve">
<value>EnvelopeID:</value>
</data>
<data name="&gt;&gt;Label1.Name" xml:space="preserve">
<value>Label1</value>
</data>
<data name="&gt;&gt;Label1.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;Label1.Parent" xml:space="preserve">
<value>XtraTabPage3</value>
</data>
<data name="&gt;&gt;Label1.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="Button1.Location" type="System.Drawing.Point, System.Drawing">
<value>24, 85</value>
</data>
<data name="Button1.Size" type="System.Drawing.Size, System.Drawing">
<value>199, 23</value>
</data>
<data name="Button1.TabIndex" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="Button1.Text" xml:space="preserve">
<value>Finalisierung emails prüfen</value>
</data>
<data name="&gt;&gt;Button1.Name" xml:space="preserve">
<value>Button1</value>
</data>
<data name="&gt;&gt;Button1.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;Button1.Parent" xml:space="preserve">
<value>XtraTabPage3</value>
</data>
<data name="&gt;&gt;Button1.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="txtEnvID.Location" type="System.Drawing.Point, System.Drawing">
<value>24, 34</value>
</data>
<data name="txtEnvID.Size" type="System.Drawing.Size, System.Drawing">
<value>100, 20</value>
</data>
<data name="txtEnvID.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name="&gt;&gt;txtEnvID.Name" xml:space="preserve">
<value>txtEnvID</value>
</data>
<data name="&gt;&gt;txtEnvID.Type" xml:space="preserve">
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;txtEnvID.Parent" xml:space="preserve">
<value>XtraTabPage3</value>
</data>
<data name="&gt;&gt;txtEnvID.ZOrder" xml:space="preserve">
<value>2</value>
</data>
<data name="XtraTabPage3.Size" type="System.Drawing.Size, System.Drawing">
<value>1088, 469</value>
</data>
<data name="XtraTabPage3.Text" xml:space="preserve">
<value>Admin Test</value>
</data>
<data name="&gt;&gt;XtraTabPage3.Name" xml:space="preserve">
<value>XtraTabPage3</value>
</data>
<data name="&gt;&gt;XtraTabPage3.Type" xml:space="preserve">
<value>DevExpress.XtraTab.XtraTabPage, DevExpress.XtraEditors.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
</data>
<data name="&gt;&gt;XtraTabPage3.Parent" xml:space="preserve">
<value>XtraTabControlMain</value>
</data>
<data name="&gt;&gt;XtraTabPage3.ZOrder" xml:space="preserve">
<value>3</value>
</data>
<data name="&gt;&gt;XtraTabControlMain.Name" xml:space="preserve"> <data name="&gt;&gt;XtraTabControlMain.Name" xml:space="preserve">
<value>XtraTabControlMain</value> <value>XtraTabControlMain</value>
</data> </data>
@ -1849,6 +1976,12 @@
<data name="&gt;&gt;BarStaticItemGhost.Type" xml:space="preserve"> <data name="&gt;&gt;BarStaticItemGhost.Type" xml:space="preserve">
<value>DevExpress.XtraBars.BarStaticItem, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value> <value>DevExpress.XtraBars.BarStaticItem, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
</data> </data>
<data name="&gt;&gt;bbtnitm2Faktor.Name" xml:space="preserve">
<value>bbtnitm2Faktor</value>
</data>
<data name="&gt;&gt;bbtnitm2Faktor.Type" xml:space="preserve">
<value>DevExpress.XtraBars.BarButtonItem, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
</data>
<data name="&gt;&gt;RibbonPage1.Name" xml:space="preserve"> <data name="&gt;&gt;RibbonPage1.Name" xml:space="preserve">
<value>RibbonPage1</value> <value>RibbonPage1</value>
</data> </data>

View File

@ -14,6 +14,8 @@ Imports System.Diagnostics
Imports System.ComponentModel Imports System.ComponentModel
Imports DevExpress.XtraPrinting Imports DevExpress.XtraPrinting
Imports System.Web Imports System.Web
Imports EnvelopeGenerator.Common.Constants
Imports System.Security.Cryptography
Public Class frmMain Public Class frmMain
Private ReadOnly LogConfig As LogConfig Private ReadOnly LogConfig As LogConfig
@ -55,8 +57,10 @@ Public Class frmMain
End Try End Try
If MYUSER.IsAdmin Then If MYUSER.IsAdmin Then
XtraTabControlMain.TabPages(2).PageVisible = True XtraTabControlMain.TabPages(2).PageVisible = True
XtraTabControlMain.TabPages(3).PageVisible = True
Else Else
XtraTabControlMain.TabPages(2).PageVisible = False XtraTabControlMain.TabPages(2).PageVisible = False
XtraTabControlMain.TabPages(3).PageVisible = False
End If End If
LoadEnvelopeData() LoadEnvelopeData()
End Sub End Sub
@ -222,6 +226,7 @@ Public Class frmMain
bbtnitm_ResendInvitation.Enabled = False bbtnitm_ResendInvitation.Enabled = False
bbtnitmInfoMail.Enabled = False bbtnitmInfoMail.Enabled = False
bbtnitmEB.Enabled = True bbtnitmEB.Enabled = True
bbtnitm2Faktor.Enabled = False
LoadEnvelopeData() LoadEnvelopeData()
Case 0 Case 0
btnEditEnvelope.Enabled = True btnEditEnvelope.Enabled = True
@ -230,6 +235,7 @@ Public Class frmMain
btnShowDocument.Enabled = True btnShowDocument.Enabled = True
bbtnitm_ResendInvitation.Enabled = True bbtnitm_ResendInvitation.Enabled = True
bbtnitmInfoMail.Enabled = True bbtnitmInfoMail.Enabled = True
bbtnitm2Faktor.Enabled = True
bbtnitmEB.Enabled = False bbtnitmEB.Enabled = False
LoadEnvelopeData() LoadEnvelopeData()
@ -767,4 +773,63 @@ Public Class frmMain
GridControlData.DataSource = Nothing GridControlData.DataSource = Nothing
End If End If
End Sub End Sub
Private Sub bbtnitm2Faktor_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles bbtnitm2Faktor.ItemClick
If ViewEnvelopes.FocusedRowHandle < 0 Then
Exit Sub
End If
Dim oEnvelope As Envelope = ViewEnvelopes.GetRow(ViewEnvelopes.FocusedRowHandle)
Dim oView As GridView = GridEnvelopes.FocusedView
If oView.Name = ViewReceivers.Name Then
Dim oReceiver As EnvelopeReceiver = oView.GetRow(oView.FocusedRowHandle)
Dim oEnvelopeTitle As String = Net.WebUtility.UrlEncode(oEnvelope.Title)
Dim oDT As DataTable = DB_DD_ECM.GetDatatable($"SELECT * FROM TBSIG_RECEIVER WHERE EMAIL_ADDRESS = '{oReceiver.Email}'")
If Not IsNothing(oDT) Then
If oDT.Rows.Count = 1 Then
Dim oTFA_REG_DL = oDT.Rows(0).Item("TFA_REG_DEADLINE")
Dim oTOTP = oDT.Rows(0).Item("TOTP_SECRET_KEY")
Dim oForm As New frm2Factor_Properties(oReceiver.Email, oTOTP, oTFA_REG_DL, DB_DD_ECM)
oForm.ShowDialog()
End If
End If
Else
MsgBox(Resources.Envelope.Please_select_a_recipient_from_the_Recipients_tab, MsgBoxStyle.Information, Text)
End If
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
If txtEnvID.Text = String.Empty Then
Exit Sub
End If
Dim EnvelopeModel As EnvelopeModel
Dim oState = GetState()
EnvelopeModel = New EnvelopeModel(oState)
Dim oEnvelope = EnvelopeModel.GetById(txtEnvID.Text)
Dim oMailToCreator = oEnvelope.FinalEmailToCreator
Dim oMailToReceivers = oEnvelope.FinalEmailToReceivers
If oMailToCreator <> FinalEmailType.No Then
MsgBox("Finale email an Creator könnten/würden gesendet werden!")
Else
MsgBox("Finale email an Creator könnte/würde nicht erzeugt werden!" & vbNewLine & $"No SendFinalEmailToCreator - oMailToCreator [{oMailToCreator}] <> [{FinalEmailType.No}]")
End If
If oMailToReceivers <> FinalEmailType.No Then
MsgBox("Finale email an Unterzeichner könnten/würden gesendet werden!")
Else
MsgBox("Finale email an Unterzeichner könnte/würde nicht erzeugt werden!" & vbNewLine & $"No SendFinalEmailToReceivers - oMailToReceivers [{oMailToReceivers}] <> [{FinalEmailType.No}]")
End If
End Sub
Private Function GetState() As State
Return New State With {
.LogConfig = LogConfig,
.UserId = 0,
.Database = DB_DD_ECM,
.Config = Nothing,
.DbConfig = Nothing
}
End Function
End Class End Class

View File

@ -121,7 +121,7 @@
<data name="PictureEdit1.EditValue" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="PictureEdit1.EditValue" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAAyAAAADICAYAAAAQj4UaAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAL iVBORw0KGgoAAAANSUhEUgAAAyAAAADICAYAAAAQj4UaAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAL
DQAACw0B7QfALAAASudJREFUeF7tvWusZNd5nukfcpSOmmre3Wp2s3lrdpNUk01RPxIk6iBBIjFxMBPZ DAAACwwBP0AiyAAASudJREFUeF7tvWusZNd5nukfcpSOmmre3Wp2s3lrdpNUk01RPxIk6iBBIjFxMBPZ
DGxLEyB2M8ggkegAsSRElikHEsnBJFZrRjZtxZIpZaIZRy2AloGxrAHIRKIQRIqVGJ6AsJEAAwgDOzNJ DGxLEyB2M8ggkegAsSRElikHEsnBJFZrRjZtxZIpZaIZRy2AloGxrAHIRKIQRIqVGJ6AsJEAAwgDOzNJ
HCBSLsqfynmq+HV9tepd+1KnLnufen88OKf2rfa67HPed3/rW+t7PnffoxNjjDHGGLNb/n4L/9t9l6b8 HCBSLsqfynmq+HV9tepd+1KnLnufen88OKf2rfa67HPed3/rW+t7PnffoxNjjDHGGLNb/n4L/9t9l6b8
vXsX+ewBn1ngkSkvCH79hy9NXr5yafKbz1yavHr10uRfv/jo5Pe//Ohk8uoMfmcb+ziGYznnc4/q663C vXsX+ewBn1ngkSkvCH79hy9NXr5yafKbz1yavHr10uRfv/jo5Pe//Ohk8uoMfmcb+ziGYznnc4/q663C

View File

@ -260,6 +260,7 @@
<ItemGroup> <ItemGroup>
<Compile Include="Config.vb" /> <Compile Include="Config.vb" />
<Compile Include="LogProvider.vb" /> <Compile Include="LogProvider.vb" />
<Compile Include="Scheduler_Envelopetask_API.vb" />
<Compile Include="Service.Designer.vb"> <Compile Include="Service.Designer.vb">
<DependentUpon>Service.vb</DependentUpon> <DependentUpon>Service.vb</DependentUpon>
</Compile> </Compile>
@ -288,7 +289,7 @@
<DependentUpon>Settings.settings</DependentUpon> <DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput> <DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile> </Compile>
<Compile Include="Scheduler.vb" /> <Compile Include="Scheduler_FinishEnvelope.vb" />
<Compile Include="TempFiles.vb" /> <Compile Include="TempFiles.vb" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>

View File

@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben: ' übernehmen, indem Sie "*" eingeben:
' <Assembly: AssemblyVersion("1.0.*")> ' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("1.8.0.0")> <Assembly: AssemblyVersion("1.9.0.0")>
<Assembly: AssemblyFileVersion("1.8.0.0")> <Assembly: AssemblyFileVersion("1.9.0.0")>

View File

@ -0,0 +1,72 @@
Imports System.Collections.Specialized
Imports DigitalData.Modules.Base
Imports DigitalData.Modules.Database
Imports DigitalData.Modules.Logging
Imports EnvelopeGenerator.Common.Jobs
Imports EnvelopeGenerator.Common.Jobs.FinalizeDocument
Imports Quartz
Public Class Scheduler_Envelopetask_API
Inherits BaseClass
Private Scheduler As IScheduler
Private ReadOnly ConnectionString As String
Private Const JobName = "SendInvitationMailsAPI"
Public Sub New(pLogConfig As LogConfig, pConnectionString As String)
MyBase.New(pLogConfig)
ConnectionString = pConnectionString
Dim oLogProvider = New LogProvider(Logger)
Logging.LogProvider.SetCurrentLogProvider(oLogProvider)
End Sub
Public Async Function Start(pInterval As Integer) As Task
Try
Logger.Debug("Starting Scheduler SendMailsfromAPI..")
Dim oProperties As New NameValueCollection()
Scheduler = Await SchedulerBuilder.Create(oProperties).
UseDefaultThreadPool(Sub(x) x.MaxConcurrency = 5).
BuildScheduler()
Dim oJobKey = New JobKey(JobName)
Dim oJobData = New JobDataMap() From {
{Common.Constants.LOGCONFIG, LogConfig},
{Common.Constants.DATABASE, ConnectionString}
}
Logger.Debug("Initialized Job [{0}]", JobName)
Dim oJob As IJobDetail = JobBuilder.Create(Of APIEnvelopeJob).
UsingJobData(oJobData).
WithIdentity(oJobKey).
Build()
Dim oTrigger As ITrigger = TriggerBuilder.Create().
ForJob(oJobKey).
WithIdentity($"{JobName}-trigger").
WithSimpleSchedule(Sub(s) s.
RepeatForever().
WithIntervalInMinutes(pInterval)).
StartNow().
Build()
Logger.Debug($"{JobName}-trigger initialized")
Await Scheduler.ScheduleJob(oJob, oTrigger)
Logger.Debug($"{JobName}-scheduled")
Await Scheduler.Start()
Logger.Info($"{JobName}-started")
Catch ex As Exception
Logger.Error(ex)
End Try
End Function
Public Async Function [Stop]() As Task
Logger.Info("Stopping scheduler SendMailsfromAPI..")
Await Scheduler.Shutdown()
Logger.Info("Scheduler SendMailsfromAPI stopped!")
End Function
End Class

View File

@ -6,7 +6,7 @@ Imports EnvelopeGenerator.Common.Jobs
Imports EnvelopeGenerator.Common.Jobs.FinalizeDocument Imports EnvelopeGenerator.Common.Jobs.FinalizeDocument
Imports Quartz Imports Quartz
Public Class Scheduler Public Class Scheduler_FinishEnvelope
Inherits BaseClass Inherits BaseClass
Private Scheduler As IScheduler Private Scheduler As IScheduler
@ -28,7 +28,7 @@ Public Class Scheduler
Public Async Function Start(pInterval As Integer) As Task Public Async Function Start(pInterval As Integer) As Task
Try Try
Logger.Debug("Starting Scheduler..") Logger.Debug("Starting Scheduler Finish Envelope..")
Dim oProperties As New NameValueCollection() Dim oProperties As New NameValueCollection()

View File

@ -2,6 +2,7 @@
Imports DigitalData.Modules.Logging Imports DigitalData.Modules.Logging
Imports DigitalData.Modules.Database Imports DigitalData.Modules.Database
Imports DigitalData.Modules.Config Imports DigitalData.Modules.Config
Imports System.Threading
Public Class Service Public Class Service
Private Logger As Logger Private Logger As Logger
@ -10,7 +11,8 @@ Public Class Service
Private Config As Config Private Config As Config
Private Database As MSSQLServer Private Database As MSSQLServer
Private TempFiles As TempFiles Private TempFiles As TempFiles
Private Scheduler As Scheduler Private Scheduler1 As Scheduler_FinishEnvelope
Private Scheduler2 As Scheduler_Envelopetask_API
Protected Overrides Async Sub OnStart(ByVal args() As String) Protected Overrides Async Sub OnStart(ByVal args() As String)
Try Try
@ -53,10 +55,15 @@ Public Class Service
' === Initialize Queue === ' === Initialize Queue ===
Logger.Debug("Inititalize Quartz") Logger.Debug("Inititalizing scheduler(s) ...")
Scheduler = New Scheduler(LogConfig, Config.ConnectionString, oKey, Config.PDFBurnerParams) Scheduler1 = New Scheduler_FinishEnvelope(LogConfig, Config.ConnectionString, oKey, Config.PDFBurnerParams)
Await Scheduler.Start(Config.IntervalInMin) Await Scheduler1.Start(Config.IntervalInMin)
Thread.Sleep(2500)
Scheduler2 = New Scheduler_Envelopetask_API(LogConfig, Config.ConnectionString)
Await Scheduler2.Start(Config.IntervalInMin)
Logger.Info("Started [{0}] !", ServiceName) Logger.Info("Started [{0}] !", ServiceName)
@ -67,8 +74,9 @@ Public Class Service
Protected Overrides Async Sub OnStop() Protected Overrides Async Sub OnStop()
Try Try
Logger.Info("Stopping [{0}] !", ServiceName) Logger.Info("Stopping [{0}] ...", ServiceName)
Await Scheduler.Stop() Await Scheduler1.Stop()
Await Scheduler2.Stop()
TempFiles.CleanUp() TempFiles.CleanUp()
Logger.Info("Stopped [{0}] !", ServiceName) Logger.Info("Stopped [{0}] !", ServiceName)
Catch ex As Exception Catch ex As Exception