Compare commits
224 Commits
customer/C
...
608d79d35b
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
608d79d35b | ||
|
|
62d396932d | ||
|
|
62dcb41526 | ||
|
|
360bb9b3d8 | ||
|
|
1f57914f9e | ||
|
|
9c431ddf56 | ||
|
|
61ff2f8cde | ||
|
|
f2ee509727 | ||
|
|
da06daf776 | ||
|
|
d3104500d4 | ||
|
|
d23b8b9187 | ||
|
|
ec206ab33a | ||
|
|
de6d4b9dd8 | ||
|
|
2943fe0e2d | ||
|
|
33e99f584a | ||
|
|
4a62ab0c56 | ||
|
|
132acd35cc | ||
|
|
ed80839777 | ||
|
|
2114615584 | ||
|
|
6e6f3fd2ed | ||
|
|
5da306acd3 | ||
|
|
18ef1d19b5 | ||
|
|
b76ebd2abc | ||
|
|
d55233061d | ||
|
|
949001791c | ||
|
|
30f93f2439 | ||
|
|
36ffb9511c | ||
|
|
bf84d5c63a | ||
|
|
57f8d0e398 | ||
|
|
bb8bd8ed40 | ||
|
|
ba832acad3 | ||
|
|
6490a3cb82 | ||
|
|
4c077c90db | ||
|
|
9bd5e63128 | ||
|
|
15ce7c9384 | ||
|
|
8707a5cdb5 | ||
|
|
47c7070700 | ||
|
|
fcc3223eb1 | ||
|
|
c4114a3800 | ||
|
|
977486bb7d | ||
|
|
6ccc0d2e0a | ||
|
|
084a9b7db4 | ||
|
|
826844cf46 | ||
|
|
39cff26f2d | ||
|
|
1619801526 | ||
|
|
5a1263ee3a | ||
|
|
bc91baa4fa | ||
|
|
a4882a7bfa | ||
|
|
c254b5b8df | ||
|
|
66718a3fd8 | ||
|
|
99fc2aecd9 | ||
|
|
a41d03aed5 | ||
|
|
6d14b79c43 | ||
|
|
faeac8f290 | ||
|
|
d172faacf3 | ||
|
|
35d6beb3cb | ||
|
|
7ff787ec28 | ||
|
|
f6fc850a20 | ||
|
|
04b8d0ef5d | ||
|
|
891f6368f1 | ||
|
|
e6011b6201 | ||
|
|
8b86114998 | ||
|
|
c20b115faf | ||
|
|
2c8ccd3e7c | ||
|
|
b1f771c320 | ||
|
|
425645a610 | ||
|
|
24e6ffc5ef | ||
|
|
1dd9ce6bbc | ||
|
|
e528fa6409 | ||
|
|
6440dd09d1 | ||
|
|
869493bd97 | ||
|
|
1cb9042736 | ||
|
|
c9410a1e2e | ||
|
|
683ff03a0f | ||
|
|
c9ba7eeaf9 | ||
|
|
c4f0ce7d4b | ||
|
|
dc83486032 | ||
|
|
2a64091c87 | ||
|
|
f65f749208 | ||
|
|
0b6ed00062 | ||
|
|
e87c976e19 | ||
|
|
f31ece3a59 | ||
|
|
cfd08602ab | ||
|
|
4b7152b272 | ||
|
|
5117a66c81 | ||
|
|
83794d4bbc | ||
|
|
76f74778b4 | ||
|
|
ded3425e31 | ||
|
|
738b379fe5 | ||
|
|
cf8b28441f | ||
|
|
0eb5897185 | ||
|
|
25cd1601a6 | ||
|
|
42e4d110ad | ||
|
|
2538f34892 | ||
|
|
3ce11f4cc7 | ||
|
|
f2cd34a79e | ||
|
|
5f923ad485 | ||
|
|
8f70f085d3 | ||
|
|
d6c09ed31a | ||
|
|
7d3ee1331d | ||
|
|
cd5b90a1e2 | ||
|
|
ac861f5fa0 | ||
|
|
c1d8f817bb | ||
|
|
da28a7332b | ||
|
|
bfd4e6a8ed | ||
|
|
b4e0e4b6b2 | ||
|
|
e37caf5c8f | ||
|
|
e95cf24af7 | ||
|
|
524a72caa0 | ||
|
|
1919c562cc | ||
|
|
62b54d6e75 | ||
|
|
efa9160c04 | ||
|
|
bc6955055a | ||
|
|
dc997d5ff2 | ||
|
|
a32f495038 | ||
|
|
210466883c | ||
|
|
728385b70a | ||
|
|
792aa0b922 | ||
|
|
6847b74095 | ||
|
|
54e86b421c | ||
|
|
370666cb0e | ||
|
|
e17f7df930 | ||
|
|
0e91df7acc | ||
|
|
ad26230da5 | ||
|
|
a103f34230 | ||
|
|
806bd3b248 | ||
|
|
c69c39fa44 | ||
|
|
b6badb44af | ||
|
|
b2195ce13f | ||
|
|
f3cb9b8510 | ||
|
|
8edfecb9dc | ||
|
|
c123d103bb | ||
|
|
b92d9da387 | ||
|
|
8841698aab | ||
|
|
6f140f16cd | ||
|
|
8bfd31997b | ||
|
|
4a1459d708 | ||
|
|
361bdeb2b2 | ||
|
|
9ce5af7cd0 | ||
|
|
84fa9e6e7c | ||
|
|
36916ed5c8 | ||
|
|
fb366d3e0b | ||
|
|
6e7670f667 | ||
|
|
e82be8b6a5 | ||
|
|
07320af4ee | ||
|
|
73eb270237 | ||
|
|
222684cfc8 | ||
|
|
3974d2123e | ||
|
|
b837a63b34 | ||
|
|
461316713a | ||
|
|
185af3210b | ||
|
|
e4620b5469 | ||
|
|
5c4acd17a0 | ||
|
|
fc171e5b89 | ||
|
|
662faf2512 | ||
|
|
2fb8af9a4f | ||
|
|
017d03713b | ||
|
|
5f5180d937 | ||
|
|
6b3e6cd6f5 | ||
|
|
f95f3c7b1b | ||
|
|
316b62083c | ||
|
|
530b63f299 | ||
|
|
2f228de163 | ||
|
|
e5e64b25fe | ||
|
|
2d5dde177c | ||
|
|
ce0ad4ba61 | ||
|
|
ebd7c5d6a4 | ||
|
|
341da273c9 | ||
|
|
73d2a43a95 | ||
|
|
eee18889d6 | ||
|
|
590d7fb717 | ||
|
|
dd28ef7ab6 | ||
|
|
36fb033adc | ||
|
|
4275f25f4a | ||
|
|
30b5633498 | ||
|
|
00545fdc50 | ||
|
|
d80e511b08 | ||
|
|
7313355a83 | ||
|
|
66466dc865 | ||
|
|
8cd8df4b02 | ||
|
|
d6bcb8c43d | ||
|
|
2aa2064a67 | ||
|
|
f403d12073 | ||
|
|
b66c2f67da | ||
|
|
d084a4cd81 | ||
|
|
5d2bf56493 | ||
|
|
cd88f5c833 | ||
|
|
ab41e25071 | ||
|
|
eb775da7d4 | ||
|
|
7bc2695da4 | ||
|
|
75fff426bc | ||
|
|
4172df4d78 | ||
|
|
01856b61ef | ||
|
|
2e32559132 | ||
|
|
9adb49df78 | ||
|
|
18e21b0a8e | ||
|
|
e1d7d0e141 | ||
|
|
cfa40e640b | ||
|
|
cb0a45bc17 | ||
|
|
c7b6e5bf24 | ||
|
|
a9ca1b71eb | ||
|
|
97f07bc72d | ||
|
|
8753875d93 | ||
|
|
3692aa80a4 | ||
|
|
b8b09ded5d | ||
|
|
5b8d8b9e55 | ||
|
|
e3fbf4fc77 | ||
|
|
8d680992b7 | ||
|
|
01247f73f4 | ||
|
|
6a7a3dcb90 | ||
|
|
2fbfbb4eb6 | ||
|
|
f88b5d2733 | ||
|
|
363358aaa1 | ||
|
|
7444eeba2a | ||
|
|
e9d686a4c1 | ||
|
|
939ba1bb47 | ||
|
|
d5de868eb9 | ||
|
|
6e3bb6c3a0 | ||
|
|
d347ec420c | ||
|
|
a011b677ea | ||
|
|
8831436809 | ||
|
|
1ededc1f64 | ||
|
|
183c94fd0a | ||
|
|
a0a5568d93 |
@@ -0,0 +1,13 @@
|
|||||||
|
namespace EnvelopeGenerator.Application.Configurations
|
||||||
|
{
|
||||||
|
public class DispatcherConfig
|
||||||
|
{
|
||||||
|
public int SendingProfile { get; init; } = 1;
|
||||||
|
|
||||||
|
public string AddedWho { get; init; } = "DDEnvelopGenerator";
|
||||||
|
|
||||||
|
public int ReminderTypeId { get; init; } = 202377;
|
||||||
|
|
||||||
|
public string EmailAttmt1 { get; init; } = string.Empty;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
using DigitalData.Core.Abstractions.Client;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.Configurations.GtxMessaging
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// https://www.gtx-messaging.com/en/api-docs/sms-rest-api/
|
||||||
|
/// </summary>
|
||||||
|
public class SmsParams : IHttpClientOptions
|
||||||
|
{
|
||||||
|
public required string Uri { get; init; }
|
||||||
|
|
||||||
|
public string? Path { get; init; }
|
||||||
|
|
||||||
|
public Dictionary<string, object>? Headers { get; init; }
|
||||||
|
|
||||||
|
public Dictionary<string, object?>? QueryParams { get; init; }
|
||||||
|
|
||||||
|
public string RecipientQueryParamName { get; init; } = "to";
|
||||||
|
|
||||||
|
public string MessageQueryParamName { get; init; } = "text";
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
namespace EnvelopeGenerator.Application.Configurations
|
||||||
|
{
|
||||||
|
public class MailConfig
|
||||||
|
{
|
||||||
|
public required Dictionary<string, string> Placeholders { get; init; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -5,7 +5,7 @@ using EnvelopeGenerator.Domain.Entities;
|
|||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Contracts
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
{
|
{
|
||||||
public interface IConfigService : IBasicCRUDService<ConfigDto, Config, int>
|
public interface IConfigService : IReadService<ConfigDto, Config, int>
|
||||||
{
|
{
|
||||||
Task<DataResult<ConfigDto>> ReadFirstAsync();
|
Task<DataResult<ConfigDto>> ReadFirstAsync();
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,6 @@ using DigitalData.Core.DTO;
|
|||||||
using EnvelopeGenerator.Application.DTOs.EnvelopeHistory;
|
using EnvelopeGenerator.Application.DTOs.EnvelopeHistory;
|
||||||
using EnvelopeGenerator.Application.DTOs.Receiver;
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
|
||||||
using static EnvelopeGenerator.Common.Constants;
|
using static EnvelopeGenerator.Common.Constants;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Contracts
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
using DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiver;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly;
|
||||||
using EnvelopeGenerator.Common;
|
using EnvelopeGenerator.Common;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Contracts
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
@@ -8,6 +9,9 @@ namespace EnvelopeGenerator.Application.Contracts
|
|||||||
public interface IEnvelopeMailService : IEmailOutService
|
public interface IEnvelopeMailService : IEmailOutService
|
||||||
{
|
{
|
||||||
Task<DataResult<int>> SendAsync(EnvelopeReceiverDto envelopeReceiverDto, Constants.EmailTemplateType tempType);
|
Task<DataResult<int>> SendAsync(EnvelopeReceiverDto envelopeReceiverDto, Constants.EmailTemplateType tempType);
|
||||||
|
|
||||||
|
Task<DataResult<int>> SendAsync(EnvelopeReceiverReadOnlyDto dto);
|
||||||
|
|
||||||
Task<DataResult<int>> SendAccessCodeAsync(EnvelopeReceiverDto envelopeReceiverDto);
|
Task<DataResult<int>> SendAccessCodeAsync(EnvelopeReceiverDto envelopeReceiverDto);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
using DigitalData.Core.Abstractions.Application;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly;
|
||||||
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
|
{
|
||||||
|
public interface IEnvelopeReceiverReadOnlyService : ICRUDService<EnvelopeReceiverReadOnlyCreateDto, EnvelopeReceiverReadOnlyDto, EnvelopeReceiverReadOnlyUpdateDto, EnvelopeReceiverReadOnly, long>
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,15 +1,18 @@
|
|||||||
using DigitalData.Core.Abstractions.Application;
|
using DigitalData.Core.Abstractions.Application;
|
||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiver;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Contracts
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
{
|
{
|
||||||
public interface IEnvelopeReceiverService : IBasicCRUDService<EnvelopeReceiverDto, EnvelopeReceiver, object>
|
public interface IEnvelopeReceiverService : IBasicCRUDService<EnvelopeReceiverDto, EnvelopeReceiver, (int Envelope, int Receiver)>
|
||||||
{
|
{
|
||||||
|
|
||||||
Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUuidAsync(string uuid, bool withEnvelope = true, bool withReceiver = false);
|
Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUuidAsync(string uuid, bool withEnvelope = true, bool withReceiver = false);
|
||||||
|
|
||||||
|
Task<DataResult<IEnumerable<EnvelopeReceiverSecretDto>>> ReadSecretByUuidAsync(string uuid, bool withEnvelope = false, bool withReceiver = true);
|
||||||
|
|
||||||
Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadBySignatureAsync(string signature, bool withEnvelope = false, bool withReceiver = true);
|
Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadBySignatureAsync(string signature, bool withEnvelope = false, bool withReceiver = true);
|
||||||
|
|
||||||
Task<DataResult<EnvelopeReceiverDto>> ReadByUuidSignatureAsync(string uuid, string signature, bool withEnvelope = true, bool withReceiver = true);
|
Task<DataResult<EnvelopeReceiverDto>> ReadByUuidSignatureAsync(string uuid, string signature, bool withEnvelope = true, bool withReceiver = true);
|
||||||
@@ -25,5 +28,7 @@ namespace EnvelopeGenerator.Application.Contracts
|
|||||||
Task<DataResult<bool>> IsExisting(string envelopeReceiverId);
|
Task<DataResult<bool>> IsExisting(string envelopeReceiverId);
|
||||||
|
|
||||||
Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUsernameAsync(string username, int? min_status = null, int? max_status = null, params int[] ignore_statuses);
|
Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUsernameAsync(string username, int? min_status = null, int? max_status = null, params int[] ignore_statuses);
|
||||||
|
|
||||||
|
Task<DataResult<string?>> ReadLastUsedReceiverNameByMail(string mail);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2,7 +2,6 @@
|
|||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Contracts
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
{
|
{
|
||||||
@@ -11,5 +10,7 @@ namespace EnvelopeGenerator.Application.Contracts
|
|||||||
Task<DataResult<IEnumerable<EnvelopeDto>>> ReadAllWithAsync(bool documents = false, bool history = false, bool documentReceiverElement = false);
|
Task<DataResult<IEnumerable<EnvelopeDto>>> ReadAllWithAsync(bool documents = false, bool history = false, bool documentReceiverElement = false);
|
||||||
|
|
||||||
Task<DataResult<EnvelopeDto>> ReadByUuidAsync(string uuid, bool withDocuments = false, bool withHistory = false, bool withDocumentReceiverElement = false, bool withUser = false, bool withAll = false);
|
Task<DataResult<EnvelopeDto>> ReadByUuidAsync(string uuid, bool withDocuments = false, bool withHistory = false, bool withDocumentReceiverElement = false, bool withUser = false, bool withAll = false);
|
||||||
|
|
||||||
|
Task<DataResult<IEnumerable<EnvelopeDto>>> ReadByUserAsync(int userId, int? min_status = null, int? max_status = null, params int[]ignore_statuses);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
|
{
|
||||||
|
public interface IMessagingService
|
||||||
|
{
|
||||||
|
public Task<dynamic?> SendSmsAsync(string recipient, string message);
|
||||||
|
|
||||||
|
public Task<TResponse?> SendSmsAsync<TResponse>(string recipient, string message);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
using DigitalData.Core.Abstractions.Application;
|
using DigitalData.Core.Abstractions.Application;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Contracts
|
namespace EnvelopeGenerator.Application.Contracts
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,57 +1,70 @@
|
|||||||
using DigitalData.UserManager.Application.MappingProfiles;
|
using DigitalData.UserManager.Application.MappingProfiles;
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.MappingProfiles;
|
using EnvelopeGenerator.Application.MappingProfiles;
|
||||||
|
using EnvelopeGenerator.Application.Configurations;
|
||||||
using EnvelopeGenerator.Application.Services;
|
using EnvelopeGenerator.Application.Services;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using EnvelopeGenerator.Infrastructure.Repositories;
|
using EnvelopeGenerator.Infrastructure.Repositories;
|
||||||
|
using Microsoft.Extensions.Configuration;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using System;
|
using Microsoft.Extensions.DependencyInjection.Extensions;
|
||||||
using System.Collections.Generic;
|
using DigitalData.Core.Client;
|
||||||
using System.Linq;
|
using EnvelopeGenerator.Application.Configurations.GtxMessaging;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application
|
namespace EnvelopeGenerator.Application
|
||||||
{
|
{
|
||||||
public static class DIExtensions
|
public static class DIExtensions
|
||||||
{
|
{
|
||||||
public static IServiceCollection AddEnvelopeGenerator(this IServiceCollection services)
|
public static IServiceCollection AddEnvelopeGenerator(this IServiceCollection services, IConfigurationSection dispatcherConfigSection, IConfigurationSection mailConfigSection, IConfigurationSection smsConfigSection)
|
||||||
{
|
{
|
||||||
//Inject CRUD Service and repositoriesad
|
//Inject CRUD Service and repositoriesad
|
||||||
services.AddScoped<IConfigRepository, ConfigRepository>();
|
services.TryAddScoped<IConfigRepository, ConfigRepository>();
|
||||||
services.AddScoped<IDocumentReceiverElementRepository, DocumentReceiverElementRepository>();
|
services.TryAddScoped<IDocumentReceiverElementRepository, DocumentReceiverElementRepository>();
|
||||||
services.AddScoped<IEnvelopeDocumentRepository, EnvelopeDocumentRepository>();
|
services.TryAddScoped<IEnvelopeDocumentRepository, EnvelopeDocumentRepository>();
|
||||||
services.AddScoped<IConfigRepository, ConfigRepository>();
|
services.TryAddScoped<IConfigRepository, ConfigRepository>();
|
||||||
services.AddScoped<IDocumentReceiverElementRepository, DocumentReceiverElementRepository>();
|
services.TryAddScoped<IDocumentReceiverElementRepository, DocumentReceiverElementRepository>();
|
||||||
services.AddScoped<IDocumentStatusRepository, DocumentStatusRepository>();
|
services.TryAddScoped<IDocumentStatusRepository, DocumentStatusRepository>();
|
||||||
services.AddScoped<IEmailTemplateRepository, EmailTemplateRepository>();
|
services.TryAddScoped<IEmailTemplateRepository, EmailTemplateRepository>();
|
||||||
services.AddScoped<IEnvelopeRepository, EnvelopeRepository>();
|
services.TryAddScoped<IEnvelopeRepository, EnvelopeRepository>();
|
||||||
services.AddScoped<IEnvelopeCertificateRepository, EnvelopeCertificateRepository>();
|
services.TryAddScoped<IEnvelopeCertificateRepository, EnvelopeCertificateRepository>();
|
||||||
services.AddScoped<IEnvelopeDocumentRepository, EnvelopeDocumentRepository>();
|
services.TryAddScoped<IEnvelopeDocumentRepository, EnvelopeDocumentRepository>();
|
||||||
services.AddScoped<IEnvelopeHistoryRepository, EnvelopeHistoryRepository>();
|
services.TryAddScoped<IEnvelopeHistoryRepository, EnvelopeHistoryRepository>();
|
||||||
services.AddScoped<IEnvelopeReceiverRepository, EnvelopeReceiverRepository>();
|
services.TryAddScoped<IEnvelopeReceiverRepository, EnvelopeReceiverRepository>();
|
||||||
services.AddScoped<IEnvelopeTypeRepository, EnvelopeTypeRepository>();
|
services.TryAddScoped<IEnvelopeTypeRepository, EnvelopeTypeRepository>();
|
||||||
services.AddScoped<IReceiverRepository, ReceiverRepository>();
|
services.TryAddScoped<IReceiverRepository, ReceiverRepository>();
|
||||||
services.AddScoped<IUserReceiverRepository, UserReceiverRepository>();
|
services.TryAddScoped<IUserReceiverRepository, UserReceiverRepository>();
|
||||||
services.AddScoped<IConfigService, ConfigService>();
|
services.TryAddScoped<IEnvelopeReceiverReadOnlyRepository, EnvelopeReceiverReadOnlyRepository>();
|
||||||
services.AddScoped<IDocumentReceiverElementService, DocumentReceiverElementService>();
|
services.TryAddScoped<IConfigService, ConfigService>();
|
||||||
services.AddScoped<IEnvelopeDocumentService, EnvelopeDocumentService>();
|
services.TryAddScoped<IDocumentReceiverElementService, DocumentReceiverElementService>();
|
||||||
services.AddScoped<IEnvelopeHistoryService, EnvelopeHistoryService>();
|
services.TryAddScoped<IEnvelopeDocumentService, EnvelopeDocumentService>();
|
||||||
services.AddScoped<IDocumentStatusService, DocumentStatusService>();
|
services.TryAddScoped<IEnvelopeHistoryService, EnvelopeHistoryService>();
|
||||||
services.AddScoped<IEmailTemplateService, EmailTemplateService>();
|
services.TryAddScoped<IDocumentStatusService, DocumentStatusService>();
|
||||||
services.AddScoped<IEnvelopeService, EnvelopeService>();
|
services.TryAddScoped<IEmailTemplateService, EmailTemplateService>();
|
||||||
services.AddScoped<IEnvelopeCertificateService, EnvelopeCertificateService>();
|
services.TryAddScoped<IEnvelopeService, EnvelopeService>();
|
||||||
services.AddScoped<IEnvelopeDocumentService, EnvelopeDocumentService>();
|
services.TryAddScoped<IEnvelopeCertificateService, EnvelopeCertificateService>();
|
||||||
services.AddScoped<IEnvelopeReceiverService, EnvelopeReceiverService>();
|
services.TryAddScoped<IEnvelopeDocumentService, EnvelopeDocumentService>();
|
||||||
services.AddScoped<IEnvelopeTypeService, EnvelopeTypeService>();
|
services.TryAddScoped<IEnvelopeReceiverService, EnvelopeReceiverService>();
|
||||||
services.AddScoped<IReceiverService, ReceiverService>();
|
services.TryAddScoped<IEnvelopeTypeService, EnvelopeTypeService>();
|
||||||
services.AddScoped<IUserReceiverService, UserReceiverService>();
|
services.TryAddScoped<IReceiverService, ReceiverService>();
|
||||||
|
services.TryAddScoped<IUserReceiverService, UserReceiverService>();
|
||||||
|
services.TryAddScoped<IEnvelopeReceiverReadOnlyService, EnvelopeReceiverReadOnlyService>();
|
||||||
|
|
||||||
//Auto mapping profiles
|
//Auto mapping profiles
|
||||||
services.AddAutoMapper(typeof(BasicDtoMappingProfile).Assembly);
|
services.AddAutoMapper(typeof(BasicDtoMappingProfile).Assembly);
|
||||||
services.AddAutoMapper(typeof(UserMappingProfile).Assembly);
|
services.AddAutoMapper(typeof(UserMappingProfile).Assembly);
|
||||||
|
|
||||||
|
services.Configure<DispatcherConfig>(dispatcherConfigSection);
|
||||||
|
services.Configure<MailConfig>(mailConfigSection);
|
||||||
|
|
||||||
|
services.AddHttpClientService<SmsParams>(smsConfigSection);
|
||||||
|
services.TryAddSingleton<IMessagingService, GtxMessagingService>();
|
||||||
|
|
||||||
return services;
|
return services;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static IServiceCollection AddEnvelopeGenerator(this IServiceCollection services, IConfiguration config) => services.AddEnvelopeGenerator(
|
||||||
|
dispatcherConfigSection: config.GetSection("DispatcherConfig"),
|
||||||
|
mailConfigSection: config.GetSection("MailConfig"),
|
||||||
|
smsConfigSection: config.GetSection("SmsConfig"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,12 +1,19 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
using System.Text.Json.Serialization;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record ConfigDto(
|
public record ConfigDto(
|
||||||
string DocumentPath,
|
string DocumentPath,
|
||||||
int SendingProfile,
|
int SendingProfile,
|
||||||
string SignatureHost,
|
string SignatureHost,
|
||||||
string ExternalProgramName,
|
string ExternalProgramName,
|
||||||
string ExportPath,
|
string ExportPath) : IUnique<int>
|
||||||
string DocumentPathDmz,
|
{
|
||||||
string ExportPathDmz,
|
[NotMapped]
|
||||||
string DocumentPathMoveAftsend);
|
[JsonIgnore]
|
||||||
|
[Obsolete("Configuration does not have an ID; it represents a single table in the database.")]
|
||||||
|
public int Id => throw new InvalidOperationException("This configuration does not support an ID as it represents a single row in the database.");
|
||||||
|
};
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record DocumentReceiverElementDto(
|
public record DocumentReceiverElementDto(
|
||||||
int Id,
|
int Id,
|
||||||
@@ -18,5 +20,5 @@
|
|||||||
DateTime? ChangedWhen,
|
DateTime? ChangedWhen,
|
||||||
double Top,
|
double Top,
|
||||||
double Left
|
double Left
|
||||||
);
|
): IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record DocumentStatusDto(
|
public record DocumentStatusDto(
|
||||||
int Id,
|
int Id,
|
||||||
@@ -8,5 +10,5 @@
|
|||||||
DateTime? StatusChangedWhen,
|
DateTime? StatusChangedWhen,
|
||||||
string Value,
|
string Value,
|
||||||
DateTime AddedWhen,
|
DateTime AddedWhen,
|
||||||
DateTime? ChangedWhen);
|
DateTime? ChangedWhen) : IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,8 +1,10 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record EmailTemplateDto(
|
public record EmailTemplateDto(
|
||||||
int Id,
|
int Id,
|
||||||
string Name,
|
string Name,
|
||||||
string Body,
|
string Body,
|
||||||
string Subject);
|
string Subject) : IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record EnvelopeCertificateDto(
|
public record EnvelopeCertificateDto(
|
||||||
int Id,
|
int Id,
|
||||||
@@ -8,5 +10,5 @@
|
|||||||
int CreatorId,
|
int CreatorId,
|
||||||
string CreatorName,
|
string CreatorName,
|
||||||
string CreatorEmail,
|
string CreatorEmail,
|
||||||
int EnvelopeStatus);
|
int EnvelopeStatus) : IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,10 +1,13 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record EnvelopeDocumentDto
|
public record EnvelopeDocumentDto
|
||||||
(
|
(
|
||||||
int Id,
|
int Id,
|
||||||
int EnvelopeId,
|
int EnvelopeId,
|
||||||
DateTime AddedWhen,
|
DateTime AddedWhen,
|
||||||
IEnumerable<DocumentReceiverElementDto>? Elements
|
byte[]? ByteData = null,
|
||||||
);
|
IEnumerable<DocumentReceiverElementDto>? Elements = null
|
||||||
|
) : IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,10 +1,11 @@
|
|||||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Attributes;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using DigitalData.EmailProfilerDispatcher.Abstraction.Attributes;
|
||||||
using DigitalData.UserManager.Application.DTOs.User;
|
using DigitalData.UserManager.Application.DTOs.User;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.DTOs
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record EnvelopeDto()
|
public record EnvelopeDto() : IUnique<int>
|
||||||
{
|
{
|
||||||
public int Id { get; set; }
|
public int Id { get; set; }
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using DigitalData.Core.DTO;
|
||||||
using DigitalData.UserManager.Application.DTOs.User;
|
using DigitalData.UserManager.Application.DTOs.User;
|
||||||
using EnvelopeGenerator.Application.DTOs.Receiver;
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
using static EnvelopeGenerator.Common.Constants;
|
using static EnvelopeGenerator.Common.Constants;
|
||||||
@@ -10,10 +11,11 @@ namespace EnvelopeGenerator.Application.DTOs.EnvelopeHistory
|
|||||||
int EnvelopeId,
|
int EnvelopeId,
|
||||||
string UserReference,
|
string UserReference,
|
||||||
int Status,
|
int Status,
|
||||||
|
string? StatusName,
|
||||||
DateTime AddedWhen,
|
DateTime AddedWhen,
|
||||||
DateTime? ActionDate,
|
DateTime? ActionDate,
|
||||||
UserCreateDto? Sender,
|
UserCreateDto? Sender,
|
||||||
ReceiverReadDto? Receiver,
|
ReceiverReadDto? Receiver,
|
||||||
ReferenceType ReferenceType,
|
ReferenceType ReferenceType,
|
||||||
string? Comment = null) : BaseDTO<long>(Id);
|
string? Comment = null) : BaseDTO<long>(Id), IUnique<long>;
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
using DigitalData.Core.Abstractions;
|
||||||
|
using DigitalData.EmailProfilerDispatcher.Abstraction.Attributes;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs.EnvelopeReceiver
|
||||||
|
{
|
||||||
|
public record EnvelopeReceiverBasicDto() : IUnique<(int Envelope, int Receiver)>
|
||||||
|
{
|
||||||
|
public (int Envelope, int Receiver) Id => (Envelope: EnvelopeId, Receiver: ReceiverId);
|
||||||
|
|
||||||
|
public int EnvelopeId { get; init; }
|
||||||
|
|
||||||
|
public int ReceiverId { get; init; }
|
||||||
|
|
||||||
|
public int Sequence { get; init; }
|
||||||
|
|
||||||
|
[TemplatePlaceholder("[NAME_RECEIVER]")]
|
||||||
|
public string? Name { get; init; }
|
||||||
|
|
||||||
|
public string? JobTitle { get; init; }
|
||||||
|
|
||||||
|
public string? CompanyName { get; init; }
|
||||||
|
|
||||||
|
public string? PrivateMessage { get; init; }
|
||||||
|
|
||||||
|
public DateTime AddedWhen { get; init; }
|
||||||
|
|
||||||
|
public DateTime? ChangedWhen { get; init; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs.EnvelopeReceiver
|
||||||
|
{
|
||||||
|
public record EnvelopeReceiverDto() : EnvelopeReceiverBasicDto()
|
||||||
|
{
|
||||||
|
public EnvelopeDto? Envelope { get; set; }
|
||||||
|
|
||||||
|
public ReceiverReadDto? Receiver { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
namespace EnvelopeGenerator.Application.DTOs.EnvelopeReceiver
|
||||||
|
{
|
||||||
|
public record EnvelopeReceiverSecretDto(string? AccessCode) : EnvelopeReceiverDto;
|
||||||
|
}
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Attributes;
|
|
||||||
using EnvelopeGenerator.Application.DTOs.Receiver;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.DTOs
|
|
||||||
{
|
|
||||||
public record EnvelopeReceiverDto()
|
|
||||||
{
|
|
||||||
public int EnvelopeId { get; set; }
|
|
||||||
|
|
||||||
public int ReceiverId { get; set; }
|
|
||||||
|
|
||||||
public int Sequence { get; set; }
|
|
||||||
|
|
||||||
[TemplatePlaceholder("[NAME_RECEIVER]")]
|
|
||||||
public string? Name { get; set; }
|
|
||||||
|
|
||||||
public string? JobTitle { get; set; }
|
|
||||||
|
|
||||||
public string? CompanyName { get; set; }
|
|
||||||
|
|
||||||
public string? PrivateMessage { get; set; }
|
|
||||||
|
|
||||||
public DateTime AddedWhen { get; set; }
|
|
||||||
|
|
||||||
public DateTime? ChangedWhen { get; set; }
|
|
||||||
|
|
||||||
public EnvelopeDto? Envelope { get; set; }
|
|
||||||
|
|
||||||
public ReceiverReadDto? Receiver { get; set; }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.Text.Json.Serialization;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly
|
||||||
|
{
|
||||||
|
public record EnvelopeReceiverReadOnlyCreateDto(
|
||||||
|
DateTime DateValid)
|
||||||
|
{
|
||||||
|
[EmailAddress]
|
||||||
|
[Required]
|
||||||
|
public required string ReceiverMail { get; init; }
|
||||||
|
|
||||||
|
[JsonIgnore]
|
||||||
|
public long? EnvelopeId { get; set; } = null;
|
||||||
|
|
||||||
|
[JsonIgnore]
|
||||||
|
public string? AddedWho { get; set; }
|
||||||
|
|
||||||
|
[JsonIgnore]
|
||||||
|
public DateTime AddedWhen { get; } = DateTime.Now;
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly
|
||||||
|
{
|
||||||
|
public record EnvelopeReceiverReadOnlyDto(
|
||||||
|
long Id,
|
||||||
|
long EnvelopeId,
|
||||||
|
string ReceiverMail,
|
||||||
|
DateTime DateValid,
|
||||||
|
DateTime AddedWhen,
|
||||||
|
string AddedWho,
|
||||||
|
EnvelopeDto? Envelope = null,
|
||||||
|
string? ChangedWho = null,
|
||||||
|
DateTime? ChangedWhen = null,
|
||||||
|
ReceiverReadDto? Receiver = null);
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly
|
||||||
|
{
|
||||||
|
public record EnvelopeReceiverReadOnlyUpdateDto(
|
||||||
|
long Id,
|
||||||
|
DateTime DateValid,
|
||||||
|
string ChangedWho) : IUnique<long>
|
||||||
|
{
|
||||||
|
public DateTime ChangedWhen { get; } = DateTime.Now;
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record EnvelopeTypeDto(
|
public record EnvelopeTypeDto(
|
||||||
int Id,
|
int Id,
|
||||||
@@ -15,5 +17,5 @@
|
|||||||
bool? SendReminderEmails,
|
bool? SendReminderEmails,
|
||||||
int? FirstReminderDays,
|
int? FirstReminderDays,
|
||||||
int? ReminderIntervalDays,
|
int? ReminderIntervalDays,
|
||||||
int? ContractType);
|
int? ContractType) : IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiver;
|
||||||
|
using System.Text.Json.Serialization;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.DTOs.Receiver
|
namespace EnvelopeGenerator.Application.DTOs.Receiver
|
||||||
{
|
{
|
||||||
@@ -6,6 +8,12 @@ namespace EnvelopeGenerator.Application.DTOs.Receiver
|
|||||||
int Id,
|
int Id,
|
||||||
string EmailAddress,
|
string EmailAddress,
|
||||||
string Signature,
|
string Signature,
|
||||||
DateTime AddedWhen
|
DateTime AddedWhen
|
||||||
) : BaseDTO<int>(Id);
|
) : BaseDTO<int>(Id)
|
||||||
|
{
|
||||||
|
[JsonIgnore]
|
||||||
|
public IEnumerable<EnvelopeReceiverBasicDto>? EnvelopeReceivers { get; init; }
|
||||||
|
|
||||||
|
public string? LastUsedName => EnvelopeReceivers?.LastOrDefault()?.Name;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs.Receiver
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs.Receiver
|
||||||
{
|
{
|
||||||
public record ReceiverUpdateDto();
|
public record ReceiverUpdateDto(int Id) : IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
namespace EnvelopeGenerator.Application.DTOs
|
using DigitalData.Core.Abstractions;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.DTOs
|
||||||
{
|
{
|
||||||
public record UserReceiverDto(
|
public record UserReceiverDto(
|
||||||
int Id,
|
int Id,
|
||||||
@@ -7,5 +9,5 @@
|
|||||||
string Name,
|
string Name,
|
||||||
string CompanyName,
|
string CompanyName,
|
||||||
string JobTitle,
|
string JobTitle,
|
||||||
DateTime AddedWhen);
|
DateTime AddedWhen) : IUnique<int>;
|
||||||
}
|
}
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
namespace EnvelopeGenerator.Application
|
|
||||||
{
|
|
||||||
public class DispatcherConfig
|
|
||||||
{
|
|
||||||
public int SendingProfile { get; init; } = 1;
|
|
||||||
|
|
||||||
public string AddedWho { get; init; } = "DDEnvelopGenerator";
|
|
||||||
|
|
||||||
public int ReminderTypeId { get; init; } = 202377;
|
|
||||||
|
|
||||||
public string EmailAttmt1 { get; init; } = string.Empty;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -12,16 +12,18 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="AutoMapper" Version="13.0.1" />
|
<PackageReference Include="AutoMapper" Version="13.0.1" />
|
||||||
<PackageReference Include="DigitalData.Core.Abstractions" Version="1.0.1.1" />
|
<PackageReference Include="DigitalData.Core.Abstractions" Version="2.2.1" />
|
||||||
<PackageReference Include="DigitalData.Core.Application" Version="1.0.0" />
|
<PackageReference Include="DigitalData.Core.Application" Version="2.0.0" />
|
||||||
<PackageReference Include="DigitalData.Core.DTO" Version="1.0.0" />
|
<PackageReference Include="DigitalData.Core.Client" Version="2.0.2" />
|
||||||
<PackageReference Include="DigitalData.EmailProfilerDispatcher" Version="1.0.0" />
|
<PackageReference Include="DigitalData.Core.DTO" Version="2.0.0" />
|
||||||
|
<PackageReference Include="DigitalData.EmailProfilerDispatcher" Version="2.0.0" />
|
||||||
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="7.0.18" />
|
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="7.0.18" />
|
||||||
<PackageReference Include="UserManager.Application" Version="1.0.0" />
|
<PackageReference Include="UserManager.Application" Version="2.0.0" />
|
||||||
<PackageReference Include="UserManager.Infrastructure" Version="1.0.0" />
|
<PackageReference Include="UserManager.Infrastructure" Version="2.0.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\EnvelopeGenerator.Extensions\EnvelopeGenerator.Extensions.csproj" />
|
||||||
<ProjectReference Include="..\EnvelopeGenerator.Infrastructure\EnvelopeGenerator.Infrastructure.csproj" />
|
<ProjectReference Include="..\EnvelopeGenerator.Infrastructure\EnvelopeGenerator.Infrastructure.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
using AutoMapper;
|
using AutoMapper;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Application.DTOs.EnvelopeHistory;
|
using EnvelopeGenerator.Application.DTOs.EnvelopeHistory;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiver;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly;
|
||||||
using EnvelopeGenerator.Application.DTOs.Receiver;
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
|
|
||||||
@@ -21,11 +23,13 @@ namespace EnvelopeGenerator.Application.MappingProfiles
|
|||||||
CreateMap<EnvelopeHistory, EnvelopeHistoryDto>();
|
CreateMap<EnvelopeHistory, EnvelopeHistoryDto>();
|
||||||
CreateMap<EnvelopeHistory, EnvelopeHistoryCreateDto>();
|
CreateMap<EnvelopeHistory, EnvelopeHistoryCreateDto>();
|
||||||
CreateMap<EnvelopeReceiver, EnvelopeReceiverDto>();
|
CreateMap<EnvelopeReceiver, EnvelopeReceiverDto>();
|
||||||
|
CreateMap<EnvelopeReceiver, EnvelopeReceiverSecretDto>();
|
||||||
CreateMap<EnvelopeType, EnvelopeTypeDto>();
|
CreateMap<EnvelopeType, EnvelopeTypeDto>();
|
||||||
CreateMap<Receiver, ReceiverReadDto>();
|
CreateMap<Receiver, ReceiverReadDto>();
|
||||||
CreateMap<Receiver, ReceiverCreateDto>();
|
CreateMap<Receiver, ReceiverCreateDto>();
|
||||||
CreateMap<Receiver, ReceiverUpdateDto>();
|
CreateMap<Receiver, ReceiverUpdateDto>();
|
||||||
CreateMap<UserReceiver, UserReceiverDto>();
|
CreateMap<UserReceiver, UserReceiverDto>();
|
||||||
|
CreateMap<EnvelopeReceiverReadOnly, EnvelopeReceiverReadOnlyDto>();
|
||||||
|
|
||||||
// DTO to Entity mappings
|
// DTO to Entity mappings
|
||||||
CreateMap<ConfigDto, Config>();
|
CreateMap<ConfigDto, Config>();
|
||||||
@@ -43,6 +47,9 @@ namespace EnvelopeGenerator.Application.MappingProfiles
|
|||||||
CreateMap<ReceiverCreateDto, Receiver>();
|
CreateMap<ReceiverCreateDto, Receiver>();
|
||||||
CreateMap<ReceiverUpdateDto, Receiver>();
|
CreateMap<ReceiverUpdateDto, Receiver>();
|
||||||
CreateMap<UserReceiverDto, UserReceiver>();
|
CreateMap<UserReceiverDto, UserReceiver>();
|
||||||
|
CreateMap<EnvelopeReceiverBase, EnvelopeReceiverBasicDto>();
|
||||||
|
CreateMap<EnvelopeReceiverReadOnlyCreateDto, EnvelopeReceiverReadOnly>();
|
||||||
|
CreateMap<EnvelopeReceiverReadOnlyUpdateDto, EnvelopeReceiverReadOnly>();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -156,6 +156,9 @@
|
|||||||
<data name="Hello" xml:space="preserve">
|
<data name="Hello" xml:space="preserve">
|
||||||
<value>Hallo</value>
|
<value>Hallo</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="HomePageDescription" xml:space="preserve">
|
||||||
|
<value>Das digitale Unterschriftenportal ist eine Plattform, die entwickelt wurde, um Ihre Dokumente sicher zu unterschreiben und zu verwalten. Mit seiner benutzerfreundlichen Oberfläche können Sie Ihre Dokumente schnell hochladen, die Unterschriftsprozesse verfolgen und Ihre digitalen Unterschriftenanwendungen einfach durchführen. Dieses Portal beschleunigt Ihren Arbeitsablauf mit rechtlich gültigen Unterschriften und erhöht gleichzeitig die Sicherheit Ihrer Dokumente.</value>
|
||||||
|
</data>
|
||||||
<data name="LocakedOpen" xml:space="preserve">
|
<data name="LocakedOpen" xml:space="preserve">
|
||||||
<value>Öffnen</value>
|
<value>Öffnen</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -177,6 +180,12 @@
|
|||||||
<data name="LockedTitle" xml:space="preserve">
|
<data name="LockedTitle" xml:space="preserve">
|
||||||
<value>Dokument erfordert einen Zugriffscode</value>
|
<value>Dokument erfordert einen Zugriffscode</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Privacy" xml:space="preserve">
|
||||||
|
<value>Datenschutz</value>
|
||||||
|
</data>
|
||||||
|
<data name="ReadOnlyMessage" xml:space="preserve">
|
||||||
|
<value>Weitergeleitet von {0}. Gültig bis {1}.</value>
|
||||||
|
</data>
|
||||||
<data name="Reject" xml:space="preserve">
|
<data name="Reject" xml:space="preserve">
|
||||||
<value>Ablehnen</value>
|
<value>Ablehnen</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -210,6 +219,9 @@
|
|||||||
<data name="UnexpectedError" xml:space="preserve">
|
<data name="UnexpectedError" xml:space="preserve">
|
||||||
<value>Ein unerwarteter Fehler ist aufgetreten.</value>
|
<value>Ein unerwarteter Fehler ist aufgetreten.</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="ViewDoc" xml:space="preserve">
|
||||||
|
<value>Dokument ansehen</value>
|
||||||
|
</data>
|
||||||
<data name="WelcomeToTheESignPortal" xml:space="preserve">
|
<data name="WelcomeToTheESignPortal" xml:space="preserve">
|
||||||
<value>Herzlich willkommen im eSign-Portal</value>
|
<value>Herzlich willkommen im eSign-Portal</value>
|
||||||
</data>
|
</data>
|
||||||
|
|||||||
@@ -156,6 +156,9 @@
|
|||||||
<data name="Hello" xml:space="preserve">
|
<data name="Hello" xml:space="preserve">
|
||||||
<value>Hello</value>
|
<value>Hello</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="HomePageDescription" xml:space="preserve">
|
||||||
|
<value>The Digital Signature Portal is a platform developed for securely signing and managing your documents. With its user-friendly interface, you can quickly upload your documents, track the signing processes, and easily carry out your digital signature applications. This portal accelerates your workflow with legally valid signatures while enhancing the security of your documents.</value>
|
||||||
|
</data>
|
||||||
<data name="LocakedOpen" xml:space="preserve">
|
<data name="LocakedOpen" xml:space="preserve">
|
||||||
<value>Open</value>
|
<value>Open</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -177,6 +180,12 @@
|
|||||||
<data name="LockedTitle" xml:space="preserve">
|
<data name="LockedTitle" xml:space="preserve">
|
||||||
<value>Document requires an access code</value>
|
<value>Document requires an access code</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Privacy" xml:space="preserve">
|
||||||
|
<value>Privacy</value>
|
||||||
|
</data>
|
||||||
|
<data name="ReadOnlyMessage" xml:space="preserve">
|
||||||
|
<value>Forwarded by {0}. Valid until {1}.</value>
|
||||||
|
</data>
|
||||||
<data name="Reject" xml:space="preserve">
|
<data name="Reject" xml:space="preserve">
|
||||||
<value>Reject</value>
|
<value>Reject</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -210,6 +219,9 @@
|
|||||||
<data name="UnexpectedError" xml:space="preserve">
|
<data name="UnexpectedError" xml:space="preserve">
|
||||||
<value>An unexpected error has occurred.</value>
|
<value>An unexpected error has occurred.</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="ViewDoc" xml:space="preserve">
|
||||||
|
<value>View document</value>
|
||||||
|
</data>
|
||||||
<data name="WelcomeToTheESignPortal" xml:space="preserve">
|
<data name="WelcomeToTheESignPortal" xml:space="preserve">
|
||||||
<value>Welcome to the eSign portal</value>
|
<value>Welcome to the eSign portal</value>
|
||||||
</data>
|
</data>
|
||||||
|
|||||||
@@ -3,15 +3,13 @@ using DigitalData.Core.Application;
|
|||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using Microsoft.Extensions.Caching.Memory;
|
using Microsoft.Extensions.Caching.Memory;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
public class ConfigService : BasicCRUDService<IConfigRepository, ConfigDto, Config, int>, IConfigService
|
public class ConfigService : ReadService<IConfigRepository, ConfigDto, Config, int>, IConfigService
|
||||||
{
|
{
|
||||||
private static readonly Guid DefaultConfigCacheId = Guid.NewGuid();
|
private static readonly Guid DefaultConfigCacheId = Guid.NewGuid();
|
||||||
|
|
||||||
@@ -28,7 +26,7 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
var config = await _repository.ReadFirstAsync();
|
var config = await _repository.ReadFirstAsync();
|
||||||
return config is null
|
return config is null
|
||||||
? Result.Fail<ConfigDto>().Notice(LogLevel.Error, Flag.DataIntegrityIssue, "There is no configuration in DB.")
|
? Result.Fail<ConfigDto>().Notice(LogLevel.Error, Flag.DataIntegrityIssue, "There is no configuration in DB.")
|
||||||
: Result.Success(_mapper.MapOrThrow<ConfigDto>(config));
|
: Result.Success(_mapper.Map<ConfigDto>(config));
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -2,10 +2,8 @@
|
|||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -2,10 +2,8 @@
|
|||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,11 +1,9 @@
|
|||||||
using AutoMapper;
|
using AutoMapper;
|
||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
using static EnvelopeGenerator.Common.Constants;
|
using static EnvelopeGenerator.Common.Constants;
|
||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
@@ -26,7 +24,7 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
? Result.Fail<EmailTemplateDto>()
|
? Result.Fail<EmailTemplateDto>()
|
||||||
.Message(Key.InnerServiceError)
|
.Message(Key.InnerServiceError)
|
||||||
.Notice(LogLevel.Error, Flag.DataIntegrityIssue, $"EmailTemplateType '{type}' is not found in DB. Please, define required e-mail template.")
|
.Notice(LogLevel.Error, Flag.DataIntegrityIssue, $"EmailTemplateType '{type}' is not found in DB. Please, define required e-mail template.")
|
||||||
: Result.Success(_mapper.MapOrThrow<EmailTemplateDto>(temp));
|
: Result.Success(_mapper.Map<EmailTemplateDto>(temp));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,11 +1,9 @@
|
|||||||
using AutoMapper;
|
using AutoMapper;
|
||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using static EnvelopeGenerator.Common.Constants;
|
using static EnvelopeGenerator.Common.Constants;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using EnvelopeGenerator.Application.DTOs.EnvelopeHistory;
|
using EnvelopeGenerator.Application.DTOs.EnvelopeHistory;
|
||||||
using EnvelopeGenerator.Application.DTOs.Receiver;
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
@@ -14,7 +12,7 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
{
|
{
|
||||||
public class EnvelopeHistoryService : CRUDService<IEnvelopeHistoryRepository, EnvelopeHistoryCreateDto, EnvelopeHistoryDto, EnvelopeHistoryDto, EnvelopeHistory, long>, IEnvelopeHistoryService
|
public class EnvelopeHistoryService : CRUDService<IEnvelopeHistoryRepository, EnvelopeHistoryCreateDto, EnvelopeHistoryDto, EnvelopeHistoryDto, EnvelopeHistory, long>, IEnvelopeHistoryService
|
||||||
{
|
{
|
||||||
public EnvelopeHistoryService(IEnvelopeHistoryRepository repository, IStringLocalizer<Resource> localizer, IMapper mapper)
|
public EnvelopeHistoryService(IEnvelopeHistoryRepository repository, IMapper mapper)
|
||||||
: base(repository, mapper)
|
: base(repository, mapper)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -53,7 +51,7 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
|
|
||||||
public async Task<IEnumerable<EnvelopeHistoryDto>> ReadAsync(int? envelopeId = null, string? userReference = null, ReferenceType? referenceType = null, int? status = null, bool withSender = false, bool withReceiver = false)
|
public async Task<IEnumerable<EnvelopeHistoryDto>> ReadAsync(int? envelopeId = null, string? userReference = null, ReferenceType? referenceType = null, int? status = null, bool withSender = false, bool withReceiver = false)
|
||||||
{
|
{
|
||||||
var histDTOs = _mapper.MapOrThrow<IEnumerable<EnvelopeHistoryDto>>(
|
var histDTOs = _mapper.Map<IEnumerable<EnvelopeHistoryDto>>(
|
||||||
await _repository.ReadAsync(
|
await _repository.ReadAsync(
|
||||||
envelopeId: envelopeId,
|
envelopeId: envelopeId,
|
||||||
userReference: userReference,
|
userReference: userReference,
|
||||||
|
|||||||
@@ -3,56 +3,68 @@ using DigitalData.Core.DTO;
|
|||||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
using DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
||||||
using DigitalData.EmailProfilerDispatcher.Abstraction.DTOs.EmailOut;
|
using DigitalData.EmailProfilerDispatcher.Abstraction.DTOs.EmailOut;
|
||||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Services;
|
using DigitalData.EmailProfilerDispatcher.Abstraction.Services;
|
||||||
using DigitalData.UserManager.Application;
|
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiver;
|
||||||
using EnvelopeGenerator.Common;
|
using EnvelopeGenerator.Common;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
using Microsoft.Extensions.Options;
|
using Microsoft.Extensions.Options;
|
||||||
using static EnvelopeGenerator.Common.Constants;
|
using static EnvelopeGenerator.Common.Constants;
|
||||||
|
using EnvelopeGenerator.Extensions;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly;
|
||||||
|
using EnvelopeGenerator.Application.Configurations;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
public class EnvelopeMailService : EmailOutService, IEnvelopeMailService
|
public class EnvelopeMailService : EmailOutService, IEnvelopeMailService
|
||||||
{
|
{
|
||||||
private readonly IEmailTemplateService _tempService;
|
private readonly IEmailTemplateService _tempService;
|
||||||
private readonly IEnvelopeReceiverService _envRcvService;
|
private readonly IEnvelopeReceiverService _envRcvService;
|
||||||
private readonly DispatcherConfig _dConfig;
|
private readonly DispatcherConfig _dConfig;
|
||||||
private readonly IConfigService _configService;
|
private readonly IConfigService _configService;
|
||||||
|
private readonly Dictionary<string, string> _placeholders;
|
||||||
|
|
||||||
public EnvelopeMailService(IEmailOutRepository repository, IStringLocalizer<Resource> localizer, IMapper mapper, IEmailTemplateService tempService, IEnvelopeReceiverService envelopeReceiverService, IOptions<DispatcherConfig> dispatcherConfigOptions, IConfigService configService) : base(repository, mapper)
|
public EnvelopeMailService(IEmailOutRepository repository, IMapper mapper, IEmailTemplateService tempService, IEnvelopeReceiverService envelopeReceiverService, IOptions<DispatcherConfig> dispatcherConfigOptions, IConfigService configService, IOptions<MailConfig> mailConfig) : base(repository, mapper)
|
||||||
{
|
{
|
||||||
_tempService = tempService;
|
_tempService = tempService;
|
||||||
_envRcvService = envelopeReceiverService;
|
_envRcvService = envelopeReceiverService;
|
||||||
_dConfig = dispatcherConfigOptions.Value;
|
_dConfig = dispatcherConfigOptions.Value;
|
||||||
_configService = configService;
|
_configService = configService;
|
||||||
|
_placeholders = mailConfig.Value.Placeholders;
|
||||||
}
|
}
|
||||||
|
|
||||||
//TODO: create ioptions and implement TemplatePlaceHolderAttribute instead of this method
|
private async Task<Dictionary<string, string>> CreatePlaceholders(string? accessCode = null, EnvelopeReceiverDto? envelopeReceiverDto = null, EnvelopeReceiverReadOnlyDto? readOnlyDto = null)
|
||||||
private async Task<Dictionary<string, string>> CreatePlaceholders(string? accessCode = null, EnvelopeReceiverDto? envelopeReceiverDto = null)
|
|
||||||
{
|
{
|
||||||
Dictionary<string, string> placeholders = new() {
|
|
||||||
{ "[NAME_PORTAL]", "signFlow" },
|
|
||||||
{ "[SIGNATURE_TYPE]" , "signieren"},
|
|
||||||
{ "[REASON]", string.Empty } };
|
|
||||||
|
|
||||||
if (accessCode is not null)
|
if (accessCode is not null)
|
||||||
placeholders["[DOCUMENT_ACCESS_CODE]"] = accessCode;
|
_placeholders["[DOCUMENT_ACCESS_CODE]"] = accessCode;
|
||||||
|
|
||||||
if(envelopeReceiverDto is not null && envelopeReceiverDto.Envelope is not null && envelopeReceiverDto.Receiver is not null)
|
if(envelopeReceiverDto?.Envelope is not null && envelopeReceiverDto.Receiver is not null)
|
||||||
{
|
{
|
||||||
var erId = (envelopeReceiverDto.Envelope.Uuid, envelopeReceiverDto.Receiver.Signature).EncodeEnvelopeReceiverId();
|
var erId = (envelopeReceiverDto.Envelope.Uuid, envelopeReceiverDto.Receiver.Signature).EncodeEnvelopeReceiverId();
|
||||||
var sigHost = await _configService.ReadDefaultSignatureHost();
|
var sigHost = await _configService.ReadDefaultSignatureHost();
|
||||||
var linkToDoc = $"{sigHost}/envelope/{erId}";
|
var linkToDoc = $"{sigHost}/EnvelopeKey/{erId}";
|
||||||
placeholders["[LINK_TO_DOCUMENT]"] = linkToDoc;
|
_placeholders["[LINK_TO_DOCUMENT]"] = linkToDoc;
|
||||||
placeholders["[LINK_TO_DOCUMENT_TEXT]"] = linkToDoc[..Math.Min(40, linkToDoc.Length)];
|
_placeholders["[LINK_TO_DOCUMENT_TEXT]"] = linkToDoc[..Math.Min(40, linkToDoc.Length)] + "..";
|
||||||
}
|
}
|
||||||
|
|
||||||
return placeholders;
|
return _placeholders;
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<DataResult<int>> SendAccessCodeAsync(EnvelopeReceiverDto dto) => await SendAsync(dto: dto, tempType: Constants.EmailTemplateType.DocumentAccessCodeReceived);
|
private async Task<Dictionary<string, string>> CreatePlaceholders(EnvelopeReceiverReadOnlyDto? readOnlyDto = null)
|
||||||
|
{
|
||||||
|
if (readOnlyDto?.Envelope is not null && readOnlyDto.Receiver is not null)
|
||||||
|
{
|
||||||
|
_placeholders["[NAME_RECEIVER]"] = await _envRcvService.ReadLastUsedReceiverNameByMail(readOnlyDto.AddedWho).ThenAsync(res => res, (msg, ntc) => string.Empty) ?? string.Empty;
|
||||||
|
var erReadOnlyId = (readOnlyDto.Id).EncodeEnvelopeReceiverId();
|
||||||
|
var sigHost = await _configService.ReadDefaultSignatureHost();
|
||||||
|
var linkToDoc = $"{sigHost}/EnvelopeKey/{erReadOnlyId}";
|
||||||
|
_placeholders["[LINK_TO_DOCUMENT]"] = linkToDoc;
|
||||||
|
_placeholders["[LINK_TO_DOCUMENT_TEXT]"] = linkToDoc[..Math.Min(40, linkToDoc.Length)] + "..";
|
||||||
|
}
|
||||||
|
|
||||||
|
return _placeholders;
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<DataResult<int>> SendAccessCodeAsync(EnvelopeReceiverDto dto) => await SendAsync(dto: dto, tempType: Constants.EmailTemplateType.DocumentAccessCodeReceived);
|
||||||
|
|
||||||
public async Task<DataResult<int>> SendAsync(EnvelopeReceiverDto dto, Constants.EmailTemplateType tempType)
|
public async Task<DataResult<int>> SendAsync(EnvelopeReceiverDto dto, Constants.EmailTemplateType tempType)
|
||||||
{
|
{
|
||||||
@@ -92,8 +104,43 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
|
|
||||||
var placeholders = await CreatePlaceholders(accessCode: accessCode, envelopeReceiverDto: dto);
|
var placeholders = await CreatePlaceholders(accessCode: accessCode, envelopeReceiverDto: dto);
|
||||||
|
|
||||||
|
//TODO: remove the requirement to add the models using reflections
|
||||||
return await CreateWithTemplateAsync(createDto: mail,placeholders: placeholders,
|
return await CreateWithTemplateAsync(createDto: mail,placeholders: placeholders,
|
||||||
dto, dto.Envelope.User!, dto.Envelope);
|
dto, dto.Envelope.User!, dto.Envelope);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
public async Task<DataResult<int>> SendAsync(EnvelopeReceiverReadOnlyDto dto)
|
||||||
|
{
|
||||||
|
var tempSerResult = await _tempService.ReadByNameAsync(Constants.EmailTemplateType.DocumentShared);
|
||||||
|
if (tempSerResult.IsFailed)
|
||||||
|
return tempSerResult.ToFail<int>().Notice(LogLevel.Error, Flag.DataIntegrityIssue, $"The email cannot send because '{Constants.EmailTemplateType.DocumentShared}' template cannot found.");
|
||||||
|
var temp = tempSerResult.Data;
|
||||||
|
|
||||||
|
var mail = new EmailOutCreateDto()
|
||||||
|
{
|
||||||
|
EmailAddress = dto.ReceiverMail,
|
||||||
|
EmailSubj = temp.Subject,
|
||||||
|
EmailBody = temp.Body,
|
||||||
|
//TODO: remove int casting when all
|
||||||
|
ReferenceId = (int) dto.EnvelopeId, //REFERENCE_ID = ENVELOPE_ID
|
||||||
|
ReferenceString = dto.Envelope!.Uuid, //REFERENCE_STRING = ENVELOPE_UUID
|
||||||
|
//receiver_name = receiver.name,
|
||||||
|
//receiver_access_code = receiver.access_code,
|
||||||
|
//sender_adress = envelope.user.email,
|
||||||
|
//sender_name = envelope.user.full_name,
|
||||||
|
//envelope_title = envelope.title,
|
||||||
|
ReminderTypeId = _dConfig.ReminderTypeId,
|
||||||
|
SendingProfile = _dConfig.SendingProfile,
|
||||||
|
EntityId = null,
|
||||||
|
WfId = (int)EnvelopeStatus.EnvelopeShared,
|
||||||
|
WfReference = null,
|
||||||
|
AddedWho = _dConfig.AddedWho,
|
||||||
|
EmailAttmt1 = _dConfig.EmailAttmt1
|
||||||
|
};
|
||||||
|
|
||||||
|
var placeholders = await CreatePlaceholders(readOnlyDto: dto);
|
||||||
|
|
||||||
|
return await CreateWithTemplateAsync(createDto: mail, placeholders: placeholders, dto.Envelope);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
using AutoMapper;
|
||||||
|
using DigitalData.Core.Application;
|
||||||
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiverReadOnly;
|
||||||
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.Services
|
||||||
|
{
|
||||||
|
public class EnvelopeReceiverReadOnlyService : CRUDService<IEnvelopeReceiverReadOnlyRepository, EnvelopeReceiverReadOnlyCreateDto, EnvelopeReceiverReadOnlyDto, EnvelopeReceiverReadOnlyUpdateDto, EnvelopeReceiverReadOnly, long>, IEnvelopeReceiverReadOnlyService
|
||||||
|
{
|
||||||
|
public EnvelopeReceiverReadOnlyService(IEnvelopeReceiverReadOnlyRepository repository, IMapper mapper) : base(repository, mapper)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -2,16 +2,17 @@
|
|||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs.EnvelopeReceiver;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
using EnvelopeGenerator.Application.Resources;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using Microsoft.Extensions.Localization;
|
using Microsoft.Extensions.Localization;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
using EnvelopeGenerator.Extensions;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
public class EnvelopeReceiverService : BasicCRUDService<IEnvelopeReceiverRepository, EnvelopeReceiverDto, EnvelopeReceiver, object>, IEnvelopeReceiverService
|
public class EnvelopeReceiverService : BasicCRUDService<IEnvelopeReceiverRepository, EnvelopeReceiverDto, EnvelopeReceiver, (int Envelope, int Receiver)>, IEnvelopeReceiverService
|
||||||
{
|
{
|
||||||
private readonly IStringLocalizer<Resource> _localizer;
|
private readonly IStringLocalizer<Resource> _localizer;
|
||||||
|
|
||||||
@@ -24,13 +25,19 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
public async Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadBySignatureAsync(string signature, bool withEnvelope = false, bool withReceiver = true)
|
public async Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadBySignatureAsync(string signature, bool withEnvelope = false, bool withReceiver = true)
|
||||||
{
|
{
|
||||||
var env_rcvs = await _repository.ReadBySignatureAsync(signature: signature, withEnvelope: withEnvelope, withReceiver: withReceiver);
|
var env_rcvs = await _repository.ReadBySignatureAsync(signature: signature, withEnvelope: withEnvelope, withReceiver: withReceiver);
|
||||||
return Result.Success(_mapper.MapOrThrow<IEnumerable<EnvelopeReceiverDto>>(env_rcvs));
|
return Result.Success(_mapper.Map<IEnumerable<EnvelopeReceiverDto>>(env_rcvs));
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUuidAsync(string uuid, bool withEnvelope = true, bool withReceiver = false)
|
public async Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUuidAsync(string uuid, bool withEnvelope = true, bool withReceiver = false)
|
||||||
{
|
{
|
||||||
var env_rcvs = await _repository.ReadByUuidAsync(uuid: uuid, withEnvelope: withEnvelope, withReceiver: withReceiver);
|
var env_rcvs = await _repository.ReadByUuidAsync(uuid: uuid, withEnvelope: withEnvelope, withReceiver: withReceiver);
|
||||||
return Result.Success(_mapper.MapOrThrow<IEnumerable<EnvelopeReceiverDto>>(env_rcvs));
|
return Result.Success(_mapper.Map<IEnumerable<EnvelopeReceiverDto>>(env_rcvs));
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<DataResult<IEnumerable<EnvelopeReceiverSecretDto>>> ReadSecretByUuidAsync(string uuid, bool withEnvelope = false, bool withReceiver = true)
|
||||||
|
{
|
||||||
|
var env_rcvs = await _repository.ReadByUuidAsync(uuid: uuid, withEnvelope: withEnvelope, withReceiver: withReceiver);
|
||||||
|
return Result.Success(_mapper.Map<IEnumerable<EnvelopeReceiverSecretDto>>(env_rcvs));
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<DataResult<EnvelopeReceiverDto>> ReadByUuidSignatureAsync(string uuid, string signature, bool withEnvelope = true, bool withReceiver = true)
|
public async Task<DataResult<EnvelopeReceiverDto>> ReadByUuidSignatureAsync(string uuid, string signature, bool withEnvelope = true, bool withReceiver = true)
|
||||||
@@ -40,7 +47,7 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
return Result.Fail<EnvelopeReceiverDto>()
|
return Result.Fail<EnvelopeReceiverDto>()
|
||||||
.Message(Key.EnvelopeReceiverNotFound);
|
.Message(Key.EnvelopeReceiverNotFound);
|
||||||
|
|
||||||
return Result.Success(_mapper.MapOrThrow<EnvelopeReceiverDto>(env_rcv));
|
return Result.Success(_mapper.Map<EnvelopeReceiverDto>(env_rcv));
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<DataResult<EnvelopeReceiverDto>> ReadByEnvelopeReceiverIdAsync(string envelopeReceiverId, bool withEnvelope = true, bool withReceiver = true)
|
public async Task<DataResult<EnvelopeReceiverDto>> ReadByEnvelopeReceiverIdAsync(string envelopeReceiverId, bool withEnvelope = true, bool withReceiver = true)
|
||||||
@@ -119,8 +126,14 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
public async Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUsernameAsync(string username, int? min_status = null, int? max_status = null, params int[] ignore_statuses)
|
public async Task<DataResult<IEnumerable<EnvelopeReceiverDto>>> ReadByUsernameAsync(string username, int? min_status = null, int? max_status = null, params int[] ignore_statuses)
|
||||||
{
|
{
|
||||||
var er_list = await _repository.ReadByUsernameAsync(username: username, min_status: min_status, max_status: max_status, ignore_statuses: ignore_statuses);
|
var er_list = await _repository.ReadByUsernameAsync(username: username, min_status: min_status, max_status: max_status, ignore_statuses: ignore_statuses);
|
||||||
var dto_list = _mapper.MapOrThrow<IEnumerable<EnvelopeReceiverDto>>(er_list);
|
var dto_list = _mapper.Map<IEnumerable<EnvelopeReceiverDto>>(er_list);
|
||||||
return Result.Success(dto_list);
|
return Result.Success(dto_list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public async Task<DataResult<string?>> ReadLastUsedReceiverNameByMail(string mail)
|
||||||
|
{
|
||||||
|
var er = await _repository.ReadLastByReceiver(mail);
|
||||||
|
return er is null ? Result.Fail<string?>().Notice(LogLevel.None, Flag.NotFound) : Result.Success(er.Name);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3,27 +3,22 @@ using DigitalData.Core.Application;
|
|||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using Microsoft.Extensions.Logging;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
public class EnvelopeService : BasicCRUDService<IEnvelopeRepository, EnvelopeDto, Envelope, int>, IEnvelopeService
|
public class EnvelopeService : BasicCRUDService<IEnvelopeRepository, EnvelopeDto, Envelope, int>, IEnvelopeService
|
||||||
{
|
{
|
||||||
private readonly ILogger _logger;
|
public EnvelopeService(IEnvelopeRepository repository, IMapper mapper)
|
||||||
public EnvelopeService(IEnvelopeRepository repository, IMapper mapper, ILogger<EnvelopeService> logger)
|
|
||||||
: base(repository, mapper)
|
: base(repository, mapper)
|
||||||
{
|
{
|
||||||
_logger = logger;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<DataResult<IEnumerable<EnvelopeDto>>> ReadAllWithAsync(bool documents = false, bool history = false, bool documentReceiverElement = false)
|
public async Task<DataResult<IEnumerable<EnvelopeDto>>> ReadAllWithAsync(bool documents = false, bool history = false, bool documentReceiverElement = false)
|
||||||
{
|
{
|
||||||
var envelopes = await _repository.ReadAllWithAsync(documents: documents, history: history, documentReceiverElement: documentReceiverElement);
|
var envelopes = await _repository.ReadAllWithAsync(documents: documents, history: history, documentReceiverElement: documentReceiverElement);
|
||||||
var readDto = _mapper.MapOrThrow<IEnumerable<EnvelopeDto>>(envelopes);
|
var readDto = _mapper.Map<IEnumerable<EnvelopeDto>>(envelopes);
|
||||||
return Result.Success(readDto);
|
return Result.Success(readDto);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -34,7 +29,14 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
if (envelope is null)
|
if (envelope is null)
|
||||||
return Result.Fail<EnvelopeDto>();
|
return Result.Fail<EnvelopeDto>();
|
||||||
|
|
||||||
var readDto = _mapper.MapOrThrow<EnvelopeDto>(envelope);
|
var readDto = _mapper.Map<EnvelopeDto>(envelope);
|
||||||
|
return Result.Success(readDto);
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<DataResult<IEnumerable<EnvelopeDto>>> ReadByUserAsync(int userId, int? min_status = null, int? max_status = null, params int[] ignore_statuses)
|
||||||
|
{
|
||||||
|
var users = await _repository.ReadByUserAsync(userId: userId, min_status: min_status, max_status: max_status, ignore_statuses: ignore_statuses);
|
||||||
|
var readDto = _mapper.Map<IEnumerable<EnvelopeDto>>(users);
|
||||||
return Result.Success(readDto);
|
return Result.Success(readDto);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,19 +1,30 @@
|
|||||||
using AutoMapper;
|
using AutoMapper;
|
||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
using Microsoft.Extensions.Caching.Memory;
|
||||||
|
using DigitalData.Core.DTO;
|
||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
public class EnvelopeTypeService : BasicCRUDService<IEnvelopeTypeRepository, EnvelopeTypeDto, EnvelopeType, int>, IEnvelopeTypeService
|
public class EnvelopeTypeService : BasicCRUDService<IEnvelopeTypeRepository, EnvelopeTypeDto, EnvelopeType, int>, IEnvelopeTypeService
|
||||||
{
|
{
|
||||||
public EnvelopeTypeService(IEnvelopeTypeRepository repository, IMapper mapper)
|
private static readonly Guid CacheKey = Guid.NewGuid();
|
||||||
|
|
||||||
|
private readonly IMemoryCache _cache;
|
||||||
|
|
||||||
|
public EnvelopeTypeService(IEnvelopeTypeRepository repository, IMapper mapper, IMemoryCache cache)
|
||||||
: base(repository, mapper)
|
: base(repository, mapper)
|
||||||
{
|
{
|
||||||
|
_cache = cache;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override async Task<DataResult<IEnumerable<EnvelopeTypeDto>>> ReadAllAsync()
|
||||||
|
=> await _cache.GetOrCreateAsync(CacheKey, async entry => await base.ReadAllAsync())
|
||||||
|
?? Result.Fail<IEnumerable<EnvelopeTypeDto>>().Notice(LogLevel.Error, Flag.NotFound, "No cached envelope types are available in the database. If you have added any envelope types after the server started, please restart the server.");
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
using DigitalData.Core.Abstractions.Client;
|
||||||
|
using DigitalData.Core.Client;
|
||||||
|
using EnvelopeGenerator.Application.Configurations.GtxMessaging;
|
||||||
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
|
using Microsoft.Extensions.Options;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Application.Services
|
||||||
|
{
|
||||||
|
public class GtxMessagingService : IMessagingService
|
||||||
|
{
|
||||||
|
private readonly IHttpClientService<SmsParams> _smsClient;
|
||||||
|
|
||||||
|
private readonly SmsParams _smsParams;
|
||||||
|
|
||||||
|
public GtxMessagingService(IHttpClientService<SmsParams> smsClient, IOptions<SmsParams> smsParamsOptions)
|
||||||
|
{
|
||||||
|
_smsClient = smsClient;
|
||||||
|
_smsParams = smsParamsOptions.Value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Task<dynamic?> SendSmsAsync(string recipient, string message) => SendSmsAsync<dynamic>(recipient: recipient, message: message);
|
||||||
|
|
||||||
|
public async Task<TResponse?> SendSmsAsync<TResponse>(string recipient, string message)
|
||||||
|
{
|
||||||
|
return await _smsClient.FetchAsync(queryParams: new Dictionary<string, object?>() {
|
||||||
|
{ _smsParams.RecipientQueryParamName, recipient },
|
||||||
|
{ _smsParams.MessageQueryParamName, message }
|
||||||
|
}).ThenAsync(res => res.Json<TResponse>());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,10 +1,8 @@
|
|||||||
using AutoMapper;
|
using AutoMapper;
|
||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
using EnvelopeGenerator.Application.DTOs.Receiver;
|
using EnvelopeGenerator.Application.DTOs.Receiver;
|
||||||
using DigitalData.Core.DTO;
|
using DigitalData.Core.DTO;
|
||||||
|
|
||||||
@@ -12,7 +10,7 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
{
|
{
|
||||||
public class ReceiverService : CRUDService<IReceiverRepository, ReceiverCreateDto, ReceiverReadDto, ReceiverUpdateDto, Receiver, int>, IReceiverService
|
public class ReceiverService : CRUDService<IReceiverRepository, ReceiverCreateDto, ReceiverReadDto, ReceiverUpdateDto, Receiver, int>, IReceiverService
|
||||||
{
|
{
|
||||||
public ReceiverService(IReceiverRepository repository, IStringLocalizer<Resource> localizer, IMapper mapper)
|
public ReceiverService(IReceiverRepository repository, IMapper mapper)
|
||||||
: base(repository, mapper)
|
: base(repository, mapper)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -24,7 +22,7 @@ namespace EnvelopeGenerator.Application.Services
|
|||||||
if (rcv is null)
|
if (rcv is null)
|
||||||
return Result.Fail<ReceiverReadDto>();
|
return Result.Fail<ReceiverReadDto>();
|
||||||
|
|
||||||
return Result.Success(_mapper.MapOrThrow<ReceiverReadDto>(rcv));
|
return Result.Success(_mapper.Map<ReceiverReadDto>(rcv));
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<Result> DeleteByAsync(string? emailAddress = null, string? signature = null)
|
public async Task<Result> DeleteByAsync(string? emailAddress = null, string? signature = null)
|
||||||
|
|||||||
@@ -1,17 +1,15 @@
|
|||||||
using AutoMapper;
|
using AutoMapper;
|
||||||
using DigitalData.Core.Application;
|
using DigitalData.Core.Application;
|
||||||
using Microsoft.Extensions.Localization;
|
|
||||||
using EnvelopeGenerator.Application.Contracts;
|
using EnvelopeGenerator.Application.Contracts;
|
||||||
using EnvelopeGenerator.Application.DTOs;
|
using EnvelopeGenerator.Application.DTOs;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure.Contracts;
|
using EnvelopeGenerator.Infrastructure.Contracts;
|
||||||
using EnvelopeGenerator.Application.Resources;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application.Services
|
namespace EnvelopeGenerator.Application.Services
|
||||||
{
|
{
|
||||||
public class UserReceiverService : BasicCRUDService<IUserReceiverRepository, UserReceiverDto, UserReceiver, int>, IUserReceiverService
|
public class UserReceiverService : BasicCRUDService<IUserReceiverRepository, UserReceiverDto, UserReceiver, int>, IUserReceiverService
|
||||||
{
|
{
|
||||||
public UserReceiverService(IUserReceiverRepository repository, IStringLocalizer<Resource> localizer, IMapper mapper)
|
public UserReceiverService(IUserReceiverRepository repository, IMapper mapper)
|
||||||
: base(repository, mapper)
|
: base(repository, mapper)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
Public Class Constants
|
Public Class Constants
|
||||||
|
|
||||||
#Region "Status Fields"
|
#Region "Status Fields"
|
||||||
|
'http://wiki.dd/xwiki13/bin/view/Anwendungen/Produkt-Handbuch/Sonstiges/SignFlow/Envelope%20Status/
|
||||||
Public Enum EnvelopeStatus
|
Public Enum EnvelopeStatus
|
||||||
Invalid = 0
|
Invalid = 0
|
||||||
EnvelopeCreated = 1001
|
EnvelopeCreated = 1001
|
||||||
@@ -17,8 +18,11 @@
|
|||||||
AccessCodeIncorrect = 2003
|
AccessCodeIncorrect = 2003
|
||||||
DocumentOpened = 2004
|
DocumentOpened = 2004
|
||||||
DocumentSigned = 2005
|
DocumentSigned = 2005
|
||||||
|
DocumentForwarded = 4001
|
||||||
SignatureConfirmed = 2006
|
SignatureConfirmed = 2006
|
||||||
DocumentRejected = 2007
|
DocumentRejected = 2007
|
||||||
|
EnvelopeShared = 2008
|
||||||
|
EnvelopeViewed = 2009
|
||||||
MessageInvitationSent = 3001 ' Wird von Trigger verwendet
|
MessageInvitationSent = 3001 ' Wird von Trigger verwendet
|
||||||
MessageAccessCodeSent = 3002
|
MessageAccessCodeSent = 3002
|
||||||
MessageConfirmationSent = 3003
|
MessageConfirmationSent = 3003
|
||||||
@@ -26,6 +30,7 @@
|
|||||||
MessageCompletionSent = 3005
|
MessageCompletionSent = 3005
|
||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
|
'TODO: standardize in xwiki
|
||||||
Public Enum ReferenceType
|
Public Enum ReferenceType
|
||||||
Receiver
|
Receiver
|
||||||
Sender
|
Sender
|
||||||
@@ -73,7 +78,7 @@
|
|||||||
|
|
||||||
Public Enum CertificationType
|
Public Enum CertificationType
|
||||||
ElectronicSignature = 1
|
ElectronicSignature = 1
|
||||||
QualifiedSignature = 2
|
'QualifiedSignature = 2
|
||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
Public Enum FinalEmailType
|
Public Enum FinalEmailType
|
||||||
@@ -93,6 +98,15 @@
|
|||||||
DocumentDeleted
|
DocumentDeleted
|
||||||
DocumentCompleted
|
DocumentCompleted
|
||||||
DocumentAccessCodeReceived
|
DocumentAccessCodeReceived
|
||||||
|
DocumentShared
|
||||||
|
End Enum
|
||||||
|
|
||||||
|
Public Enum EncodeType
|
||||||
|
EnvelopeReceiver
|
||||||
|
EnvelopeReceiverReadOnly
|
||||||
|
Undefined
|
||||||
|
DocumentForwarded
|
||||||
|
DocumentShared
|
||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
@@ -108,4 +122,4 @@
|
|||||||
Public Const RED_300 = "#fecaca"
|
Public Const RED_300 = "#fecaca"
|
||||||
Public Const ORANGE_300 = "#fed7aa"
|
Public Const ORANGE_300 = "#fed7aa"
|
||||||
#End Region
|
#End Region
|
||||||
End Class
|
End Class
|
||||||
@@ -1,15 +1,8 @@
|
|||||||
Public Class DbConfig
|
Public Class DbConfig
|
||||||
Public Property ExternalProgramName As String = "Sign Flow"
|
Public Property ExternalProgramName As String = "signFLOW"
|
||||||
Public Property DocumentPathOrigin As String = ""
|
Public Property DocumentPathOrigin As String = ""
|
||||||
Public Property DocumentPath As String = ""
|
Public Property DocumentPath As String = ""
|
||||||
Public Property ExportPath As String = ""
|
Public Property ExportPath As String = ""
|
||||||
Public Property DocumentPath_DMZ As String = ""
|
|
||||||
Public Property ExportPath_DMZ As String = ""
|
|
||||||
Public Property DOCUMENT_PATH_MOVE_AFTSEND As String = ""
|
|
||||||
Public Property FINISHED_PATH_EX_DMZ As String = ""
|
|
||||||
Public Property EML_PATH_EX_DMZ As String = ""
|
|
||||||
Public Property SendingProfile As Integer = 0
|
Public Property SendingProfile As Integer = 0
|
||||||
Public Property SignatureHost As String = ""
|
Public Property SignatureHost As String = ""
|
||||||
Public Property NetUse_necessary As Boolean = False
|
|
||||||
Public Property NetUse_Finish As Boolean = False
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -13,6 +13,8 @@
|
|||||||
<TargetFrameworkVersion>v4.6.2</TargetFrameworkVersion>
|
<TargetFrameworkVersion>v4.6.2</TargetFrameworkVersion>
|
||||||
<Deterministic>true</Deterministic>
|
<Deterministic>true</Deterministic>
|
||||||
<TargetFrameworkProfile />
|
<TargetFrameworkProfile />
|
||||||
|
<NuGetPackageImportStamp>
|
||||||
|
</NuGetPackageImportStamp>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<DebugSymbols>true</DebugSymbols>
|
<DebugSymbols>true</DebugSymbols>
|
||||||
@@ -63,22 +65,20 @@
|
|||||||
<Reference Include="DevExpress.XtraEditors.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
<Reference Include="DevExpress.XtraEditors.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
||||||
<Reference Include="DevExpress.XtraGauges.v21.2.Core, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
<Reference Include="DevExpress.XtraGauges.v21.2.Core, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
||||||
<Reference Include="DevExpress.XtraReports.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
<Reference Include="DevExpress.XtraReports.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
||||||
<Reference Include="DigitalData.Modules.Base, Version=1.3.4.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="DigitalData.Modules.Base">
|
||||||
<SpecificVersion>False</SpecificVersion>
|
<HintPath>..\..\2_DLL Projekte\DDModules\Base\bin\Debug\DigitalData.Modules.Base.dll</HintPath>
|
||||||
<HintPath>..\..\DDModules\Base\bin\Debug\DigitalData.Modules.Base.dll</HintPath>
|
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DigitalData.Modules.Config">
|
<Reference Include="DigitalData.Modules.Config">
|
||||||
<HintPath>..\..\DDModules\Config\bin\Debug\DigitalData.Modules.Config.dll</HintPath>
|
<HintPath>..\..\2_DLL Projekte\DDModules\Config\bin\Debug\DigitalData.Modules.Config.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DigitalData.Modules.Database">
|
<Reference Include="DigitalData.Modules.Database">
|
||||||
<HintPath>..\..\DDModules\Database\bin\Debug\DigitalData.Modules.Database.dll</HintPath>
|
<HintPath>..\..\2_DLL Projekte\DDModules\Database\bin\Debug\DigitalData.Modules.Database.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DigitalData.Modules.Logging, Version=2.6.2.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="DigitalData.Modules.Logging">
|
||||||
<SpecificVersion>False</SpecificVersion>
|
<HintPath>..\..\2_DLL Projekte\DDModules\Logging\bin\Debug\DigitalData.Modules.Logging.dll</HintPath>
|
||||||
<HintPath>..\..\DDModules\Logging\bin\Debug\DigitalData.Modules.Logging.dll</HintPath>
|
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="GdPicture.NET.14">
|
<Reference Include="GdPicture.NET.14, Version=14.2.89.0, Culture=neutral, PublicKeyToken=f52a2e60ad468dbb, processorArchitecture=MSIL">
|
||||||
<HintPath>D:\ProgramFiles\GdPicture.NET 14\Redist\GdPicture.NET (.NET Framework 4.5)\GdPicture.NET.14.dll</HintPath>
|
<HintPath>..\packages\GdPicture.14.2.89\lib\net462\GdPicture.NET.14.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="Microsoft.Extensions.Logging.Abstractions, Version=2.1.1.0, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
|
<Reference Include="Microsoft.Extensions.Logging.Abstractions, Version=2.1.1.0, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
|
||||||
@@ -260,11 +260,13 @@
|
|||||||
<Generator>PublicResXFileCodeGenerator</Generator>
|
<Generator>PublicResXFileCodeGenerator</Generator>
|
||||||
<LastGenOutput>Model.en.Designer.vb</LastGenOutput>
|
<LastGenOutput>Model.en.Designer.vb</LastGenOutput>
|
||||||
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="Strings\Model.resx">
|
<EmbeddedResource Include="Strings\Model.resx">
|
||||||
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||||
<Generator>PublicResXFileCodeGenerator</Generator>
|
<Generator>PublicResXFileCodeGenerator</Generator>
|
||||||
<LastGenOutput>Model.Designer.vb</LastGenOutput>
|
<LastGenOutput>Model.Designer.vb</LastGenOutput>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
@@ -289,4 +291,11 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup />
|
<ItemGroup />
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||||
|
<Import Project="..\packages\GdPicture.runtimes.windows.14.2.89\build\net462\GdPicture.runtimes.windows.targets" Condition="Exists('..\packages\GdPicture.runtimes.windows.14.2.89\build\net462\GdPicture.runtimes.windows.targets')" />
|
||||||
|
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||||
|
<PropertyGroup>
|
||||||
|
<ErrorText>Dieses Projekt verweist auf mindestens ein NuGet-Paket, das auf diesem Computer fehlt. Verwenden Sie die Wiederherstellung von NuGet-Paketen, um die fehlenden Dateien herunterzuladen. Weitere Informationen finden Sie unter "http://go.microsoft.com/fwlink/?LinkID=322105". Die fehlende Datei ist "{0}".</ErrorText>
|
||||||
|
</PropertyGroup>
|
||||||
|
<Error Condition="!Exists('..\packages\GdPicture.runtimes.windows.14.2.89\build\net462\GdPicture.runtimes.windows.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\GdPicture.runtimes.windows.14.2.89\build\net462\GdPicture.runtimes.windows.targets'))" />
|
||||||
|
</Target>
|
||||||
</Project>
|
</Project>
|
||||||
@@ -33,7 +33,7 @@ Namespace Jobs
|
|||||||
Private PDFMerger As PDFMerger
|
Private PDFMerger As PDFMerger
|
||||||
Private ReportCreator As ReportCreator
|
Private ReportCreator As ReportCreator
|
||||||
|
|
||||||
Private ReadOnly CompleteWaitTime As Integer = 5
|
Private ReadOnly CompleteWaitTime As Integer = 1
|
||||||
Private ParentFolderUID As String = ""
|
Private ParentFolderUID As String = ""
|
||||||
Private myTempFiles As TempFiles
|
Private myTempFiles As TempFiles
|
||||||
|
|
||||||
@@ -82,49 +82,14 @@ Namespace Jobs
|
|||||||
|
|
||||||
Logger.Debug("Loading ReportCreator..")
|
Logger.Debug("Loading ReportCreator..")
|
||||||
ReportCreator = New ReportCreator(LogConfig, oState)
|
ReportCreator = New ReportCreator(LogConfig, oState)
|
||||||
Logger.Debug("My.Settings.RuninDMZ: [{0}]", My.Settings.RuninDMZ.ToString)
|
|
||||||
Logger.Debug("My.Settings.NetUse_Usr: [{0}]", My.Settings.NetUse_Usr)
|
|
||||||
|
|
||||||
|
Config.DocumentPath = Config.DocumentPath
|
||||||
|
|
||||||
If My.Settings.RuninDMZ = True Then
|
|
||||||
If Config.DocumentPath_DMZ <> String.Empty Then
|
|
||||||
Logger.Debug("RuninDMZ - Using DocumentPath_DMZ: [{0}] - Overwrite Document-Path", Config.DocumentPath_DMZ)
|
|
||||||
Config.DocumentPath = Config.DocumentPath_DMZ
|
|
||||||
Config.NetUse_necessary = True
|
|
||||||
Else
|
|
||||||
Config.DocumentPath = Config.DocumentPath
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
If Config.DOCUMENT_PATH_MOVE_AFTSEND <> String.Empty Then
|
|
||||||
Logger.Debug("Using DMZRemotePath: [{0}] - Overwrite Document-Path ...", Config.DOCUMENT_PATH_MOVE_AFTSEND)
|
|
||||||
Config.DocumentPath = Config.DOCUMENT_PATH_MOVE_AFTSEND
|
|
||||||
Config.NetUse_Finish = True
|
|
||||||
|
|
||||||
Else
|
|
||||||
Config.DocumentPath = Config.DocumentPath
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
Logger.Debug("DocumentPath: [{0}]", Config.DocumentPath)
|
Logger.Debug("DocumentPath: [{0}]", Config.DocumentPath)
|
||||||
|
|
||||||
If My.Settings.RuninDMZ = True Then
|
|
||||||
If Config.FINISHED_PATH_EX_DMZ <> String.Empty Then
|
|
||||||
Logger.Debug("RuninDMZ - FINISHED_PATH_EX_DMZ configured: [{0}]", Config.FINISHED_PATH_EX_DMZ)
|
|
||||||
Config.NetUse_Finish = True
|
|
||||||
End If
|
|
||||||
If Config.ExportPath_DMZ <> String.Empty Then
|
|
||||||
Logger.Debug("RuninDMZ - Using ExportPath_DMZ: [{0}] - Overwrite ExportPath", Config.ExportPath_DMZ)
|
|
||||||
Config.ExportPath = Config.ExportPath_DMZ
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
Logger.Debug("ExportPath: [{0}]", Config.ExportPath)
|
Logger.Debug("ExportPath: [{0}]", Config.ExportPath)
|
||||||
|
|
||||||
If Config.NetUse_Finish = True Then
|
|
||||||
If NetUse_Command(Config.DocumentPath, My.Settings.NetUse_Usr, My.Settings.NetUse_PW) = True Then
|
|
||||||
Logger.Debug("NetUse_Finish = successful!")
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
Dim oCompleteStatus As Integer = Constants.EnvelopeStatus.EnvelopeCompletelySigned
|
Dim oCompleteStatus As Integer = Constants.EnvelopeStatus.EnvelopeCompletelySigned
|
||||||
Dim oSql = $"SELECT * FROM TBSIG_ENVELOPE WHERE STATUS = {oCompleteStatus} AND DATEDIFF(minute, CHANGED_WHEN, GETDATE()) >= {CompleteWaitTime} ORDER BY GUID"
|
Dim oSql = $"SELECT * FROM TBSIG_ENVELOPE WHERE STATUS = {oCompleteStatus} AND DATEDIFF(minute, CHANGED_WHEN, GETDATE()) >= {CompleteWaitTime} ORDER BY GUID"
|
||||||
Dim oTable = Database.GetDatatable(oSql)
|
Dim oTable = Database.GetDatatable(oSql)
|
||||||
@@ -157,10 +122,6 @@ Namespace Jobs
|
|||||||
Logger.Warn("EnvelopeData could not be loaded for Id [{0}]!", oId)
|
Logger.Warn("EnvelopeData could not be loaded for Id [{0}]!", oId)
|
||||||
Throw New ArgumentNullException("EnvelopeData")
|
Throw New ArgumentNullException("EnvelopeData")
|
||||||
End If
|
End If
|
||||||
If Config.DOCUMENT_PATH_MOVE_AFTSEND <> String.Empty Then
|
|
||||||
oEnvelopeData.DocumentPath.Replace(Config.DocumentPathOrigin, Config.DOCUMENT_PATH_MOVE_AFTSEND)
|
|
||||||
Logger.Debug("Replaced Path in oEnvelopeData.DocumentPath!")
|
|
||||||
End If
|
|
||||||
Logger.Debug("Burning Annotations to pdf ...")
|
Logger.Debug("Burning Annotations to pdf ...")
|
||||||
Dim oBurnedDocument As Byte() = BurnAnnotationsToPdf(oEnvelopeData)
|
Dim oBurnedDocument As Byte() = BurnAnnotationsToPdf(oEnvelopeData)
|
||||||
If oBurnedDocument Is Nothing Then
|
If oBurnedDocument Is Nothing Then
|
||||||
@@ -196,13 +157,6 @@ 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
|
||||||
|
|
||||||
If Config.NetUse_Finish = True Then
|
|
||||||
If Config.FINISHED_PATH_EX_DMZ <> String.Empty Then
|
|
||||||
If My.Settings.NetUse_PW <> String.Empty And My.Settings.NetUse_Usr <> String.Empty Then
|
|
||||||
Clean_DNZ_PAth(Config.FINISHED_PATH_EX_DMZ)
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
Logger.Info("Writing EB-bytes to database...")
|
Logger.Info("Writing EB-bytes to database...")
|
||||||
Update_File_DB(oOutputFilePath, oEnvelope.Id)
|
Update_File_DB(oOutputFilePath, oEnvelope.Id)
|
||||||
|
|
||||||
@@ -287,48 +241,48 @@ Namespace Jobs
|
|||||||
data = br.ReadBytes(CInt(numBytes))
|
data = br.ReadBytes(CInt(numBytes))
|
||||||
Return data
|
Return data
|
||||||
End Function
|
End Function
|
||||||
Private Function NetUse_Command(pDestinationPath As String, pUsername As String, pPassword As String)
|
'Private Function NetUse_Command(pDestinationPath As String, pUsername As String, pPassword As String)
|
||||||
Dim oDectryptedPW = Helpers.Decrypt(My.Settings.NetUse_PW)
|
' Dim oDectryptedPW = Helpers.Decrypt(My.Settings.NetUse_PW)
|
||||||
Dim netUseCommand As String = $"net use {pDestinationPath} /user:{pUsername} {oDectryptedPW}"
|
' Dim netUseCommand As String = $"net use {pDestinationPath} /user:{pUsername} {oDectryptedPW}"
|
||||||
Logger.Debug("EXECUTING NetUse_Command for " & pDestinationPath)
|
' Logger.Debug("EXECUTING NetUse_Command for " & pDestinationPath)
|
||||||
Dim processInfo As New ProcessStartInfo("cmd.exe", $"/C {netUseCommand}")
|
' Dim processInfo As New ProcessStartInfo("cmd.exe", $"/C {netUseCommand}")
|
||||||
processInfo.RedirectStandardOutput = True
|
' processInfo.RedirectStandardOutput = True
|
||||||
processInfo.UseShellExecute = False
|
' processInfo.UseShellExecute = False
|
||||||
processInfo.CreateNoWindow = True
|
' processInfo.CreateNoWindow = True
|
||||||
|
|
||||||
Using process As Process = Process.Start(processInfo)
|
' Using process As Process = Process.Start(processInfo)
|
||||||
process.WaitForExit()
|
' process.WaitForExit()
|
||||||
|
|
||||||
' Prüfe den Rückgabewert des net use Befehls
|
' ' Prüfe den Rückgabewert des net use Befehls
|
||||||
If process.ExitCode = 0 Then
|
' If process.ExitCode = 0 Then
|
||||||
Return True
|
' Return True
|
||||||
Else
|
' Else
|
||||||
Return False
|
' Return False
|
||||||
End If
|
' End If
|
||||||
End Using
|
' End Using
|
||||||
End Function
|
'End Function
|
||||||
|
|
||||||
Private Function Clean_DNZ_PAth(pSourcePath As String) As Boolean
|
'Private Function Clean_DNZ_PAth(pSourcePath As String) As Boolean
|
||||||
Dim oFilename = System.IO.Path.GetFileName(pSourcePath)
|
' Dim oFilename = System.IO.Path.GetFileName(pSourcePath)
|
||||||
|
|
||||||
Logger.Debug("## Starting Clean_DNZ_PAth ...")
|
' Logger.Debug("## Starting Clean_DNZ_PAth ...")
|
||||||
Logger.Debug("## pSourcePath {0}", pSourcePath)
|
' Logger.Debug("## pSourcePath {0}", pSourcePath)
|
||||||
|
|
||||||
Dim oDirectorySource = Path.Combine(pSourcePath, ParentFolderUID)
|
' Dim oDirectorySource = Path.Combine(pSourcePath, ParentFolderUID)
|
||||||
|
|
||||||
Try
|
' Try
|
||||||
Logger.Debug($"Deleting oDirectorySource {oDirectorySource} ...")
|
' Logger.Debug($"Deleting oDirectorySource {oDirectorySource} ...")
|
||||||
Directory.Delete(oDirectorySource, True)
|
' Directory.Delete(oDirectorySource, True)
|
||||||
Console.WriteLine($"Folder successfully deleted!")
|
' Console.WriteLine($"Folder successfully deleted!")
|
||||||
Logger.Debug($"...Deleted!")
|
' Logger.Debug($"...Deleted!")
|
||||||
Return True
|
' Return True
|
||||||
Catch ex As Exception
|
' Catch ex As Exception
|
||||||
Logger.Error(ex)
|
' Logger.Error(ex)
|
||||||
Return False
|
' Return False
|
||||||
End Try
|
' End Try
|
||||||
|
|
||||||
|
|
||||||
End Function
|
'End Function
|
||||||
Private Function SendFinalEmails(pEnvelope As Envelope) As Boolean ', pAttachment As String
|
Private Function SendFinalEmails(pEnvelope As Envelope) As Boolean ', pAttachment As String
|
||||||
Dim oMailToCreator = pEnvelope.FinalEmailToCreator
|
Dim oMailToCreator = pEnvelope.FinalEmailToCreator
|
||||||
Dim oMailToReceivers = pEnvelope.FinalEmailToReceivers
|
Dim oMailToReceivers = pEnvelope.FinalEmailToReceivers
|
||||||
@@ -398,15 +352,7 @@ Namespace Jobs
|
|||||||
Dim oAnnotations = pEnvelopeData.AnnotationData
|
Dim oAnnotations = pEnvelopeData.AnnotationData
|
||||||
Dim oInputPath = ""
|
Dim oInputPath = ""
|
||||||
If IsNothing(pEnvelopeData.DocAsByte) Then
|
If IsNothing(pEnvelopeData.DocAsByte) Then
|
||||||
If My.Settings.RuninDMZ Then
|
oInputPath = pEnvelopeData.DocumentPath
|
||||||
Logger.Debug("Replacing Path in pData.DocumentPath ...")
|
|
||||||
oInputPath = pEnvelopeData.DocumentPath.Replace(Config.DocumentPathOrigin, Config.DocumentPath)
|
|
||||||
ElseIf Config.DOCUMENT_PATH_MOVE_AFTSEND <> String.Empty Then
|
|
||||||
Logger.Debug("Replacing Path in pData.DocumentPath ...")
|
|
||||||
oInputPath = pEnvelopeData.DocumentPath.Replace(Config.DocumentPathOrigin, Config.DOCUMENT_PATH_MOVE_AFTSEND)
|
|
||||||
Else
|
|
||||||
oInputPath = pEnvelopeData.DocumentPath
|
|
||||||
End If
|
|
||||||
Logger.Info($"Input path: [{oInputPath}]")
|
Logger.Info($"Input path: [{oInputPath}]")
|
||||||
Else
|
Else
|
||||||
Logger.Info($"we got bytes..")
|
Logger.Info($"we got bytes..")
|
||||||
|
|||||||
@@ -16,17 +16,12 @@ Public Class ConfigModel
|
|||||||
Dim oRow As DataRow = oTable.Rows.Item(0)
|
Dim oRow As DataRow = oTable.Rows.Item(0)
|
||||||
|
|
||||||
Return New DbConfig() With {
|
Return New DbConfig() With {
|
||||||
.DocumentPath = oRow.ItemEx("DOCUMENT_PATH", ""),
|
.DocumentPath = oRow.ItemEx("DOCUMENT_PATH", ""),
|
||||||
.DocumentPathOrigin = oRow.ItemEx("DOCUMENT_PATH", ""),
|
.DocumentPathOrigin = oRow.ItemEx("DOCUMENT_PATH", ""),
|
||||||
.DocumentPath_DMZ = oRow.ItemEx("DOCUMENT_PATH_DMZ", ""),
|
.ExportPath = oRow.ItemEx("EXPORT_PATH", ""),
|
||||||
.ExportPath = oRow.ItemEx("EXPORT_PATH", ""),
|
.SendingProfile = oRow.ItemEx("SENDING_PROFILE", 0),
|
||||||
.ExportPath_DMZ = oRow.ItemEx("EXPORT_PATH_DMZ", ""),
|
.SignatureHost = oRow.ItemEx("SIGNATURE_HOST", ""),
|
||||||
.SendingProfile = oRow.ItemEx("SENDING_PROFILE", 0),
|
.ExternalProgramName = oRow.ItemEx("EXTERNAL_PROGRAM_NAME", "")
|
||||||
.SignatureHost = oRow.ItemEx("SIGNATURE_HOST", ""),
|
|
||||||
.ExternalProgramName = oRow.ItemEx("EXTERNAL_PROGRAM_NAME", ""),
|
|
||||||
.DOCUMENT_PATH_MOVE_AFTSEND = oRow.ItemEx("DOCUMENT_PATH_MOVE_AFTSEND", ""),
|
|
||||||
.FINISHED_PATH_EX_DMZ = oRow.ItemEx("FINISHED_PATH_EX_DMZ", ""),
|
|
||||||
.EML_PATH_EX_DMZ = oRow.ItemEx("EML_PATH_EX_DMZ", "")
|
|
||||||
}
|
}
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
Logger.Error(ex)
|
Logger.Error(ex)
|
||||||
|
|||||||
@@ -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("1.9.1.0")>
|
<Assembly: AssemblyVersion("2.0.0.0")>
|
||||||
<Assembly: AssemblyFileVersion("1.9.1.0")>
|
<Assembly: AssemblyFileVersion("2.0.0.0")>
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ Option Explicit On
|
|||||||
Namespace My
|
Namespace My
|
||||||
|
|
||||||
<Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
|
<Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
|
||||||
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.3.0.0"), _
|
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.9.0.0"), _
|
||||||
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||||
Partial Friend NotInheritable Class MySettings
|
Partial Friend NotInheritable Class MySettings
|
||||||
Inherits Global.System.Configuration.ApplicationSettingsBase
|
Inherits Global.System.Configuration.ApplicationSettingsBase
|
||||||
@@ -53,33 +53,6 @@ Namespace My
|
|||||||
Return defaultInstance
|
Return defaultInstance
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _
|
|
||||||
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
|
||||||
Global.System.Configuration.DefaultSettingValueAttribute("False")> _
|
|
||||||
Public ReadOnly Property RuninDMZ() As Boolean
|
|
||||||
Get
|
|
||||||
Return CType(Me("RuninDMZ"),Boolean)
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
|
|
||||||
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _
|
|
||||||
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
|
||||||
Global.System.Configuration.DefaultSettingValueAttribute("dd-gan\Administrator")> _
|
|
||||||
Public ReadOnly Property NetUse_Usr() As String
|
|
||||||
Get
|
|
||||||
Return CType(Me("NetUse_Usr"),String)
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
|
|
||||||
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _
|
|
||||||
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
|
||||||
Global.System.Configuration.DefaultSettingValueAttribute("sY4vnATDXwosbTJGip6SqA==")> _
|
|
||||||
Public ReadOnly Property NetUse_PW() As String
|
|
||||||
Get
|
|
||||||
Return CType(Me("NetUse_PW"),String)
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
End Class
|
End Class
|
||||||
End Namespace
|
End Namespace
|
||||||
|
|
||||||
|
|||||||
@@ -1,15 +1,5 @@
|
|||||||
<?xml version='1.0' encoding='utf-8'?>
|
<?xml version='1.0' encoding='utf-8'?>
|
||||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="My" GeneratedClassName="MySettings" UseMySettingsClassName="true">
|
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" UseMySettingsClassName="true">
|
||||||
<Profiles />
|
<Profiles />
|
||||||
<Settings>
|
<Settings />
|
||||||
<Setting Name="RuninDMZ" Type="System.Boolean" Scope="Application">
|
|
||||||
<Value Profile="(Default)">False</Value>
|
|
||||||
</Setting>
|
|
||||||
<Setting Name="NetUse_Usr" Type="System.String" Scope="Application">
|
|
||||||
<Value Profile="(Default)">dd-gan\Administrator</Value>
|
|
||||||
</Setting>
|
|
||||||
<Setting Name="NetUse_PW" Type="System.String" Scope="Application">
|
|
||||||
<Value Profile="(Default)">sY4vnATDXwosbTJGip6SqA==</Value>
|
|
||||||
</Setting>
|
|
||||||
</Settings>
|
|
||||||
</SettingsFile>
|
</SettingsFile>
|
||||||
@@ -34,8 +34,18 @@ Public Class ActionService
|
|||||||
|
|
||||||
Return True
|
Return True
|
||||||
End Function
|
End Function
|
||||||
|
Public Function Resend_Receiver(pEnvelope As Envelope, pmail As String) As Boolean
|
||||||
|
If HistoryService.SetEnvelopeStatus(pEnvelope, Constants.EnvelopeStatus.EnvelopeQueued, pEnvelope.User.Email) = False Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
Dim oSendResult As Boolean = False
|
||||||
|
For Each oReceiver In pEnvelope.Receivers
|
||||||
|
EmailService.SendDocumentReceivedEmail(pEnvelope, oReceiver)
|
||||||
|
Next
|
||||||
|
Return oSendResult
|
||||||
|
End Function
|
||||||
Public Function ResendReceiver(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As Boolean
|
Public Function ResendReceiver(pEnvelope As Envelope, pReceiver As EnvelopeReceiver) As Boolean
|
||||||
EmailService.SendDocumentReceivedEmail(pEnvelope, pReceiver)
|
Return EmailService.SendDocumentReceivedEmail(pEnvelope, pReceiver)
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -138,6 +138,9 @@
|
|||||||
<data name="Document Could Not Be Saved" xml:space="preserve">
|
<data name="Document Could Not Be Saved" xml:space="preserve">
|
||||||
<value>Document could not be saved!</value>
|
<value>Document could not be saved!</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Document forwarded" xml:space="preserve">
|
||||||
|
<value>Document forwarded to receiver: {0}</value>
|
||||||
|
</data>
|
||||||
<data name="Edit Envelope" xml:space="preserve">
|
<data name="Edit Envelope" xml:space="preserve">
|
||||||
<value>Edit Envelope</value>
|
<value>Edit Envelope</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -165,6 +168,9 @@
|
|||||||
<data name="Envelope-Editor" xml:space="preserve">
|
<data name="Envelope-Editor" xml:space="preserve">
|
||||||
<value>Envelope-Editor</value>
|
<value>Envelope-Editor</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Error email Validation" xml:space="preserve">
|
||||||
|
<value>The email [ @Mail ] could not be varified!</value>
|
||||||
|
</data>
|
||||||
<data name="Error sending the envelope" xml:space="preserve">
|
<data name="Error sending the envelope" xml:space="preserve">
|
||||||
<value>Error sending the envelope:</value>
|
<value>Error sending the envelope:</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -186,6 +192,9 @@
|
|||||||
<data name="Invalid Email Address" xml:space="preserve">
|
<data name="Invalid Email Address" xml:space="preserve">
|
||||||
<value>Receiver {0} has an invalid Email Address.</value>
|
<value>Receiver {0} has an invalid Email Address.</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Invitation successfully resend" xml:space="preserve">
|
||||||
|
<value>Invitation has been send once again!</value>
|
||||||
|
</data>
|
||||||
<data name="Missing Documents" xml:space="preserve">
|
<data name="Missing Documents" xml:space="preserve">
|
||||||
<value>Missing Documents</value>
|
<value>Missing Documents</value>
|
||||||
</data>
|
</data>
|
||||||
|
|||||||
@@ -138,6 +138,9 @@
|
|||||||
<data name="Document Could Not Be Saved" xml:space="preserve">
|
<data name="Document Could Not Be Saved" xml:space="preserve">
|
||||||
<value>Dokument konnte nicht gespeichert werden!</value>
|
<value>Dokument konnte nicht gespeichert werden!</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Document forwarded" xml:space="preserve">
|
||||||
|
<value>Umschlag an Empfänger {0} weitergeleitet.</value>
|
||||||
|
</data>
|
||||||
<data name="Edit Envelope" xml:space="preserve">
|
<data name="Edit Envelope" xml:space="preserve">
|
||||||
<value>Bearbeite Umschlag</value>
|
<value>Bearbeite Umschlag</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -165,6 +168,9 @@
|
|||||||
<data name="Envelope-Editor" xml:space="preserve">
|
<data name="Envelope-Editor" xml:space="preserve">
|
||||||
<value>Umschlag-Editor</value>
|
<value>Umschlag-Editor</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Error email Validation" xml:space="preserve">
|
||||||
|
<value>Die Email-Adresse [ @Mail ] konnte nicht validiert werden!</value>
|
||||||
|
</data>
|
||||||
<data name="Error sending the envelope" xml:space="preserve">
|
<data name="Error sending the envelope" xml:space="preserve">
|
||||||
<value>Fehler beim Senden des Umschlags:</value>
|
<value>Fehler beim Senden des Umschlags:</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -186,6 +192,9 @@
|
|||||||
<data name="Invalid Email Address" xml:space="preserve">
|
<data name="Invalid Email Address" xml:space="preserve">
|
||||||
<value>Empfänger {0} hat keine gültige Email Addresse.</value>
|
<value>Empfänger {0} hat keine gültige Email Addresse.</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Invitation successfully resend" xml:space="preserve">
|
||||||
|
<value>Die Einladung wurde nochmal versendet!</value>
|
||||||
|
</data>
|
||||||
<data name="Missing Documents" xml:space="preserve">
|
<data name="Missing Documents" xml:space="preserve">
|
||||||
<value>Fehlendes Dokument</value>
|
<value>Fehlendes Dokument</value>
|
||||||
</data>
|
</data>
|
||||||
|
|||||||
@@ -127,6 +127,15 @@ Namespace My.Resources
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
'''<summary>
|
||||||
|
''' Sucht eine lokalisierte Zeichenfolge, die Umschlag an Empfänger {0} weitergeleitet. ähnelt.
|
||||||
|
'''</summary>
|
||||||
|
Public Shared ReadOnly Property Document_forwarded() As String
|
||||||
|
Get
|
||||||
|
Return ResourceManager.GetString("Document forwarded", resourceCulture)
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
'''<summary>
|
'''<summary>
|
||||||
''' Sucht eine lokalisierte Zeichenfolge, die Bearbeite Umschlag ähnelt.
|
''' Sucht eine lokalisierte Zeichenfolge, die Bearbeite Umschlag ähnelt.
|
||||||
'''</summary>
|
'''</summary>
|
||||||
@@ -208,6 +217,15 @@ Namespace My.Resources
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
'''<summary>
|
||||||
|
''' Sucht eine lokalisierte Zeichenfolge, die Die Email-Adresse [ @Mail ] konnte nicht validiert werden! ähnelt.
|
||||||
|
'''</summary>
|
||||||
|
Public Shared ReadOnly Property Error_email_Validation() As String
|
||||||
|
Get
|
||||||
|
Return ResourceManager.GetString("Error email Validation", resourceCulture)
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
'''<summary>
|
'''<summary>
|
||||||
''' Sucht eine lokalisierte Zeichenfolge, die Fehler beim Senden des Umschlags: ähnelt.
|
''' Sucht eine lokalisierte Zeichenfolge, die Fehler beim Senden des Umschlags: ähnelt.
|
||||||
'''</summary>
|
'''</summary>
|
||||||
@@ -271,6 +289,15 @@ Namespace My.Resources
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
'''<summary>
|
||||||
|
''' Sucht eine lokalisierte Zeichenfolge, die Die Einladung wurde nochmal versendet! ähnelt.
|
||||||
|
'''</summary>
|
||||||
|
Public Shared ReadOnly Property Invitation_successfully_resend() As String
|
||||||
|
Get
|
||||||
|
Return ResourceManager.GetString("Invitation successfully resend", resourceCulture)
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
'''<summary>
|
'''<summary>
|
||||||
''' Sucht eine lokalisierte Zeichenfolge, die Fehlendes Dokument ähnelt.
|
''' Sucht eine lokalisierte Zeichenfolge, die Fehlendes Dokument ähnelt.
|
||||||
'''</summary>
|
'''</summary>
|
||||||
|
|||||||
20
EnvelopeGenerator.Common/Strings/Model.Designer.vb
generated
20
EnvelopeGenerator.Common/Strings/Model.Designer.vb
generated
@@ -306,16 +306,16 @@ Namespace My.Resources
|
|||||||
Return ResourceManager.GetString("PartlySigned", resourceCulture)
|
Return ResourceManager.GetString("PartlySigned", resourceCulture)
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
'''<summary>
|
''''<summary>
|
||||||
''' Sucht eine lokalisierte Zeichenfolge, die Qualifizierte Signatur ähnelt.
|
'''' Sucht eine lokalisierte Zeichenfolge, die Qualifizierte Signatur ähnelt.
|
||||||
'''</summary>
|
''''</summary>
|
||||||
Public Shared ReadOnly Property QualifiedSignature() As String
|
'Public Shared ReadOnly Property QualifiedSignature() As String
|
||||||
Get
|
' Get
|
||||||
Return ResourceManager.GetString("QualifiedSignature", resourceCulture)
|
' Return ResourceManager.GetString("QualifiedSignature", resourceCulture)
|
||||||
End Get
|
' End Get
|
||||||
End Property
|
'End Property
|
||||||
|
|
||||||
'''<summary>
|
'''<summary>
|
||||||
''' Sucht eine lokalisierte Zeichenfolge, die Arbeitsanweisung ähnelt.
|
''' Sucht eine lokalisierte Zeichenfolge, die Arbeitsanweisung ähnelt.
|
||||||
'''</summary>
|
'''</summary>
|
||||||
|
|||||||
@@ -2,9 +2,6 @@
|
|||||||
<configuration>
|
<configuration>
|
||||||
|
|
||||||
<configSections>
|
<configSections>
|
||||||
<sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
|
|
||||||
<section name="EnvelopeGenerator.Common.My.MySettings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
|
|
||||||
</sectionGroup>
|
|
||||||
</configSections>
|
</configSections>
|
||||||
<system.diagnostics>
|
<system.diagnostics>
|
||||||
<sources>
|
<sources>
|
||||||
@@ -29,17 +26,4 @@
|
|||||||
</sharedListeners>
|
</sharedListeners>
|
||||||
</system.diagnostics>
|
</system.diagnostics>
|
||||||
|
|
||||||
<applicationSettings>
|
|
||||||
<EnvelopeGenerator.Common.My.MySettings>
|
|
||||||
<setting name="RuninDMZ" serializeAs="String">
|
|
||||||
<value>False</value>
|
|
||||||
</setting>
|
|
||||||
<setting name="NetUse_Usr" serializeAs="String">
|
|
||||||
<value>dd-gan\Administrator</value>
|
|
||||||
</setting>
|
|
||||||
<setting name="NetUse_PW" serializeAs="String">
|
|
||||||
<value>sY4vnATDXwosbTJGip6SqA==</value>
|
|
||||||
</setting>
|
|
||||||
</EnvelopeGenerator.Common.My.MySettings>
|
|
||||||
</applicationSettings>
|
|
||||||
</configuration>
|
</configuration>
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
|
<package id="GdPicture" version="14.2.89" targetFramework="net462" />
|
||||||
|
<package id="GdPicture.runtimes.windows" version="14.2.89" targetFramework="net462" />
|
||||||
<package id="Microsoft.Extensions.Logging.Abstractions" version="2.1.1" targetFramework="net462" />
|
<package id="Microsoft.Extensions.Logging.Abstractions" version="2.1.1" targetFramework="net462" />
|
||||||
<package id="Newtonsoft.Json" version="13.0.3" targetFramework="net462" />
|
<package id="Newtonsoft.Json" version="13.0.3" targetFramework="net462" />
|
||||||
<package id="Quartz" version="3.8.0" targetFramework="net462" />
|
<package id="Quartz" version="3.8.0" targetFramework="net462" />
|
||||||
|
|||||||
@@ -1,43 +1,32 @@
|
|||||||
using System.ComponentModel;
|
using DigitalData.Core.Abstractions;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
using System.Text.Json.Serialization;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_CONFIG", Schema = "dbo")]
|
[Table("TBSIG_CONFIG", Schema = "dbo")]
|
||||||
public class Config
|
public class Config : IUnique<int>
|
||||||
{
|
{
|
||||||
[Column("DOCUMENT_PATH", TypeName = "nvarchar(256)")]
|
[Column("DOCUMENT_PATH", TypeName = "nvarchar(256)")]
|
||||||
public string DocumentPath { get; set; }
|
public string? DocumentPath { get; init; }
|
||||||
|
|
||||||
[Column("SENDING_PROFILE", TypeName = "int")]
|
[Column("SENDING_PROFILE", TypeName = "int")]
|
||||||
[Required]
|
[Required]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.None)] // Assuming SENDING_PROFILE is manually entered or controlled by the application logic
|
public required int SendingProfile { get; init; }
|
||||||
[DefaultValue(0)] // This sets the default value for SENDING_PROFILE
|
|
||||||
public int SendingProfile { get; set; }
|
|
||||||
|
|
||||||
[Column("SIGNATURE_HOST", TypeName = "nvarchar(128)")]
|
[Column("SIGNATURE_HOST", TypeName = "nvarchar(128)")]
|
||||||
public string SignatureHost { get; set; }
|
public string? SignatureHost { get; init; }
|
||||||
|
|
||||||
[Column("EXTERNAL_PROGRAM_NAME", TypeName = "nvarchar(30)")]
|
[Column("EXTERNAL_PROGRAM_NAME", TypeName = "nvarchar(30)")]
|
||||||
public string ExternalProgramName { get; set; }
|
public string? ExternalProgramName { get; init; }
|
||||||
|
|
||||||
[Column("EXPORT_PATH", TypeName = "nvarchar(256)")]
|
[Column("EXPORT_PATH", TypeName = "nvarchar(256)")]
|
||||||
public string ExportPath { get; set; }
|
public string? ExportPath { get; init; }
|
||||||
|
|
||||||
[Column("DOCUMENT_PATH_DMZ", TypeName = "nvarchar(512)")]
|
[Obsolete("Configuration does not have an ID; it represents a single table in the database.")]
|
||||||
[Required]
|
[NotMapped]
|
||||||
[DefaultValue("")] // This sets the default value for DOCUMENT_PATH_DMZ
|
[JsonIgnore]
|
||||||
public string DocumentPathDmz { get; set; }
|
public int Id => throw new InvalidOperationException("This configuration does not support an ID as it represents a single table in the database.");
|
||||||
|
|
||||||
[Column("EXPORT_PATH_DMZ", TypeName = "nvarchar(512)")]
|
|
||||||
[Required]
|
|
||||||
[DefaultValue("")] // This sets the default value for EXPORT_PATH_DMZ
|
|
||||||
public string ExportPathDmz { get; set; }
|
|
||||||
|
|
||||||
[Column("DOCUMENT_PATH_MOVE_AFTSEND", TypeName = "nvarchar(512)")]
|
|
||||||
[Required]
|
|
||||||
[DefaultValue("")] // This sets the default value for DOCUMENT_PATH_MOVE_AFTSEND
|
|
||||||
public string DocumentPathMoveAftsend { get; set; }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,11 +1,12 @@
|
|||||||
using System.ComponentModel;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_DOCUMENT_RECEIVER_ELEMENT", Schema = "dbo")]
|
[Table("TBSIG_DOCUMENT_RECEIVER_ELEMENT", Schema = "dbo")]
|
||||||
public class DocumentReceiverElement
|
public class DocumentReceiverElement : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
using System.ComponentModel.DataAnnotations;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_DOCUMENT_STATUS", Schema = "dbo")]
|
[Table("TBSIG_DOCUMENT_STATUS", Schema = "dbo")]
|
||||||
public class DocumentStatus
|
public class DocumentStatus : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -27,7 +28,7 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
public DateTime? StatusChangedWhen { get; set; }
|
public DateTime? StatusChangedWhen { get; set; }
|
||||||
|
|
||||||
[Column("VALUE", TypeName = "nvarchar(max)")]
|
[Column("VALUE", TypeName = "nvarchar(max)")]
|
||||||
public string Value { get; set; }
|
public string? Value { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("ADDED_WHEN", TypeName = "datetime")]
|
[Column("ADDED_WHEN", TypeName = "datetime")]
|
||||||
@@ -42,4 +43,4 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
[ForeignKey("ReceiverId")]
|
[ForeignKey("ReceiverId")]
|
||||||
public virtual Receiver? Receiver { get; set; }
|
public virtual Receiver? Receiver { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,10 +1,11 @@
|
|||||||
using System.ComponentModel.DataAnnotations;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_EMAIL_TEMPLATE", Schema = "dbo")]
|
[Table("TBSIG_EMAIL_TEMPLATE", Schema = "dbo")]
|
||||||
public class EmailTemplate
|
public class EmailTemplate : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -12,12 +13,12 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
public int Id { get; set; }
|
public int Id { get; set; }
|
||||||
|
|
||||||
[Column("NAME", TypeName = "nvarchar(64)")]
|
[Column("NAME", TypeName = "nvarchar(64)")]
|
||||||
public string Name { get; set; }
|
public string? Name { get; set; }
|
||||||
|
|
||||||
[Column("BODY", TypeName = "nvarchar(max)")]
|
[Column("BODY", TypeName = "nvarchar(max)")]
|
||||||
public string Body { get; set; }
|
public string? Body { get; set; }
|
||||||
|
|
||||||
[Column("SUBJECT", TypeName = "nvarchar(512)")]
|
[Column("SUBJECT", TypeName = "nvarchar(512)")]
|
||||||
public string Subject { get; set; }
|
public string? Subject { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,12 +1,12 @@
|
|||||||
using EnvelopeGenerator.Common;
|
using DigitalData.Core.Abstractions;
|
||||||
using EnvelopeGenerator.Common.My.Resources;
|
using EnvelopeGenerator.Common;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_ENVELOPE", Schema = "dbo")]
|
[Table("TBSIG_ENVELOPE", Schema = "dbo")]
|
||||||
public class Envelope
|
public class Envelope : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -26,11 +26,11 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("ENVELOPE_UUID", TypeName = "nvarchar(36)")]
|
[Column("ENVELOPE_UUID", TypeName = "nvarchar(36)")]
|
||||||
public string Uuid { get; set; }
|
public required string Uuid { get; init; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("MESSAGE", TypeName = "nvarchar(max)")]
|
[Column("MESSAGE", TypeName = "nvarchar(max)")]
|
||||||
public string Message { get; set; }
|
public string? Message { get; set; }
|
||||||
|
|
||||||
[Column("EXPIRES_WHEN", TypeName = "datetime")]
|
[Column("EXPIRES_WHEN", TypeName = "datetime")]
|
||||||
public DateTime? ExpiresWhen { get; set; }
|
public DateTime? ExpiresWhen { get; set; }
|
||||||
@@ -46,13 +46,13 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
public DateTime? ChangedWhen { get; set; }
|
public DateTime? ChangedWhen { get; set; }
|
||||||
|
|
||||||
[Column("TITLE", TypeName = "nvarchar(128)")]
|
[Column("TITLE", TypeName = "nvarchar(128)")]
|
||||||
public string Title { get; set; }
|
public string? Title { get; set; }
|
||||||
|
|
||||||
[Column("CONTRACT_TYPE")]
|
[Column("CONTRACT_TYPE")]
|
||||||
public int? ContractType { get; set; }
|
public int? ContractType { get; set; }
|
||||||
|
|
||||||
[Column("LANGUAGE", TypeName = "nvarchar(5)")]
|
[Column("LANGUAGE", TypeName = "nvarchar(5)")]
|
||||||
public string Language { get; set; }
|
public required string Language { get; set; }
|
||||||
|
|
||||||
[Column("SEND_REMINDER_EMAILS")]
|
[Column("SEND_REMINDER_EMAILS")]
|
||||||
public bool? SendReminderEmails { get; set; }
|
public bool? SendReminderEmails { get; set; }
|
||||||
@@ -84,10 +84,6 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
[Column("EXPIRES_WARNING_WHEN_DAYS")]
|
[Column("EXPIRES_WARNING_WHEN_DAYS")]
|
||||||
public int? ExpiresWarningWhenDays { get; set; }
|
public int? ExpiresWarningWhenDays { get; set; }
|
||||||
|
|
||||||
[Required]
|
|
||||||
[Column("DMZ_MOVED")]
|
|
||||||
public bool DmzMoved { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The sender of envelope
|
/// The sender of envelope
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
using System.ComponentModel.DataAnnotations;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_ENVELOPE_CERTIFICATE", Schema = "dbo")]
|
[Table("TBSIG_ENVELOPE_CERTIFICATE", Schema = "dbo")]
|
||||||
public class EnvelopeCertificate
|
public class EnvelopeCertificate : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -17,11 +18,11 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("ENVELOPE_UUID", TypeName = "nvarchar(36)")]
|
[Column("ENVELOPE_UUID", TypeName = "nvarchar(36)")]
|
||||||
public string EnvelopeUuid { get; set; }
|
public required string EnvelopeUuid { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("ENVELOPE_SUBJECT", TypeName = "nvarchar(512)")]
|
[Column("ENVELOPE_SUBJECT", TypeName = "nvarchar(512)")]
|
||||||
public string EnvelopeSubject { get; set; }
|
public required string EnvelopeSubject { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("CREATOR_ID")]
|
[Column("CREATOR_ID")]
|
||||||
@@ -29,11 +30,11 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("CREATOR_NAME", TypeName = "nvarchar(128)")]
|
[Column("CREATOR_NAME", TypeName = "nvarchar(128)")]
|
||||||
public string CreatorName { get; set; }
|
public required string CreatorName { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("CREATOR_EMAIL", TypeName = "nvarchar(128)")]
|
[Column("CREATOR_EMAIL", TypeName = "nvarchar(128)")]
|
||||||
public string CreatorEmail { get; set; }
|
public required string CreatorEmail { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("ENVELOPE_STATUS")]
|
[Column("ENVELOPE_STATUS")]
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
using System.ComponentModel.DataAnnotations;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_ENVELOPE_DOCUMENT", Schema = "dbo")]
|
[Table("TBSIG_ENVELOPE_DOCUMENT", Schema = "dbo")]
|
||||||
public class EnvelopeDocument
|
public class EnvelopeDocument : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -15,20 +16,12 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
[Column("ENVELOPE_ID")]
|
[Column("ENVELOPE_ID")]
|
||||||
public int EnvelopeId { get; set; }
|
public int EnvelopeId { get; set; }
|
||||||
|
|
||||||
[Required]
|
|
||||||
[Column("FILENAME", TypeName = "nvarchar(256)")]
|
|
||||||
public string Filename { get; set; }
|
|
||||||
|
|
||||||
[Required]
|
|
||||||
[Column("FILEPATH", TypeName = "nvarchar(256)")]
|
|
||||||
public string Filepath { get; set; }
|
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("ADDED_WHEN", TypeName = "datetime")]
|
[Column("ADDED_WHEN", TypeName = "datetime")]
|
||||||
public DateTime AddedWhen { get; set; }
|
public required DateTime AddedWhen { get; set; }
|
||||||
|
|
||||||
[Column("FILENAME_ORIGINAL", TypeName = "nvarchar(256)")]
|
[Column("BYTE_DATA", TypeName = "varbinary(max)")]
|
||||||
public string FilenameOriginal { get; set; }
|
public byte[]? ByteData { get; init; }
|
||||||
|
|
||||||
public IEnumerable<DocumentReceiverElement>? Elements { get; set; }
|
public IEnumerable<DocumentReceiverElement>? Elements { get; set; }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
using DigitalData.UserManager.Domain.Entities;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using DigitalData.UserManager.Domain.Entities;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
using static EnvelopeGenerator.Common.Constants;
|
using static EnvelopeGenerator.Common.Constants;
|
||||||
@@ -6,7 +7,7 @@ using static EnvelopeGenerator.Common.Constants;
|
|||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_ENVELOPE_HISTORY", Schema = "dbo")]
|
[Table("TBSIG_ENVELOPE_HISTORY", Schema = "dbo")]
|
||||||
public class EnvelopeHistory
|
public class EnvelopeHistory : IUnique<long>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -19,7 +20,7 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("USER_REFERENCE", TypeName = "nvarchar(128)")]
|
[Column("USER_REFERENCE", TypeName = "nvarchar(128)")]
|
||||||
public string UserReference { get; set; }
|
public required string UserReference { get; init; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("STATUS")]
|
[Column("STATUS")]
|
||||||
@@ -43,11 +44,17 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
public virtual Receiver? Receiver { get; set; }
|
public virtual Receiver? Receiver { get; set; }
|
||||||
|
|
||||||
[NotMapped]
|
[NotMapped]
|
||||||
public ReferenceType ReferenceType => (Status / 3) switch
|
public ReferenceType ReferenceType => (Status / 1000) switch
|
||||||
{
|
{
|
||||||
1 => ReferenceType.Sender,
|
1 => ReferenceType.Sender,
|
||||||
2 or 3 => ReferenceType.Receiver,
|
2 or 3 => ReferenceType.Receiver,
|
||||||
_ => ReferenceType.Unknown,
|
_ => ReferenceType.Unknown,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
[NotMapped]
|
||||||
|
public string? StatusName
|
||||||
|
=> (Enum.IsDefined(typeof(EnvelopeStatus), Status))
|
||||||
|
? Enum.GetName(typeof(EnvelopeStatus), Status)
|
||||||
|
: null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,45 +1,10 @@
|
|||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_ENVELOPE_RECEIVER", Schema = "dbo")]
|
[Table("TBSIG_ENVELOPE_RECEIVER", Schema = "dbo")]
|
||||||
public class EnvelopeReceiver
|
public class EnvelopeReceiver : EnvelopeReceiverBase
|
||||||
{
|
{
|
||||||
[Key]
|
|
||||||
[Column("ENVELOPE_ID")]
|
|
||||||
public int EnvelopeId { get; set; }
|
|
||||||
|
|
||||||
[Key]
|
|
||||||
[Column("RECEIVER_ID")]
|
|
||||||
public int ReceiverId { get; set; }
|
|
||||||
|
|
||||||
[Required]
|
|
||||||
[Column("SEQUENCE")]
|
|
||||||
public int Sequence { get; set; }
|
|
||||||
|
|
||||||
[Column("NAME", TypeName = "nvarchar(128)")]
|
|
||||||
public string? Name { get; set; }
|
|
||||||
|
|
||||||
[Column("JOB_TITLE", TypeName = "nvarchar(128)")]
|
|
||||||
public string? JobTitle { get; set; }
|
|
||||||
|
|
||||||
[Column("COMPANY_NAME", TypeName = "nvarchar(128)")]
|
|
||||||
public string? CompanyName { get; set; }
|
|
||||||
|
|
||||||
[Column("PRIVATE_MESSAGE", TypeName = "nvarchar(max)")]
|
|
||||||
public string? PrivateMessage { get; set; }
|
|
||||||
|
|
||||||
[Column("ACCESS_CODE", TypeName = "nvarchar(64)")]
|
|
||||||
public string? AccessCode { get; set; }
|
|
||||||
|
|
||||||
[Required]
|
|
||||||
[Column("ADDED_WHEN", TypeName = "datetime")]
|
|
||||||
public DateTime AddedWhen { get; set; }
|
|
||||||
|
|
||||||
[Column("CHANGED_WHEN", TypeName = "datetime")]
|
|
||||||
public DateTime? ChangedWhen { get; set; }
|
|
||||||
|
|
||||||
[ForeignKey("EnvelopeId")]
|
[ForeignKey("EnvelopeId")]
|
||||||
public Envelope? Envelope { get; set; }
|
public Envelope? Envelope { get; set; }
|
||||||
|
|
||||||
|
|||||||
46
EnvelopeGenerator.Domain/Entities/EnvelopeReceiverBase.cs
Normal file
46
EnvelopeGenerator.Domain/Entities/EnvelopeReceiverBase.cs
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
|
{
|
||||||
|
[Table("TBSIG_ENVELOPE_RECEIVER", Schema = "dbo")]
|
||||||
|
public class EnvelopeReceiverBase : IUnique<(int Envelope, int Receiver)>
|
||||||
|
{
|
||||||
|
[Key]
|
||||||
|
[Column("ENVELOPE_ID")]
|
||||||
|
public int EnvelopeId { get; set; }
|
||||||
|
|
||||||
|
[Key]
|
||||||
|
[Column("RECEIVER_ID")]
|
||||||
|
public int ReceiverId { get; set; }
|
||||||
|
|
||||||
|
[Required]
|
||||||
|
[Column("SEQUENCE")]
|
||||||
|
public int Sequence { get; set; }
|
||||||
|
|
||||||
|
[Column("NAME", TypeName = "nvarchar(128)")]
|
||||||
|
public string? Name { get; set; }
|
||||||
|
|
||||||
|
[Column("JOB_TITLE", TypeName = "nvarchar(128)")]
|
||||||
|
public string? JobTitle { get; set; }
|
||||||
|
|
||||||
|
[Column("COMPANY_NAME", TypeName = "nvarchar(128)")]
|
||||||
|
public string? CompanyName { get; set; }
|
||||||
|
|
||||||
|
[Column("PRIVATE_MESSAGE", TypeName = "nvarchar(max)")]
|
||||||
|
public string? PrivateMessage { get; set; }
|
||||||
|
|
||||||
|
[Column("ACCESS_CODE", TypeName = "nvarchar(64)")]
|
||||||
|
public string? AccessCode { get; set; }
|
||||||
|
|
||||||
|
[Required]
|
||||||
|
[Column("ADDED_WHEN", TypeName = "datetime")]
|
||||||
|
public DateTime AddedWhen { get; set; }
|
||||||
|
|
||||||
|
[Column("CHANGED_WHEN", TypeName = "datetime")]
|
||||||
|
public DateTime? ChangedWhen { get; set; }
|
||||||
|
|
||||||
|
public (int Envelope, int Receiver) Id => (Envelope: EnvelopeId, Receiver: ReceiverId);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,52 @@
|
|||||||
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using DigitalData.Core.Abstractions;
|
||||||
|
using DigitalData.EmailProfilerDispatcher.Abstraction.Attributes;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
|
{
|
||||||
|
[Table("TBSIG_ENVELOPE_RECEIVER_READ_ONLY")]
|
||||||
|
public class EnvelopeReceiverReadOnly : IUnique<long>
|
||||||
|
{
|
||||||
|
[Key]
|
||||||
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
|
[Column("GUID")]
|
||||||
|
public long Id { get; init; }
|
||||||
|
|
||||||
|
[Column("ENVELOPE_ID")]
|
||||||
|
[Required]
|
||||||
|
public long EnvelopeId { get; init; }
|
||||||
|
|
||||||
|
//TODO: remove NotMapped attribute when EnvelopeId data type is standardized
|
||||||
|
[NotMapped]
|
||||||
|
public Envelope? Envelope { get; set; }
|
||||||
|
|
||||||
|
[Column("RECEIVER_MAIL")]
|
||||||
|
[Required]
|
||||||
|
[StringLength(250)]
|
||||||
|
[TemplatePlaceholder("NAME_RECEIVER")]
|
||||||
|
public required string ReceiverMail { get; init; }
|
||||||
|
|
||||||
|
[Column("DATE_VALID")]
|
||||||
|
[Required]
|
||||||
|
public DateTime DateValid { get; init; }
|
||||||
|
|
||||||
|
[Column("ADDED_WHO")]
|
||||||
|
[Required]
|
||||||
|
[StringLength(100)]
|
||||||
|
public required string AddedWho { get; init; }
|
||||||
|
|
||||||
|
public Receiver? Receiver { get; init; }
|
||||||
|
|
||||||
|
[Column("ADDED_WHEN")]
|
||||||
|
[Required]
|
||||||
|
public DateTime AddedWhen { get; init; }
|
||||||
|
|
||||||
|
[Column("CHANGED_WHO")]
|
||||||
|
[StringLength(100)]
|
||||||
|
public string? ChangedWho { get; init; }
|
||||||
|
|
||||||
|
[Column("CHANGED_WHEN")]
|
||||||
|
public DateTime? ChangedWhen { get; init; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,12 +1,11 @@
|
|||||||
using System;
|
using DigitalData.Core.Abstractions;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_ENVELOPE_TYPE", Schema = "dbo")]
|
[Table("TBSIG_ENVELOPE_TYPE", Schema = "dbo")]
|
||||||
public class EnvelopeType
|
public class EnvelopeType : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -15,10 +14,10 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("TITLE", TypeName = "nvarchar(128)")]
|
[Column("TITLE", TypeName = "nvarchar(128)")]
|
||||||
public string Title { get; set; }
|
public required string Title { get; set; }
|
||||||
|
|
||||||
[Column("LANGUAGE", TypeName = "nvarchar(5)")]
|
[Column("LANGUAGE", TypeName = "nvarchar(5)")]
|
||||||
public string Language { get; set; }
|
public string? Language { get; set; }
|
||||||
|
|
||||||
[Column("EXPIRES_DAYS")]
|
[Column("EXPIRES_DAYS")]
|
||||||
public int? ExpiresDays { get; set; }
|
public int? ExpiresDays { get; set; }
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
using System.ComponentModel.DataAnnotations;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_RECEIVER", Schema = "dbo")]
|
[Table("TBSIG_RECEIVER", Schema = "dbo")]
|
||||||
public class Receiver
|
public class Receiver : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -22,5 +23,7 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
[Required]
|
[Required]
|
||||||
[Column("ADDED_WHEN", TypeName = "datetime")]
|
[Column("ADDED_WHEN", TypeName = "datetime")]
|
||||||
public DateTime AddedWhen { get; set; }
|
public DateTime AddedWhen { get; set; }
|
||||||
|
|
||||||
|
public IEnumerable<EnvelopeReceiver>? EnvelopeReceivers { get; init; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,10 +1,11 @@
|
|||||||
using System.ComponentModel.DataAnnotations;
|
using DigitalData.Core.Abstractions;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Domain.Entities
|
namespace EnvelopeGenerator.Domain.Entities
|
||||||
{
|
{
|
||||||
[Table("TBSIG_USER_RECEIVER", Schema = "dbo")]
|
[Table("TBSIG_USER_RECEIVER", Schema = "dbo")]
|
||||||
public class UserReceiver
|
public class UserReceiver : IUnique<int>
|
||||||
{
|
{
|
||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
@@ -21,16 +22,16 @@ namespace EnvelopeGenerator.Domain.Entities
|
|||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("NAME", TypeName = "nvarchar(128)")]
|
[Column("NAME", TypeName = "nvarchar(128)")]
|
||||||
public string Name { get; set; }
|
public required string Name { get; set; }
|
||||||
|
|
||||||
[Column("COMPANY_NAME", TypeName = "nvarchar(128)")]
|
[Column("COMPANY_NAME", TypeName = "nvarchar(128)")]
|
||||||
public string CompanyName { get; set; }
|
public string? CompanyName { get; set; }
|
||||||
|
|
||||||
[Column("JOB_TITLE", TypeName = "nvarchar(128)")]
|
[Column("JOB_TITLE", TypeName = "nvarchar(128)")]
|
||||||
public string JobTitle { get; set; }
|
public string? JobTitle { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
[Column("ADDED_WHEN", TypeName = "datetime")]
|
[Column("ADDED_WHEN", TypeName = "datetime")]
|
||||||
public DateTime AddedWhen { get; set; }
|
public required DateTime AddedWhen { get; init; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -7,6 +7,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<PackageReference Include="DigitalData.Core.Abstractions" Version="2.2.1" />
|
||||||
<PackageReference Include="DigitalData.EmailProfilerDispatcher.Abstraction" Version="1.0.0" />
|
<PackageReference Include="DigitalData.EmailProfilerDispatcher.Abstraction" Version="1.0.0" />
|
||||||
<PackageReference Include="UserManager.Domain" Version="1.0.0" />
|
<PackageReference Include="UserManager.Domain" Version="1.0.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|||||||
@@ -1,12 +1,9 @@
|
|||||||
using Microsoft.Extensions.Logging;
|
using System.Text;
|
||||||
using System.Text;
|
using static EnvelopeGenerator.Common.Constants;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Application
|
namespace EnvelopeGenerator.Extensions
|
||||||
{
|
{
|
||||||
/// <summary>
|
public static class DecodingExtensions
|
||||||
/// Provides extension methods for decoding and extracting information from an envelope receiver ID.
|
|
||||||
/// </summary>
|
|
||||||
public static class EnvelopeGeneratorExtensions
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Validates whether a given string is a correctly formatted Base-64 encoded string.
|
/// Validates whether a given string is a correctly formatted Base-64 encoded string.
|
||||||
@@ -67,6 +64,40 @@ namespace EnvelopeGenerator.Application
|
|||||||
return input.IndexOf('=') == -1; // No padding allowed except at the end
|
return input.IndexOf('=') == -1; // No padding allowed except at the end
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static bool TryDecode(this string encodedKey, out string[] decodedKeys)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
byte[] bytes = Convert.FromBase64String(encodedKey);
|
||||||
|
string decodedString = Encoding.UTF8.GetString(bytes);
|
||||||
|
decodedKeys = decodedString.Split(new string[] { "::" }, StringSplitOptions.None);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
catch(ArgumentNullException) { }
|
||||||
|
catch (FormatException) { }
|
||||||
|
catch(ArgumentException) { }
|
||||||
|
|
||||||
|
decodedKeys = Array.Empty<string>();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static EncodeType GetEncodeType(this string[] decodedKeys) => decodedKeys.Length switch
|
||||||
|
{
|
||||||
|
2 => EncodeType.EnvelopeReceiver,
|
||||||
|
3 => long.TryParse(decodedKeys[1], out var _) ? EncodeType.EnvelopeReceiverReadOnly : EncodeType.Undefined,
|
||||||
|
_ => EncodeType.Undefined,
|
||||||
|
};
|
||||||
|
|
||||||
|
public static (string? EnvelopeUuid, string? ReceiverSignature) ParseEnvelopeReceiverId(this string[] decodedKeys)
|
||||||
|
=> decodedKeys.GetEncodeType() == EncodeType.EnvelopeReceiver
|
||||||
|
? (EnvelopeUuid: decodedKeys[0], ReceiverSignature: decodedKeys[1])
|
||||||
|
: throw new InvalidOperationException("Attempted to convert a decoded other than type EnvelopeReceiver to EnvelopeReceiver.");
|
||||||
|
|
||||||
|
public static long ParseReadOnlyId(this string[] decodedKeys)
|
||||||
|
=> decodedKeys.GetEncodeType() == EncodeType.EnvelopeReceiverReadOnly
|
||||||
|
? long.Parse(decodedKeys[1])
|
||||||
|
: throw new InvalidOperationException("Attempted to convert a decoded other than type EnvelopeReceiver to EnvelopeReceiver. ");
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Decodes the envelope receiver ID and extracts the envelope UUID and receiver signature.
|
/// Decodes the envelope receiver ID and extracts the envelope UUID and receiver signature.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -79,7 +110,7 @@ namespace EnvelopeGenerator.Application
|
|||||||
return (null, null);
|
return (null, null);
|
||||||
}
|
}
|
||||||
byte[] bytes = Convert.FromBase64String(envelopeReceiverId);
|
byte[] bytes = Convert.FromBase64String(envelopeReceiverId);
|
||||||
string decodedString = System.Text.Encoding.UTF8.GetString(bytes);
|
string decodedString = Encoding.UTF8.GetString(bytes);
|
||||||
string[] parts = decodedString.Split(new string[] { "::" }, StringSplitOptions.None);
|
string[] parts = decodedString.Split(new string[] { "::" }, StringSplitOptions.None);
|
||||||
|
|
||||||
if (parts.Length > 1)
|
if (parts.Length > 1)
|
||||||
@@ -88,6 +119,22 @@ namespace EnvelopeGenerator.Application
|
|||||||
return (string.Empty, string.Empty);
|
return (string.Empty, string.Empty);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static long? DecodeEnvelopeReceiverReadOnlyId(this string envelopeReceiverReadOnlyId)
|
||||||
|
{
|
||||||
|
if (!envelopeReceiverReadOnlyId.IsBase64String())
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
byte[] bytes = Convert.FromBase64String(envelopeReceiverReadOnlyId);
|
||||||
|
string decodedString = System.Text.Encoding.UTF8.GetString(bytes);
|
||||||
|
string[] parts = decodedString.Split(new string[] { "::" }, StringSplitOptions.None);
|
||||||
|
|
||||||
|
if (parts.Length > 2)
|
||||||
|
return long.TryParse(parts[1], out long readOnlyId) ? readOnlyId : null;
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets the envelope UUID from the decoded envelope receiver ID.
|
/// Gets the envelope UUID from the decoded envelope receiver ID.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -101,48 +148,5 @@ namespace EnvelopeGenerator.Application
|
|||||||
/// <param name="envelopeReceiverId">The base64 encoded string to decode.</param>
|
/// <param name="envelopeReceiverId">The base64 encoded string to decode.</param>
|
||||||
/// <returns>The receiver signature.</returns>
|
/// <returns>The receiver signature.</returns>
|
||||||
public static string? GetReceiverSignature(this string envelopeReceiverId) => envelopeReceiverId.DecodeEnvelopeReceiverId().ReceiverSignature;
|
public static string? GetReceiverSignature(this string envelopeReceiverId) => envelopeReceiverId.DecodeEnvelopeReceiverId().ReceiverSignature;
|
||||||
|
|
||||||
public static string EncodeEnvelopeReceiverId(this (string envelopeUuid, string receiverSignature) input)
|
|
||||||
{
|
|
||||||
string combinedString = $"{input.envelopeUuid}::{input.receiverSignature}";
|
|
||||||
byte[] bytes = Encoding.UTF8.GetBytes(combinedString);
|
|
||||||
string base64String = Convert.ToBase64String(bytes);
|
|
||||||
|
|
||||||
return base64String;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void LogEnvelopeError(this ILogger logger, string envelopeReceiverId, Exception? exception = null, string? message = null, params object?[] args)
|
|
||||||
{
|
|
||||||
var sb = new StringBuilder().AppendLine(envelopeReceiverId.DecodeEnvelopeReceiverId().ToTitle());
|
|
||||||
|
|
||||||
if (message is not null)
|
|
||||||
sb.AppendLine(message);
|
|
||||||
|
|
||||||
if(exception is null)
|
|
||||||
logger.Log(LogLevel.Error, sb.ToString(), args);
|
|
||||||
else
|
|
||||||
logger.Log(LogLevel.Error, exception, sb.AppendLine(exception.Message).ToString(), args);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void LogEnvelopeError(this ILogger logger, string? uuid, string? signature = null, Exception? exception = null, string? message = null, params object?[] args)
|
|
||||||
{
|
|
||||||
var sb = new StringBuilder($"Envelope Uuid: {uuid}");
|
|
||||||
|
|
||||||
if(signature is not null)
|
|
||||||
sb.AppendLine().Append($"Receiver Signature: {signature}");
|
|
||||||
|
|
||||||
if (message is not null)
|
|
||||||
sb.AppendLine().Append(message);
|
|
||||||
|
|
||||||
if (exception is null)
|
|
||||||
logger.Log(LogLevel.Error, sb.ToString(), args);
|
|
||||||
else
|
|
||||||
logger.Log(LogLevel.Error, exception, sb.ToString(), args);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static string ToTitle(this (string? UUID, string? Signature) envelopeReceiverTuple)
|
|
||||||
{
|
|
||||||
return $"UUID is {envelopeReceiverTuple.UUID} and signature is {envelopeReceiverTuple.Signature}";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
30
EnvelopeGenerator.Extensions/EncodingExtensions.cs
Normal file
30
EnvelopeGenerator.Extensions/EncodingExtensions.cs
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Extensions
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Provides extension methods for decoding and extracting information from an envelope receiver ID.
|
||||||
|
/// </summary>
|
||||||
|
public static class EncodingExtensions
|
||||||
|
{
|
||||||
|
public static string EncodeEnvelopeReceiverId(this long readOnlyId)
|
||||||
|
{
|
||||||
|
//The random number is used as a salt to increase security but it is not saved in the database.
|
||||||
|
string combinedString = $"{Random.Shared.Next()}::{readOnlyId}::{Random.Shared.Next()}";
|
||||||
|
byte[] bytes = Encoding.UTF8.GetBytes(combinedString);
|
||||||
|
string base64String = Convert.ToBase64String(bytes);
|
||||||
|
|
||||||
|
return base64String;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static string EncodeEnvelopeReceiverId(this (string envelopeUuid, string receiverSignature) input)
|
||||||
|
{
|
||||||
|
string combinedString = $"{input.envelopeUuid}::{input.receiverSignature}";
|
||||||
|
byte[] bytes = Encoding.UTF8.GetBytes(combinedString);
|
||||||
|
string base64String = Convert.ToBase64String(bytes);
|
||||||
|
|
||||||
|
return base64String;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>net7.0</TargetFramework>
|
||||||
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
|
<Nullable>enable</Nullable>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="HtmlSanitizer" Version="8.0.865" />
|
||||||
|
<PackageReference Include="Microsoft.Extensions.Localization.Abstractions" Version="7.0.19" />
|
||||||
|
<PackageReference Include="Microsoft.Extensions.Logging" Version="8.0.0" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\EnvelopeGenerator.Common\EnvelopeGenerator.Common.vbproj" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
</Project>
|
||||||
42
EnvelopeGenerator.Extensions/LoggerExtensions.cs
Normal file
42
EnvelopeGenerator.Extensions/LoggerExtensions.cs
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace EnvelopeGenerator.Extensions
|
||||||
|
{
|
||||||
|
public static class LoggerExtensions
|
||||||
|
{
|
||||||
|
public static void LogEnvelopeError(this ILogger logger, string envelopeReceiverId, Exception? exception = null, string? message = null, params object?[] args)
|
||||||
|
{
|
||||||
|
var sb = new StringBuilder().AppendLine(envelopeReceiverId.DecodeEnvelopeReceiverId().ToTitle());
|
||||||
|
|
||||||
|
if (message is not null)
|
||||||
|
sb.AppendLine(message);
|
||||||
|
|
||||||
|
if (exception is null)
|
||||||
|
logger.Log(LogLevel.Error, sb.ToString(), args);
|
||||||
|
else
|
||||||
|
logger.Log(LogLevel.Error, exception, sb.AppendLine(exception.Message).ToString(), args);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void LogEnvelopeError(this ILogger logger, string? uuid, string? signature = null, Exception? exception = null, string? message = null, params object?[] args)
|
||||||
|
{
|
||||||
|
var sb = new StringBuilder($"Envelope Uuid: {uuid}");
|
||||||
|
|
||||||
|
if (signature is not null)
|
||||||
|
sb.AppendLine().Append($"Receiver Signature: {signature}");
|
||||||
|
|
||||||
|
if (message is not null)
|
||||||
|
sb.AppendLine().Append(message);
|
||||||
|
|
||||||
|
if (exception is null)
|
||||||
|
logger.Log(LogLevel.Error, sb.ToString(), args);
|
||||||
|
else
|
||||||
|
logger.Log(LogLevel.Error, exception, sb.ToString(), args);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static string ToTitle(this (string? UUID, string? Signature) envelopeReceiverTuple)
|
||||||
|
{
|
||||||
|
return $"UUID is {envelopeReceiverTuple.UUID} and signature is {envelopeReceiverTuple.Signature}";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
using Microsoft.Extensions.Localization;
|
using Microsoft.Extensions.Localization;
|
||||||
using System.Text.Encodings.Web;
|
using System.Text.Encodings.Web;
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Web
|
namespace EnvelopeGenerator.Extensions
|
||||||
{
|
{
|
||||||
public static class XSSExtensions
|
public static class XSSExtensions
|
||||||
{
|
{
|
||||||
@@ -158,6 +158,7 @@ Public Class EnvelopeEditorController
|
|||||||
Dim oTempFilePath = Path.Combine(oTempFiles.TempPath, Guid.NewGuid().ToString + oFileInfo.Extension)
|
Dim oTempFilePath = Path.Combine(oTempFiles.TempPath, Guid.NewGuid().ToString + oFileInfo.Extension)
|
||||||
|
|
||||||
Await Helpers.CopyFileAsync(oFileInfo.FullName, oTempFilePath)
|
Await Helpers.CopyFileAsync(oFileInfo.FullName, oTempFilePath)
|
||||||
|
|
||||||
'File.Copy(oFileInfo.FullName, oTempFilePath, True)
|
'File.Copy(oFileInfo.FullName, oTempFilePath, True)
|
||||||
|
|
||||||
Dim oFileInfoTemp = New FileInfo(oTempFilePath)
|
Dim oFileInfoTemp = New FileInfo(oTempFilePath)
|
||||||
@@ -175,6 +176,7 @@ Public Class EnvelopeEditorController
|
|||||||
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
Logger.Error(ex)
|
Logger.Error(ex)
|
||||||
|
Logger.Warn($"error in CreateDocument: {ex.Message}")
|
||||||
Return Nothing
|
Return Nothing
|
||||||
End Try
|
End Try
|
||||||
End Function
|
End Function
|
||||||
@@ -288,7 +290,9 @@ Public Class EnvelopeEditorController
|
|||||||
#End Region
|
#End Region
|
||||||
Private Function GetEnvelopePath(pEnvelope As Envelope) As String
|
Private Function GetEnvelopePath(pEnvelope As Envelope) As String
|
||||||
Try
|
Try
|
||||||
Dim oEnvelopePath As String = Path.Combine(State.DbConfig.DocumentPath, pEnvelope.Uuid)
|
Dim oTempFiles As New TempFiles(State.LogConfig)
|
||||||
|
Dim oTempFolderPath = oTempFiles.TempPath
|
||||||
|
Dim oEnvelopePath As String = Path.Combine(oTempFolderPath, pEnvelope.Uuid)
|
||||||
|
|
||||||
If Not Directory.Exists(oEnvelopePath) Then
|
If Not Directory.Exists(oEnvelopePath) Then
|
||||||
Directory.CreateDirectory(oEnvelopePath)
|
Directory.CreateDirectory(oEnvelopePath)
|
||||||
|
|||||||
BIN
EnvelopeGenerator.Form/DD_signFLOW_ICON.ico
Normal file
BIN
EnvelopeGenerator.Form/DD_signFLOW_ICON.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 5.5 KiB |
@@ -14,6 +14,8 @@
|
|||||||
<OptionCompare>Binary</OptionCompare>
|
<OptionCompare>Binary</OptionCompare>
|
||||||
<OptionStrict>Off</OptionStrict>
|
<OptionStrict>Off</OptionStrict>
|
||||||
<OptionInfer>On</OptionInfer>
|
<OptionInfer>On</OptionInfer>
|
||||||
|
<NuGetPackageImportStamp>
|
||||||
|
</NuGetPackageImportStamp>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
@@ -41,7 +43,10 @@
|
|||||||
<StartupObject>EnvelopeGenerator.Form.My.MyApplication</StartupObject>
|
<StartupObject>EnvelopeGenerator.Form.My.MyApplication</StartupObject>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<ApplicationIcon>DD_signFLOW_icon_256.ico</ApplicationIcon>
|
<ApplicationIcon>DD_signFLOW_ICON.ico</ApplicationIcon>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Accessibility" />
|
<Reference Include="Accessibility" />
|
||||||
@@ -66,8 +71,9 @@
|
|||||||
<Reference Include="DevExpress.XtraNavBar.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
<Reference Include="DevExpress.XtraNavBar.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
||||||
<Reference Include="DevExpress.XtraPrinting.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
<Reference Include="DevExpress.XtraPrinting.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
||||||
<Reference Include="DevExpress.XtraTreeList.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
<Reference Include="DevExpress.XtraTreeList.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
||||||
<Reference Include="DigitalData.Controls.DocumentViewer">
|
<Reference Include="DigitalData.Controls.DocumentViewer, Version=1.9.4.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\..\DDMonorepo\Controls.DocumentViewer\bin\Debug\DigitalData.Controls.DocumentViewer.dll</HintPath>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\..\2_DLL Projekte\DDMonorepo\Controls.DocumentViewer\bin\Debug\DigitalData.Controls.DocumentViewer.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DigitalData.GUIs.Common">
|
<Reference Include="DigitalData.GUIs.Common">
|
||||||
<HintPath>..\..\DDMonorepo\GUIs.Common\bin\Debug\DigitalData.GUIs.Common.dll</HintPath>
|
<HintPath>..\..\DDMonorepo\GUIs.Common\bin\Debug\DigitalData.GUIs.Common.dll</HintPath>
|
||||||
@@ -75,21 +81,27 @@
|
|||||||
<Reference Include="DigitalData.Modules.Base">
|
<Reference Include="DigitalData.Modules.Base">
|
||||||
<HintPath>..\..\DDModules\Base\bin\Debug\DigitalData.Modules.Base.dll</HintPath>
|
<HintPath>..\..\DDModules\Base\bin\Debug\DigitalData.Modules.Base.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DigitalData.Modules.Config">
|
<Reference Include="DigitalData.Modules.Config, Version=1.2.2.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\..\DDModules\Config\bin\Debug\DigitalData.Modules.Config.dll</HintPath>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\..\2_DLL Projekte\DDModules\Config\bin\Debug\DigitalData.Modules.Config.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DigitalData.Modules.Database">
|
<Reference Include="DigitalData.Modules.Database, Version=2.3.5.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\..\DDModules\Database\bin\Debug\DigitalData.Modules.Database.dll</HintPath>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\..\2_DLL Projekte\DDModules\Database\bin\Debug\DigitalData.Modules.Database.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DigitalData.Modules.Logging">
|
<Reference Include="DigitalData.Modules.Logging, Version=2.6.3.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\..\DDModules\Logging\bin\Debug\DigitalData.Modules.Logging.dll</HintPath>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\..\2_DLL Projekte\DDModules\Logging\bin\Debug\DigitalData.Modules.Logging.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="DigitalData.Modules.Messaging">
|
||||||
|
<HintPath>..\..\2_DLL Projekte\DDModules\Messaging\bin\Debug\DigitalData.Modules.Messaging.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="EnvelopeGenerator.Common, Version=1.8.0.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="EnvelopeGenerator.Common, Version=1.8.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<SpecificVersion>False</SpecificVersion>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
<HintPath>..\EnvelopeGenerator.Common\bin\Debug\EnvelopeGenerator.Common.dll</HintPath>
|
<HintPath>..\EnvelopeGenerator.Common\bin\Debug\EnvelopeGenerator.Common.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="GdPicture.NET.14">
|
<Reference Include="GdPicture.NET.14, Version=14.2.90.0, Culture=neutral, PublicKeyToken=f52a2e60ad468dbb, processorArchitecture=MSIL">
|
||||||
<HintPath>D:\ProgramFiles\GdPicture.NET 14\Redist\GdPicture.NET (.NET Framework 4.5)\GdPicture.NET.14.dll</HintPath>
|
<HintPath>..\packages\GdPicture.14.2.90\lib\net462\GdPicture.NET.14.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.5.0.5\lib\net46\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.5.0.5\lib\net46\NLog.dll</HintPath>
|
||||||
@@ -130,6 +142,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="frmChooseDocVariant.Designer.vb">
|
||||||
|
<DependentUpon>frmChooseDocVariant.vb</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChooseDocVariant.vb">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
<Compile Include="frmEnvelopeEditor.vb">
|
<Compile Include="frmEnvelopeEditor.vb">
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -178,8 +196,12 @@
|
|||||||
<DesignTime>True</DesignTime>
|
<DesignTime>True</DesignTime>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="My Project\AssemblyInfo.vb" />
|
<Compile Include="My Project\AssemblyInfo.vb" />
|
||||||
|
<EmbeddedResource Include="frmChooseDocVariant.resx">
|
||||||
|
<DependentUpon>frmChooseDocVariant.vb</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="frmEnvelopeEditor.en.resx">
|
<EmbeddedResource Include="frmEnvelopeEditor.en.resx">
|
||||||
<DependentUpon>frmEnvelopeEditor.vb</DependentUpon>
|
<DependentUpon>frmEnvelopeEditor.vb</DependentUpon>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="frmEnvelopeEditor.resx">
|
<EmbeddedResource Include="frmEnvelopeEditor.resx">
|
||||||
<DependentUpon>frmEnvelopeEditor.vb</DependentUpon>
|
<DependentUpon>frmEnvelopeEditor.vb</DependentUpon>
|
||||||
@@ -194,6 +216,7 @@
|
|||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="frmFieldEditor.en.resx">
|
<EmbeddedResource Include="frmFieldEditor.en.resx">
|
||||||
<DependentUpon>frmFieldEditor.vb</DependentUpon>
|
<DependentUpon>frmFieldEditor.vb</DependentUpon>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="frmFieldEditor.resx">
|
<EmbeddedResource Include="frmFieldEditor.resx">
|
||||||
<DependentUpon>frmFieldEditor.vb</DependentUpon>
|
<DependentUpon>frmFieldEditor.vb</DependentUpon>
|
||||||
@@ -244,6 +267,7 @@
|
|||||||
</None>
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Content Include="DD_signFLOW_ICON.ico" />
|
||||||
<Content Include="DD_signFLOW_icon_256.ico" />
|
<Content Include="DD_signFLOW_icon_256.ico" />
|
||||||
<Content Include="DD_signFLOW_Preloader.png" />
|
<Content Include="DD_signFLOW_Preloader.png" />
|
||||||
<Content Include="MailLicense.xml">
|
<Content Include="MailLicense.xml">
|
||||||
@@ -257,6 +281,13 @@
|
|||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||||
|
<Import Project="..\packages\GdPicture.runtimes.windows.14.2.90\build\net462\GdPicture.runtimes.windows.targets" Condition="Exists('..\packages\GdPicture.runtimes.windows.14.2.90\build\net462\GdPicture.runtimes.windows.targets')" />
|
||||||
|
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||||
|
<PropertyGroup>
|
||||||
|
<ErrorText>Dieses Projekt verweist auf mindestens ein NuGet-Paket, das auf diesem Computer fehlt. Verwenden Sie die Wiederherstellung von NuGet-Paketen, um die fehlenden Dateien herunterzuladen. Weitere Informationen finden Sie unter "http://go.microsoft.com/fwlink/?LinkID=322105". Die fehlende Datei ist "{0}".</ErrorText>
|
||||||
|
</PropertyGroup>
|
||||||
|
<Error Condition="!Exists('..\packages\GdPicture.runtimes.windows.14.2.90\build\net462\GdPicture.runtimes.windows.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\GdPicture.runtimes.windows.14.2.90\build\net462\GdPicture.runtimes.windows.targets'))" />
|
||||||
|
</Target>
|
||||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||||
Other similar extension points exist, see Microsoft.Common.targets.
|
Other similar extension points exist, see Microsoft.Common.targets.
|
||||||
<Target Name="BeforeBuild">
|
<Target Name="BeforeBuild">
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
Imports DigitalData.Modules.Logging
|
Imports DigitalData.Modules.Logging
|
||||||
|
|
||||||
Module ModuleSettings
|
Module ModuleSettings
|
||||||
Public DOCUMENT_PATH_MOVE_AFTSEND As String = ""
|
Public ENVELOPE_TEMP_DOCUMENT As String = ""
|
||||||
Public CurrLogConfig As LogConfig
|
Public CurrLogConfig As LogConfig
|
||||||
Public Directory2Delete As String = ""
|
Public Directory2Delete As String = ""
|
||||||
Public MS_GDPICTUREKEY As String = ""
|
Public MS_GDPICTUREKEY As String = ""
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ Imports System.Runtime.InteropServices
|
|||||||
<Assembly: AssemblyCompany("Digital Data")>
|
<Assembly: AssemblyCompany("Digital Data")>
|
||||||
<Assembly: AssemblyProduct("Envelope Generator")>
|
<Assembly: AssemblyProduct("Envelope Generator")>
|
||||||
<Assembly: AssemblyCopyright("Copyright © 2024")>
|
<Assembly: AssemblyCopyright("Copyright © 2024")>
|
||||||
<Assembly: AssemblyTrademark("2.4.5.0")>
|
<Assembly: AssemblyTrademark("2.8.0.0")>
|
||||||
<Assembly: AssemblyCulture("")>
|
<Assembly: AssemblyCulture("")>
|
||||||
|
|
||||||
' Setting ComVisible to false makes the types in this assembly not visible
|
' Setting ComVisible to false makes the types in this assembly not visible
|
||||||
@@ -32,5 +32,5 @@ Imports System.Runtime.InteropServices
|
|||||||
' You can specify all the values or you can default the Build and Revision Numbers
|
' You can specify all the values or you can default the Build and Revision Numbers
|
||||||
' by using the '*' as shown below:
|
' by using the '*' as shown below:
|
||||||
' [assembly: AssemblyVersion("1.0.*")]
|
' [assembly: AssemblyVersion("1.0.*")]
|
||||||
<Assembly: AssemblyVersion("2.7.0.0")>
|
<Assembly: AssemblyVersion("2.8.0.0")>
|
||||||
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
||||||
|
|||||||
@@ -14,10 +14,10 @@
|
|||||||
<value>True</value>
|
<value>True</value>
|
||||||
</setting>
|
</setting>
|
||||||
<setting name="DefaultAppSkin" serializeAs="String">
|
<setting name="DefaultAppSkin" serializeAs="String">
|
||||||
<value>Skin/The Bezier</value>
|
<value>Skin/Office 2019 White</value>
|
||||||
</setting>
|
</setting>
|
||||||
<setting name="DefaultPalette" serializeAs="String">
|
<setting name="DefaultPalette" serializeAs="String">
|
||||||
<value>VS 2019 Blue</value>
|
<value></value>
|
||||||
</setting>
|
</setting>
|
||||||
<setting name="TouchUI" serializeAs="String">
|
<setting name="TouchUI" serializeAs="String">
|
||||||
<value></value>
|
<value></value>
|
||||||
@@ -68,4 +68,12 @@
|
|||||||
<!--<add name="EventLog" type="System.Diagnostics.EventLogTraceListener" initializeData="APPLICATION_NAME"/> -->
|
<!--<add name="EventLog" type="System.Diagnostics.EventLogTraceListener" initializeData="APPLICATION_NAME"/> -->
|
||||||
</sharedListeners>
|
</sharedListeners>
|
||||||
</system.diagnostics>
|
</system.diagnostics>
|
||||||
|
<runtime>
|
||||||
|
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||||
|
<dependentAssembly>
|
||||||
|
<assemblyIdentity name="GdPicture.NET.14" publicKeyToken="f52a2e60ad468dbb" culture="neutral" />
|
||||||
|
<bindingRedirect oldVersion="0.0.0.0-14.2.90.0" newVersion="14.2.90.0" />
|
||||||
|
</dependentAssembly>
|
||||||
|
</assemblyBinding>
|
||||||
|
</runtime>
|
||||||
</configuration>
|
</configuration>
|
||||||
75
EnvelopeGenerator.Form/frmChooseDocVariant.Designer.vb
generated
Normal file
75
EnvelopeGenerator.Form/frmChooseDocVariant.Designer.vb
generated
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
|
||||||
|
Partial Class frmChooseDocVariant
|
||||||
|
Inherits DevExpress.XtraEditors.XtraForm
|
||||||
|
|
||||||
|
'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(frmChooseDocVariant))
|
||||||
|
Me.LabelControl1 = New DevExpress.XtraEditors.LabelControl()
|
||||||
|
Me.SimpleButton2 = New DevExpress.XtraEditors.SimpleButton()
|
||||||
|
Me.OpenFileDialog1 = New System.Windows.Forms.OpenFileDialog()
|
||||||
|
Me.SuspendLayout()
|
||||||
|
'
|
||||||
|
'LabelControl1
|
||||||
|
'
|
||||||
|
Me.LabelControl1.Appearance.Font = New System.Drawing.Font("Segoe UI", 9.75!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||||
|
Me.LabelControl1.Appearance.Options.UseFont = True
|
||||||
|
Me.LabelControl1.Location = New System.Drawing.Point(12, 26)
|
||||||
|
Me.LabelControl1.Name = "LabelControl1"
|
||||||
|
Me.LabelControl1.Size = New System.Drawing.Size(625, 17)
|
||||||
|
Me.LabelControl1.TabIndex = 2
|
||||||
|
Me.LabelControl1.Text = "In diesem Dialog wählen Sie die Dokumente aus, welche dann zu einem Dokument verk" &
|
||||||
|
"ettet werden!"
|
||||||
|
'
|
||||||
|
'SimpleButton2
|
||||||
|
'
|
||||||
|
Me.SimpleButton2.Appearance.Font = New System.Drawing.Font("Segoe UI", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||||
|
Me.SimpleButton2.Appearance.Options.UseFont = True
|
||||||
|
Me.SimpleButton2.ImageOptions.SvgImage = CType(resources.GetObject("SimpleButton2.ImageOptions.SvgImage"), DevExpress.Utils.Svg.SvgImage)
|
||||||
|
Me.SimpleButton2.Location = New System.Drawing.Point(142, 85)
|
||||||
|
Me.SimpleButton2.Name = "SimpleButton2"
|
||||||
|
Me.SimpleButton2.Size = New System.Drawing.Size(343, 50)
|
||||||
|
Me.SimpleButton2.TabIndex = 3
|
||||||
|
Me.SimpleButton2.Text = "Mehrere PDF auswählen und automatisch verketten"
|
||||||
|
'
|
||||||
|
'OpenFileDialog1
|
||||||
|
'
|
||||||
|
Me.OpenFileDialog1.FileName = "OpenFileDialog1"
|
||||||
|
Me.OpenFileDialog1.Filter = "PDF Files|*.pdf"
|
||||||
|
'
|
||||||
|
'frmChooseDocVariant
|
||||||
|
'
|
||||||
|
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||||
|
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||||
|
Me.ClientSize = New System.Drawing.Size(644, 189)
|
||||||
|
Me.Controls.Add(Me.SimpleButton2)
|
||||||
|
Me.Controls.Add(Me.LabelControl1)
|
||||||
|
Me.IconOptions.SvgImage = CType(resources.GetObject("frmChooseDocVariant.IconOptions.SvgImage"), DevExpress.Utils.Svg.SvgImage)
|
||||||
|
Me.Name = "frmChooseDocVariant"
|
||||||
|
Me.Text = "Mehrere Dokumente"
|
||||||
|
Me.ResumeLayout(False)
|
||||||
|
Me.PerformLayout()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
Friend WithEvents LabelControl1 As DevExpress.XtraEditors.LabelControl
|
||||||
|
Friend WithEvents SimpleButton2 As DevExpress.XtraEditors.SimpleButton
|
||||||
|
Friend WithEvents OpenFileDialog1 As OpenFileDialog
|
||||||
|
End Class
|
||||||
179
EnvelopeGenerator.Form/frmChooseDocVariant.resx
Normal file
179
EnvelopeGenerator.Form/frmChooseDocVariant.resx
Normal file
@@ -0,0 +1,179 @@
|
|||||||
|
<?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="SimpleButton2.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v21.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>
|
||||||
|
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjIxLjIsIFZlcnNpb249MjEuMi40
|
||||||
|
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
|
||||||
|
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAJYEAAAC77u/
|
||||||
|
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
|
||||||
|
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
|
||||||
|
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
|
||||||
|
Y2U9InByZXNlcnZlIiBpZD0iTGF5ZXJfMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
|
||||||
|
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLlllbGxvd3tmaWxsOiNGRkIxMTU7fQoJ
|
||||||
|
LlJlZHtmaWxsOiNEMTFDMUM7fQoJLkJsdWV7ZmlsbDojMTE3N0Q3O30KCS5HcmVlbntmaWxsOiMwMzlD
|
||||||
|
MjM7fQoJLkJsYWNre2ZpbGw6IzcyNzI3Mjt9CgkuV2hpdGV7ZmlsbDojRkZGRkZGO30KCS5zdDB7b3Bh
|
||||||
|
Y2l0eTowLjc1O30KPC9zdHlsZT4NCiAgPGcgaWQ9IkRvY3VtZW50UERGIj4NCiAgICA8cGF0aCBkPSJN
|
||||||
|
MjIsMjR2NEgyVjJoMTR2NWMwLDAuNiwwLjQsMSwxLDFoNXY0aDJWN2wtNy03SDFDMC40LDAsMCwwLjQs
|
||||||
|
MCwxdjI4YzAsMC42LDAuNCwxLDEsMWgyMmMwLjYsMCwxLTAuNCwxLTEgICB2LTVIMjJ6IiBjbGFzcz0i
|
||||||
|
QmxhY2siIC8+DQogICAgPHBhdGggZD0iTTE5LjIsMTZjMC4zLDAuNSwwLjQsMS4xLDAuNCwxLjljMCww
|
||||||
|
LjktMC4yLDEuNS0wLjUsMmMtMC4zLDAuNS0wLjcsMC43LTEuMywwLjdoLTAuNnYtNS4zaDAuNiAgIEMx
|
||||||
|
OC40LDE1LjMsMTguOSwxNS42LDE5LjIsMTZ6IE0xMi4xLDE1LjNoLTAuNXYyLjZoMC41YzAuNywwLDEu
|
||||||
|
MS0wLjQsMS4xLTEuM2MwLTAuNC0wLjEtMC44LTAuMy0xQzEyLjYsMTUuNCwxMi40LDE1LjMsMTIuMSwx
|
||||||
|
NS4zeiAgICBNMzAsMTJ2MTJINlYxMkgzMHogTTE0LjgsMTYuNWMwLTAuOC0wLjItMS41LTAuNi0xLjlj
|
||||||
|
LTAuNC0wLjQtMS0wLjctMS44LTAuN0gxMHY4aDEuNnYtMi43aDAuNmMwLjgsMCwxLjQtMC4zLDEuOS0w
|
||||||
|
LjggICBDMTQuNSwxOCwxNC44LDE3LjMsMTQuOCwxNi41eiBNMjEuMiwxNy45YzAtMi42LTEuMS0zLjkt
|
||||||
|
My40LTMuOWgtMi4xdjhoMi4yYzEuMSwwLDEuOS0wLjQsMi41LTEuMUMyMC45LDIwLjIsMjEuMiwxOS4y
|
||||||
|
LDIxLjIsMTcuOXogICAgTTI2LDE0aC0zLjd2OGgxLjZ2LTMuMWgydi0xLjNoLTJ2LTIuMkgyNlYxNHoi
|
||||||
|
IGNsYXNzPSJSZWQiIC8+DQogIDwvZz4NCjwvc3ZnPgs=
|
||||||
|
</value>
|
||||||
|
</data>
|
||||||
|
<metadata name="OpenFileDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>17, 17</value>
|
||||||
|
</metadata>
|
||||||
|
<data name="frmChooseDocVariant.IconOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v21.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>
|
||||||
|
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjIxLjIsIFZlcnNpb249MjEuMi40
|
||||||
|
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
|
||||||
|
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAANYEAAAC77u/
|
||||||
|
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
|
||||||
|
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
|
||||||
|
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
|
||||||
|
Y2U9InByZXNlcnZlIiBpZD0iTG9naWNhbCIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAg
|
||||||
|
MzIgMzIiPg0KICA8c3R5bGUgdHlwZT0idGV4dC9jc3MiPgoJLkJsdWV7ZmlsbDojMTE3N0Q3O30KPC9z
|
||||||
|
dHlsZT4NCiAgPHBhdGggZD0iTTUsNGgyM1YzYzAtMC42LTAuNC0xLTEtMUg1QzMuMywyLDIsMy4zLDIs
|
||||||
|
NXYyMmMwLDEuNywxLjMsMywzLDNoMjJjMC42LDAsMS0wLjQsMS0xVjZINUM0LjQsNiw0LDUuNiw0LDUg
|
||||||
|
IEM0LDQuNCw0LjQsNCw1LDR6IE0xNiwyNGgtMnYtMmgyVjI0eiBNMTEuNiwxNC40YzAuMi0wLjUsMC40
|
||||||
|
LTAuOSwwLjctMS4zYzAuMy0wLjQsMC43LTAuNiwxLjEtMC44YzAuNC0wLjIsMC45LTAuMywxLjUtMC4z
|
||||||
|
ICBjMC43LDAsMS4zLDAuMSwxLjgsMC4zYzAuNSwwLjIsMC45LDAuNSwxLjIsMC44YzAuMywwLjMsMC41
|
||||||
|
LDAuNywwLjYsMWMwLjEsMC40LDAuMiwwLjcsMC4yLDFjMCwwLjQsMCwwLjctMC4xLDEgIGMtMC4xLDAu
|
||||||
|
My0wLjIsMC41LTAuMywwLjhjLTAuMSwwLjItMC4zLDAuNC0wLjQsMC42Yy0wLjIsMC4yLTAuMywwLjMt
|
||||||
|
MC41LDAuNGMtMC4yLDAuMS0wLjMsMC4zLTAuNSwwLjRjLTAuMiwwLjEtMC4zLDAuMy0wLjQsMC40ICBj
|
||||||
|
LTAuMSwwLjEtMC4zLDAuMy0wLjQsMC41Yy0wLjEsMC4yLTAuMiwwLjQtMC4yLDAuNnYwLjZoLTJ2LTAu
|
||||||
|
N2MwLTAuNCwwLjEtMC43LDAuMS0wLjljMC4xLTAuMywwLjItMC41LDAuMy0wLjcgIGMwLjEtMC4yLDAu
|
||||||
|
My0wLjQsMC40LTAuNWMwLjEtMC4xLDAuMy0wLjMsMC40LTAuNHMwLjMtMC4zLDAuNC0wLjRjMC4xLTAu
|
||||||
|
MSwwLjItMC4yLDAuMy0wLjRjMC4xLTAuMSwwLjItMC4zLDAuMi0wLjUgIGMwLjEtMC4yLDAuMS0wLjQs
|
||||||
|
MC4xLTAuNmMwLTAuNS0wLjEtMC45LTAuMy0xLjFjLTAuMi0wLjItMC41LTAuNC0wLjktMC40Yy0wLjMs
|
||||||
|
MC0wLjUsMC4xLTAuNywwLjJjLTAuMiwwLjEtMC40LDAuMy0wLjUsMC41ICBjLTAuMSwwLjItMC4yLDAu
|
||||||
|
NC0wLjMsMC43Yy0wLjEsMC4yLTAuMSwwLjUtMC4xLDAuOGgtMi4yQzExLjQsMTUuNCwxMS40LDE0Ljks
|
||||||
|
MTEuNiwxNC40eiIgY2xhc3M9IkJsdWUiIC8+DQo8L3N2Zz4L
|
||||||
|
</value>
|
||||||
|
</data>
|
||||||
|
</root>
|
||||||
96
EnvelopeGenerator.Form/frmChooseDocVariant.vb
Normal file
96
EnvelopeGenerator.Form/frmChooseDocVariant.vb
Normal file
@@ -0,0 +1,96 @@
|
|||||||
|
Imports DevExpress.XtraSplashScreen
|
||||||
|
Imports EnvelopeGenerator.Common
|
||||||
|
Imports DigitalData.Modules.Logging
|
||||||
|
Imports GdPicture14
|
||||||
|
Public Class frmChooseDocVariant
|
||||||
|
Private TempFiles As TempFiles
|
||||||
|
Public Property State As State
|
||||||
|
Private Logger As Logger
|
||||||
|
Private Sub frmChooseDocVariant_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||||
|
ENVELOPE_TEMP_DOCUMENT = ""
|
||||||
|
TempFiles = New TempFiles(State.LogConfig)
|
||||||
|
TempFiles.Create()
|
||||||
|
Logger = State.LogConfig.GetLogger()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub SimpleButton1_Click(sender As Object, e As EventArgs)
|
||||||
|
OpenFileDialog1.Multiselect = False
|
||||||
|
Dim oHandle = SplashScreenManager.ShowOverlayForm(Me)
|
||||||
|
|
||||||
|
Try
|
||||||
|
If OpenFileDialog1.ShowDialog() = DialogResult.OK Then
|
||||||
|
ENVELOPE_TEMP_DOCUMENT = OpenFileDialog1.FileName
|
||||||
|
End If
|
||||||
|
|
||||||
|
Catch ex As Exception
|
||||||
|
Logger.Error(ex)
|
||||||
|
Finally
|
||||||
|
SplashScreenManager.CloseOverlayForm(oHandle)
|
||||||
|
End Try
|
||||||
|
' Else
|
||||||
|
' SplashScreenManager.CloseOverlayForm(oHandle)
|
||||||
|
' End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub SimpleButton2_Click(sender As Object, e As EventArgs) Handles SimpleButton2.Click
|
||||||
|
OpenFileDialog1.Multiselect = True
|
||||||
|
Dim oHandle = SplashScreenManager.ShowOverlayForm(Me)
|
||||||
|
Try
|
||||||
|
Dim oErr As Boolean = False
|
||||||
|
If OpenFileDialog1.ShowDialog() = DialogResult.OK Then
|
||||||
|
Dim oIDX As Integer = 0
|
||||||
|
For Each oFile As String In OpenFileDialog1.FileNames
|
||||||
|
oIDX += 1
|
||||||
|
Next
|
||||||
|
|
||||||
|
Dim arPDF As GdPicturePDF() = New GdPicturePDF(oIDX) {}
|
||||||
|
oIDX = 0
|
||||||
|
For Each oFile As String In OpenFileDialog1.FileNames
|
||||||
|
arPDF(oIDX) = New GdPicturePDF()
|
||||||
|
If arPDF(oIDX).LoadFromFile(oFile) <> GdPictureStatus.OK Then
|
||||||
|
MsgBox($"PDF Statsu of file {oFile} is not OK. Please check PDF-conformity!", MsgBoxStyle.Critical)
|
||||||
|
oErr = True
|
||||||
|
Exit For
|
||||||
|
End If
|
||||||
|
oIDX += 1
|
||||||
|
Next
|
||||||
|
If oErr = False Then
|
||||||
|
|
||||||
|
Dim dstPDF As GdPicturePDF = arPDF(0).MergeDocuments(arPDF)
|
||||||
|
Dim oStatus As GdPictureStatus = arPDF(0).GetStat()
|
||||||
|
If oStatus = GdPictureStatus.OK Then
|
||||||
|
MsgBox("All documents have been successfully merged.", MsgBoxStyle.Information)
|
||||||
|
Dim oTempFolder = TempFiles.TempPath
|
||||||
|
Dim oTempFilename = String.Concat(oTempFolder, "\", $"MergedDoc.pdf")
|
||||||
|
If System.IO.File.Exists(oTempFilename) Then
|
||||||
|
System.IO.File.Delete(oTempFilename)
|
||||||
|
End If
|
||||||
|
If dstPDF.SaveToFile(oTempFilename) = GdPictureStatus.OK Then
|
||||||
|
MessageBox.Show("Merged document has been successfully saved.", "Example: MergeDocuments")
|
||||||
|
ENVELOPE_TEMP_DOCUMENT = oTempFilename
|
||||||
|
dstPDF.CloseDocument()
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
MessageBox.Show("The MergeDocuments() method has failed with the status: " + oStatus.ToString(), "Example: MergeDocuments")
|
||||||
|
End If
|
||||||
|
dstPDF.Dispose()
|
||||||
|
oIDX = 0
|
||||||
|
For Each oFile As String In OpenFileDialog1.FileNames
|
||||||
|
arPDF(oIDX).CloseDocument()
|
||||||
|
oIDX += 1
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
|
Catch ex As Exception
|
||||||
|
Logger.Error(ex)
|
||||||
|
Finally
|
||||||
|
SplashScreenManager.CloseOverlayForm(oHandle)
|
||||||
|
End Try
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub LabelControl1_Click(sender As Object, e As EventArgs) Handles LabelControl1.Click
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
End Class
|
||||||
46
EnvelopeGenerator.Form/frmEnvelopeEditor.Designer.vb
generated
46
EnvelopeGenerator.Form/frmEnvelopeEditor.Designer.vb
generated
@@ -58,12 +58,14 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.BarButtonItem1 = New DevExpress.XtraBars.BarButtonItem()
|
Me.BarButtonItem1 = New DevExpress.XtraBars.BarButtonItem()
|
||||||
Me.BarStaticItem1 = New DevExpress.XtraBars.BarStaticItem()
|
Me.BarStaticItem1 = New DevExpress.XtraBars.BarStaticItem()
|
||||||
Me.BarButtonItem2 = New DevExpress.XtraBars.BarButtonItem()
|
Me.BarButtonItem2 = New DevExpress.XtraBars.BarButtonItem()
|
||||||
|
Me.BarButtonItem3 = New DevExpress.XtraBars.BarButtonItem()
|
||||||
Me.RibbonPage1 = New DevExpress.XtraBars.Ribbon.RibbonPage()
|
Me.RibbonPage1 = New DevExpress.XtraBars.Ribbon.RibbonPage()
|
||||||
Me.RibbonPageGroup1 = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
Me.RibbonPageGroup1 = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
||||||
Me.RibbonPageGroupDocuments = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
Me.RibbonPageGroupDocuments = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
||||||
Me.RibbonPageGroupInvitation = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
Me.RibbonPageGroupInvitation = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
||||||
Me.RibbonPageGroupAddSignature = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
Me.RibbonPageGroupAddSignature = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
||||||
Me.RibbonPageGroupReceiver = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
Me.RibbonPageGroupReceiver = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
||||||
|
Me.RibbonPageGroup2 = New DevExpress.XtraBars.Ribbon.RibbonPageGroup()
|
||||||
Me.RibbonStatusBar1 = New DevExpress.XtraBars.Ribbon.RibbonStatusBar()
|
Me.RibbonStatusBar1 = New DevExpress.XtraBars.Ribbon.RibbonStatusBar()
|
||||||
Me.LayoutControlGroup4 = New DevExpress.XtraLayout.LayoutControlGroup()
|
Me.LayoutControlGroup4 = New DevExpress.XtraLayout.LayoutControlGroup()
|
||||||
Me.LayoutControlGroup5 = New DevExpress.XtraLayout.LayoutControlGroup()
|
Me.LayoutControlGroup5 = New DevExpress.XtraLayout.LayoutControlGroup()
|
||||||
@@ -98,6 +100,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.EnvelopeDocumentBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
Me.EnvelopeDocumentBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||||
Me.OpenFileDialog1 = New System.Windows.Forms.OpenFileDialog()
|
Me.OpenFileDialog1 = New System.Windows.Forms.OpenFileDialog()
|
||||||
Me.txtEnvelopeIdLabel = New DevExpress.XtraBars.BarStaticItem()
|
Me.txtEnvelopeIdLabel = New DevExpress.XtraBars.BarStaticItem()
|
||||||
|
Me.BarButtonItem4 = New DevExpress.XtraBars.BarButtonItem()
|
||||||
CType(Me.SplitContainerControl1, System.ComponentModel.ISupportInitialize).BeginInit()
|
CType(Me.SplitContainerControl1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||||
CType(Me.SplitContainerControl1.Panel1, System.ComponentModel.ISupportInitialize).BeginInit()
|
CType(Me.SplitContainerControl1.Panel1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||||
Me.SplitContainerControl1.Panel1.SuspendLayout()
|
Me.SplitContainerControl1.Panel1.SuspendLayout()
|
||||||
@@ -240,9 +243,9 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
'RibbonControl1
|
'RibbonControl1
|
||||||
'
|
'
|
||||||
Me.RibbonControl1.ExpandCollapseItem.Id = 0
|
Me.RibbonControl1.ExpandCollapseItem.Id = 0
|
||||||
Me.RibbonControl1.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.RibbonControl1.ExpandCollapseItem, Me.RibbonControl1.SearchEditItem, Me.btnSave, Me.btnCancel, Me.btnNewFile, Me.btnDeleteFile, Me.btnSendEnvelope, Me.btnEditFields, Me.btnDeleteReceiver, Me.btnEditData, Me.txtCreatorEmailLabel, Me.txtEnvelopeIdLabel2, Me.BarButtonItem1, Me.BarStaticItem1, Me.BarButtonItem2})
|
Me.RibbonControl1.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.RibbonControl1.ExpandCollapseItem, Me.RibbonControl1.SearchEditItem, Me.btnSave, Me.btnCancel, Me.btnNewFile, Me.btnDeleteFile, Me.btnSendEnvelope, Me.btnEditFields, Me.btnDeleteReceiver, Me.btnEditData, Me.txtCreatorEmailLabel, Me.txtEnvelopeIdLabel2, Me.BarButtonItem1, Me.BarStaticItem1, Me.BarButtonItem2, Me.BarButtonItem3, Me.BarButtonItem4})
|
||||||
resources.ApplyResources(Me.RibbonControl1, "RibbonControl1")
|
resources.ApplyResources(Me.RibbonControl1, "RibbonControl1")
|
||||||
Me.RibbonControl1.MaxItemId = 15
|
Me.RibbonControl1.MaxItemId = 17
|
||||||
Me.RibbonControl1.Name = "RibbonControl1"
|
Me.RibbonControl1.Name = "RibbonControl1"
|
||||||
Me.RibbonControl1.Pages.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPage() {Me.RibbonPage1})
|
Me.RibbonControl1.Pages.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPage() {Me.RibbonPage1})
|
||||||
Me.RibbonControl1.ShowApplicationButton = DevExpress.Utils.DefaultBoolean.[False]
|
Me.RibbonControl1.ShowApplicationButton = DevExpress.Utils.DefaultBoolean.[False]
|
||||||
@@ -342,9 +345,15 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.BarButtonItem2.Id = 14
|
Me.BarButtonItem2.Id = 14
|
||||||
Me.BarButtonItem2.Name = "BarButtonItem2"
|
Me.BarButtonItem2.Name = "BarButtonItem2"
|
||||||
'
|
'
|
||||||
|
'BarButtonItem3
|
||||||
|
'
|
||||||
|
resources.ApplyResources(Me.BarButtonItem3, "BarButtonItem3")
|
||||||
|
Me.BarButtonItem3.Id = 15
|
||||||
|
Me.BarButtonItem3.Name = "BarButtonItem3"
|
||||||
|
'
|
||||||
'RibbonPage1
|
'RibbonPage1
|
||||||
'
|
'
|
||||||
Me.RibbonPage1.Groups.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPageGroup() {Me.RibbonPageGroup1, Me.RibbonPageGroupDocuments, Me.RibbonPageGroupInvitation, Me.RibbonPageGroupAddSignature, Me.RibbonPageGroupReceiver})
|
Me.RibbonPage1.Groups.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPageGroup() {Me.RibbonPageGroup1, Me.RibbonPageGroupDocuments, Me.RibbonPageGroupInvitation, Me.RibbonPageGroupAddSignature, Me.RibbonPageGroupReceiver, Me.RibbonPageGroup2})
|
||||||
Me.RibbonPage1.Name = "RibbonPage1"
|
Me.RibbonPage1.Name = "RibbonPage1"
|
||||||
resources.ApplyResources(Me.RibbonPage1, "RibbonPage1")
|
resources.ApplyResources(Me.RibbonPage1, "RibbonPage1")
|
||||||
'
|
'
|
||||||
@@ -359,6 +368,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
'RibbonPageGroupDocuments
|
'RibbonPageGroupDocuments
|
||||||
'
|
'
|
||||||
Me.RibbonPageGroupDocuments.ItemLinks.Add(Me.btnNewFile)
|
Me.RibbonPageGroupDocuments.ItemLinks.Add(Me.btnNewFile)
|
||||||
|
Me.RibbonPageGroupDocuments.ItemLinks.Add(Me.BarButtonItem4)
|
||||||
Me.RibbonPageGroupDocuments.ItemLinks.Add(Me.btnDeleteFile)
|
Me.RibbonPageGroupDocuments.ItemLinks.Add(Me.btnDeleteFile)
|
||||||
Me.RibbonPageGroupDocuments.Name = "RibbonPageGroupDocuments"
|
Me.RibbonPageGroupDocuments.Name = "RibbonPageGroupDocuments"
|
||||||
resources.ApplyResources(Me.RibbonPageGroupDocuments, "RibbonPageGroupDocuments")
|
resources.ApplyResources(Me.RibbonPageGroupDocuments, "RibbonPageGroupDocuments")
|
||||||
@@ -382,6 +392,12 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.RibbonPageGroupReceiver.Name = "RibbonPageGroupReceiver"
|
Me.RibbonPageGroupReceiver.Name = "RibbonPageGroupReceiver"
|
||||||
resources.ApplyResources(Me.RibbonPageGroupReceiver, "RibbonPageGroupReceiver")
|
resources.ApplyResources(Me.RibbonPageGroupReceiver, "RibbonPageGroupReceiver")
|
||||||
'
|
'
|
||||||
|
'RibbonPageGroup2
|
||||||
|
'
|
||||||
|
Me.RibbonPageGroup2.ItemLinks.Add(Me.BarButtonItem3)
|
||||||
|
Me.RibbonPageGroup2.Name = "RibbonPageGroup2"
|
||||||
|
resources.ApplyResources(Me.RibbonPageGroup2, "RibbonPageGroup2")
|
||||||
|
'
|
||||||
'RibbonStatusBar1
|
'RibbonStatusBar1
|
||||||
'
|
'
|
||||||
Me.RibbonStatusBar1.ItemLinks.Add(Me.txtCreatorEmailLabel)
|
Me.RibbonStatusBar1.ItemLinks.Add(Me.txtCreatorEmailLabel)
|
||||||
@@ -398,7 +414,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.LayoutControlGroup4.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlGroup5})
|
Me.LayoutControlGroup4.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlGroup5})
|
||||||
Me.LayoutControlGroup4.Name = "LayoutControlGroup4"
|
Me.LayoutControlGroup4.Name = "LayoutControlGroup4"
|
||||||
Me.LayoutControlGroup4.Padding = New DevExpress.XtraLayout.Utils.Padding(0, 0, 0, 0)
|
Me.LayoutControlGroup4.Padding = New DevExpress.XtraLayout.Utils.Padding(0, 0, 0, 0)
|
||||||
Me.LayoutControlGroup4.Size = New System.Drawing.Size(251, 526)
|
Me.LayoutControlGroup4.Size = New System.Drawing.Size(251, 530)
|
||||||
Me.LayoutControlGroup4.TextVisible = False
|
Me.LayoutControlGroup4.TextVisible = False
|
||||||
'
|
'
|
||||||
'LayoutControlGroup5
|
'LayoutControlGroup5
|
||||||
@@ -406,7 +422,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.LayoutControlGroup5.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlItem5})
|
Me.LayoutControlGroup5.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlItem5})
|
||||||
Me.LayoutControlGroup5.Location = New System.Drawing.Point(0, 0)
|
Me.LayoutControlGroup5.Location = New System.Drawing.Point(0, 0)
|
||||||
Me.LayoutControlGroup5.Name = "LayoutControlGroup5"
|
Me.LayoutControlGroup5.Name = "LayoutControlGroup5"
|
||||||
Me.LayoutControlGroup5.Size = New System.Drawing.Size(251, 526)
|
Me.LayoutControlGroup5.Size = New System.Drawing.Size(251, 530)
|
||||||
resources.ApplyResources(Me.LayoutControlGroup5, "LayoutControlGroup5")
|
resources.ApplyResources(Me.LayoutControlGroup5, "LayoutControlGroup5")
|
||||||
'
|
'
|
||||||
'LayoutControlItem5
|
'LayoutControlItem5
|
||||||
@@ -414,7 +430,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.LayoutControlItem5.Control = Me.GridDocuments
|
Me.LayoutControlItem5.Control = Me.GridDocuments
|
||||||
Me.LayoutControlItem5.Location = New System.Drawing.Point(0, 0)
|
Me.LayoutControlItem5.Location = New System.Drawing.Point(0, 0)
|
||||||
Me.LayoutControlItem5.Name = "LayoutControlItem5"
|
Me.LayoutControlItem5.Name = "LayoutControlItem5"
|
||||||
Me.LayoutControlItem5.Size = New System.Drawing.Size(227, 477)
|
Me.LayoutControlItem5.Size = New System.Drawing.Size(227, 485)
|
||||||
Me.LayoutControlItem5.TextSize = New System.Drawing.Size(0, 0)
|
Me.LayoutControlItem5.TextSize = New System.Drawing.Size(0, 0)
|
||||||
Me.LayoutControlItem5.TextVisible = False
|
Me.LayoutControlItem5.TextVisible = False
|
||||||
'
|
'
|
||||||
@@ -578,7 +594,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.LayoutControlItem2.Control = Me.GridReceivers
|
Me.LayoutControlItem2.Control = Me.GridReceivers
|
||||||
Me.LayoutControlItem2.Location = New System.Drawing.Point(0, 0)
|
Me.LayoutControlItem2.Location = New System.Drawing.Point(0, 0)
|
||||||
Me.LayoutControlItem2.Name = "LayoutControlItem2"
|
Me.LayoutControlItem2.Name = "LayoutControlItem2"
|
||||||
Me.LayoutControlItem2.Size = New System.Drawing.Size(875, 200)
|
Me.LayoutControlItem2.Size = New System.Drawing.Size(875, 204)
|
||||||
Me.LayoutControlItem2.TextSize = New System.Drawing.Size(0, 0)
|
Me.LayoutControlItem2.TextSize = New System.Drawing.Size(0, 0)
|
||||||
Me.LayoutControlItem2.TextVisible = False
|
Me.LayoutControlItem2.TextVisible = False
|
||||||
'
|
'
|
||||||
@@ -611,7 +627,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.Root.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlGroup1})
|
Me.Root.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlGroup1})
|
||||||
Me.Root.Name = "Root"
|
Me.Root.Name = "Root"
|
||||||
Me.Root.Padding = New DevExpress.XtraLayout.Utils.Padding(0, 0, 0, 0)
|
Me.Root.Padding = New DevExpress.XtraLayout.Utils.Padding(0, 0, 0, 0)
|
||||||
Me.Root.Size = New System.Drawing.Size(899, 259)
|
Me.Root.Size = New System.Drawing.Size(899, 263)
|
||||||
Me.Root.TextVisible = False
|
Me.Root.TextVisible = False
|
||||||
'
|
'
|
||||||
'LayoutControlGroup1
|
'LayoutControlGroup1
|
||||||
@@ -620,7 +636,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.LayoutControlGroup1.Location = New System.Drawing.Point(0, 0)
|
Me.LayoutControlGroup1.Location = New System.Drawing.Point(0, 0)
|
||||||
Me.LayoutControlGroup1.Name = "LayoutControlGroup1"
|
Me.LayoutControlGroup1.Name = "LayoutControlGroup1"
|
||||||
Me.LayoutControlGroup1.Padding = New DevExpress.XtraLayout.Utils.Padding(10, 10, 10, 10)
|
Me.LayoutControlGroup1.Padding = New DevExpress.XtraLayout.Utils.Padding(10, 10, 10, 10)
|
||||||
Me.LayoutControlGroup1.Size = New System.Drawing.Size(899, 259)
|
Me.LayoutControlGroup1.Size = New System.Drawing.Size(899, 263)
|
||||||
resources.ApplyResources(Me.LayoutControlGroup1, "LayoutControlGroup1")
|
resources.ApplyResources(Me.LayoutControlGroup1, "LayoutControlGroup1")
|
||||||
'
|
'
|
||||||
'LayoutControlItem3
|
'LayoutControlItem3
|
||||||
@@ -629,7 +645,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.LayoutControlItem3.Location = New System.Drawing.Point(0, 0)
|
Me.LayoutControlItem3.Location = New System.Drawing.Point(0, 0)
|
||||||
Me.LayoutControlItem3.Name = "LayoutControlItem3"
|
Me.LayoutControlItem3.Name = "LayoutControlItem3"
|
||||||
Me.LayoutControlItem3.Padding = New DevExpress.XtraLayout.Utils.Padding(10, 10, 10, 10)
|
Me.LayoutControlItem3.Padding = New DevExpress.XtraLayout.Utils.Padding(10, 10, 10, 10)
|
||||||
Me.LayoutControlItem3.Size = New System.Drawing.Size(873, 208)
|
Me.LayoutControlItem3.Size = New System.Drawing.Size(873, 216)
|
||||||
resources.ApplyResources(Me.LayoutControlItem3, "LayoutControlItem3")
|
resources.ApplyResources(Me.LayoutControlItem3, "LayoutControlItem3")
|
||||||
Me.LayoutControlItem3.TextLocation = DevExpress.Utils.Locations.Top
|
Me.LayoutControlItem3.TextLocation = DevExpress.Utils.Locations.Top
|
||||||
Me.LayoutControlItem3.TextSize = New System.Drawing.Size(49, 13)
|
Me.LayoutControlItem3.TextSize = New System.Drawing.Size(49, 13)
|
||||||
@@ -659,6 +675,13 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Me.txtEnvelopeIdLabel.PaintStyle = DevExpress.XtraBars.BarItemPaintStyle.CaptionGlyph
|
Me.txtEnvelopeIdLabel.PaintStyle = DevExpress.XtraBars.BarItemPaintStyle.CaptionGlyph
|
||||||
Me.txtEnvelopeIdLabel.Tag = "Envelope-ID: {0}"
|
Me.txtEnvelopeIdLabel.Tag = "Envelope-ID: {0}"
|
||||||
'
|
'
|
||||||
|
'BarButtonItem4
|
||||||
|
'
|
||||||
|
resources.ApplyResources(Me.BarButtonItem4, "BarButtonItem4")
|
||||||
|
Me.BarButtonItem4.Id = 16
|
||||||
|
Me.BarButtonItem4.ImageOptions.SvgImage = CType(resources.GetObject("BarButtonItem4.ImageOptions.SvgImage"), DevExpress.Utils.Svg.SvgImage)
|
||||||
|
Me.BarButtonItem4.Name = "BarButtonItem4"
|
||||||
|
'
|
||||||
'frmEnvelopeEditor
|
'frmEnvelopeEditor
|
||||||
'
|
'
|
||||||
resources.ApplyResources(Me, "$this")
|
resources.ApplyResources(Me, "$this")
|
||||||
@@ -783,6 +806,9 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Friend WithEvents BarButtonItem1 As DevExpress.XtraBars.BarButtonItem
|
Friend WithEvents BarButtonItem1 As DevExpress.XtraBars.BarButtonItem
|
||||||
Friend WithEvents BarStaticItem1 As DevExpress.XtraBars.BarStaticItem
|
Friend WithEvents BarStaticItem1 As DevExpress.XtraBars.BarStaticItem
|
||||||
Friend WithEvents BarButtonItem2 As DevExpress.XtraBars.BarButtonItem
|
Friend WithEvents BarButtonItem2 As DevExpress.XtraBars.BarButtonItem
|
||||||
|
Friend WithEvents BarButtonItem3 As DevExpress.XtraBars.BarButtonItem
|
||||||
|
Friend WithEvents RibbonPageGroup2 As DevExpress.XtraBars.Ribbon.RibbonPageGroup
|
||||||
|
Friend WithEvents BarButtonItem4 As DevExpress.XtraBars.BarButtonItem
|
||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|||||||
@@ -384,6 +384,6 @@
|
|||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="$this.Text" xml:space="preserve">
|
<data name="$this.Text" xml:space="preserve">
|
||||||
<value>Sign Flow - Envelope-Editor</value>
|
<value>signFLOW - Envelope-Editor</value>
|
||||||
</data>
|
</data>
|
||||||
</root>
|
</root>
|
||||||
@@ -126,7 +126,7 @@
|
|||||||
<value>0, 132</value>
|
<value>0, 132</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="GridDocuments.Location" type="System.Drawing.Point, System.Drawing">
|
<data name="GridDocuments.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
<value>14, 39</value>
|
<value>14, 35</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="colFilename.Caption" xml:space="preserve">
|
<data name="colFilename.Caption" xml:space="preserve">
|
||||||
<value>Dateiname</value>
|
<value>Dateiname</value>
|
||||||
@@ -213,7 +213,7 @@
|
|||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnNewFile.Caption" xml:space="preserve">
|
<data name="btnNewFile.Caption" xml:space="preserve">
|
||||||
<value>Neues Dokument</value>
|
<value>Ein Dokument hinzufügen</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnNewFile.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v21.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnNewFile.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v21.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
@@ -414,6 +414,30 @@
|
|||||||
<data name="BarButtonItem2.Caption" xml:space="preserve">
|
<data name="BarButtonItem2.Caption" xml:space="preserve">
|
||||||
<value>Öffnen</value>
|
<value>Öffnen</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="BarButtonItem3.Caption" xml:space="preserve">
|
||||||
|
<value>BarButtonItem3</value>
|
||||||
|
</data>
|
||||||
|
<data name="BarButtonItem4.Caption" xml:space="preserve">
|
||||||
|
<value>Mehrere Dokumente hinzufügen</value>
|
||||||
|
</data>
|
||||||
|
<data name="BarButtonItem4.ImageOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v21.2" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>
|
||||||
|
AAEAAAD/////AQAAAAAAAAAMAgAAAFlEZXZFeHByZXNzLkRhdGEudjIxLjIsIFZlcnNpb249MjEuMi40
|
||||||
|
LjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjg4ZDE3NTRkNzAwZTQ5YQUBAAAAHURl
|
||||||
|
dkV4cHJlc3MuVXRpbHMuU3ZnLlN2Z0ltYWdlAQAAAAREYXRhBwICAAAACQMAAAAPAwAAAHECAAAC77u/
|
||||||
|
PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4NCjxzdmcgeD0iMHB4IiB5PSIwcHgi
|
||||||
|
IHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcv
|
||||||
|
MjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4bWw6c3Bh
|
||||||
|
Y2U9InByZXNlcnZlIiBpZD0iTXVsdGlwbGVfRG9jdW1lbnRzIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91
|
||||||
|
bmQ6bmV3IDAgMCAzMiAzMiI+DQogIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+CgkuQmxhY2t7ZmlsbDoj
|
||||||
|
NzI3MjcyO30KPC9zdHlsZT4NCiAgPHBhdGggZD0iTTMxLDhoLTVWNWMwLTAuNS0wLjUtMS0xLTFoLTVW
|
||||||
|
MWMwLTAuNS0wLjUtMS0xLTFIMUMwLjUsMCwwLDAuNSwwLDF2MjJjMCwwLjUsMC41LDEsMSwxaDV2M2Mw
|
||||||
|
LDAuNSwwLjUsMSwxLDEgIGg1djNjMCwwLjUsMC41LDEsMSwxaDE4YzAuNSwwLDEtMC41LDEtMVY5QzMy
|
||||||
|
LDguNSwzMS41LDgsMzEsOHogTTYsNXYxN0gyVjJoMTZ2Mkg3QzYuNSw0LDYsNC41LDYsNXogTTEyLDl2
|
||||||
|
MTdIOFY2aDE2djJIMTMgIEMxMi41LDgsMTIsOC41LDEyLDl6IE0zMCwzMEgxNFYxMGgxNlYzMHoiIGNs
|
||||||
|
YXNzPSJCbGFjayIgLz4NCjwvc3ZnPgs=
|
||||||
|
</value>
|
||||||
|
</data>
|
||||||
<data name="RibbonControl1.Location" type="System.Drawing.Point, System.Drawing">
|
<data name="RibbonControl1.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
<value>0, 0</value>
|
<value>0, 0</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -432,6 +456,9 @@
|
|||||||
<data name="RibbonPageGroupReceiver.Text" xml:space="preserve">
|
<data name="RibbonPageGroupReceiver.Text" xml:space="preserve">
|
||||||
<value>Empfänger</value>
|
<value>Empfänger</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="RibbonPageGroup2.Text" xml:space="preserve">
|
||||||
|
<value>RibbonPageGroup2</value>
|
||||||
|
</data>
|
||||||
<data name="RibbonPage1.Text" xml:space="preserve">
|
<data name="RibbonPage1.Text" xml:space="preserve">
|
||||||
<value>Start</value>
|
<value>Start</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -439,10 +466,10 @@
|
|||||||
<value>1164, 132</value>
|
<value>1164, 132</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="RibbonStatusBar1.Location" type="System.Drawing.Point, System.Drawing">
|
<data name="RibbonStatusBar1.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
<value>0, 658</value>
|
<value>0, 662</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="RibbonStatusBar1.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="RibbonStatusBar1.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>1164, 26</value>
|
<value>1164, 22</value>
|
||||||
</data>
|
</data>
|
||||||
<data name=">>RibbonStatusBar1.Name" xml:space="preserve">
|
<data name=">>RibbonStatusBar1.Name" xml:space="preserve">
|
||||||
<value>RibbonStatusBar1</value>
|
<value>RibbonStatusBar1</value>
|
||||||
@@ -469,7 +496,7 @@
|
|||||||
<value>2</value>
|
<value>2</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="GridDocuments.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="GridDocuments.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>223, 473</value>
|
<value>223, 481</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="GridDocuments.TabIndex" type="System.Int32, mscorlib">
|
<data name="GridDocuments.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>0</value>
|
<value>0</value>
|
||||||
@@ -496,7 +523,7 @@
|
|||||||
<value>Ihre Dokumente</value>
|
<value>Ihre Dokumente</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="LayoutControl3.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="LayoutControl3.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>251, 526</value>
|
<value>251, 530</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="LayoutControl3.TabIndex" type="System.Int32, mscorlib">
|
<data name="LayoutControl3.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>1</value>
|
<value>1</value>
|
||||||
@@ -541,7 +568,7 @@
|
|||||||
<value>334, 17</value>
|
<value>334, 17</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<data name="GridReceivers.Location" type="System.Drawing.Point, System.Drawing">
|
<data name="GridReceivers.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
<value>14, 39</value>
|
<value>14, 35</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="colColor.Caption" xml:space="preserve">
|
<data name="colColor.Caption" xml:space="preserve">
|
||||||
<value> </value>
|
<value> </value>
|
||||||
@@ -635,7 +662,7 @@
|
|||||||
<value>Combo</value>
|
<value>Combo</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="GridReceivers.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="GridReceivers.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>871, 196</value>
|
<value>871, 200</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="GridReceivers.TabIndex" type="System.Int32, mscorlib">
|
<data name="GridReceivers.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>0</value>
|
<value>0</value>
|
||||||
@@ -728,13 +755,13 @@
|
|||||||
<value>0</value>
|
<value>0</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="txtMessage.Location" type="System.Drawing.Point, System.Drawing">
|
<data name="txtMessage.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
<value>23, 64</value>
|
<value>23, 60</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="txtMessage.Properties.Appearance.Font" type="System.Drawing.Font, System.Drawing">
|
<data name="txtMessage.Properties.Appearance.Font" type="System.Drawing.Font, System.Drawing">
|
||||||
<value>Segoe UI, 9.75pt</value>
|
<value>Segoe UI, 9.75pt</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="txtMessage.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="txtMessage.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>853, 172</value>
|
<value>853, 180</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="txtMessage.TabIndex" type="System.Int32, mscorlib">
|
<data name="txtMessage.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>2</value>
|
<value>2</value>
|
||||||
@@ -764,7 +791,7 @@
|
|||||||
<value>Ihre Nachricht</value>
|
<value>Ihre Nachricht</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="LayoutControl1.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="LayoutControl1.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>899, 259</value>
|
<value>899, 263</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="LayoutControl1.TabIndex" type="System.Int32, mscorlib">
|
<data name="LayoutControl1.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>0</value>
|
<value>0</value>
|
||||||
@@ -794,7 +821,7 @@
|
|||||||
<value>0, 0, 0, 0</value>
|
<value>0, 0, 0, 0</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="PanelControl2.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="PanelControl2.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>903, 263</value>
|
<value>903, 267</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="PanelControl2.TabIndex" type="System.Int32, mscorlib">
|
<data name="PanelControl2.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>1</value>
|
<value>1</value>
|
||||||
@@ -827,7 +854,7 @@
|
|||||||
<value>1</value>
|
<value>1</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="SplitContainerControl2.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="SplitContainerControl2.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>903, 526</value>
|
<value>903, 530</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="SplitContainerControl2.TabIndex" type="System.Int32, mscorlib">
|
<data name="SplitContainerControl2.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>0</value>
|
<value>0</value>
|
||||||
@@ -860,7 +887,7 @@
|
|||||||
<value>1</value>
|
<value>1</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="SplitContainerControl1.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="SplitContainerControl1.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>1164, 526</value>
|
<value>1164, 530</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="SplitContainerControl1.TabIndex" type="System.Int32, mscorlib">
|
<data name="SplitContainerControl1.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>1</value>
|
<value>1</value>
|
||||||
@@ -948,7 +975,7 @@
|
|||||||
<value>CenterScreen</value>
|
<value>CenterScreen</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="$this.Text" xml:space="preserve">
|
<data name="$this.Text" xml:space="preserve">
|
||||||
<value>Sign Flow - Umschlag-Editor</value>
|
<value>signFLOW - Umschlag-Editor</value>
|
||||||
</data>
|
</data>
|
||||||
<data name=">>SplashScreenManager1.Name" xml:space="preserve">
|
<data name=">>SplashScreenManager1.Name" xml:space="preserve">
|
||||||
<value>SplashScreenManager1</value>
|
<value>SplashScreenManager1</value>
|
||||||
@@ -1058,6 +1085,18 @@
|
|||||||
<data name=">>BarButtonItem2.Type" xml:space="preserve">
|
<data name=">>BarButtonItem2.Type" xml:space="preserve">
|
||||||
<value>DevExpress.XtraBars.BarButtonItem, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
|
<value>DevExpress.XtraBars.BarButtonItem, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name=">>BarButtonItem3.Name" xml:space="preserve">
|
||||||
|
<value>BarButtonItem3</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>BarButtonItem3.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=">>BarButtonItem4.Name" xml:space="preserve">
|
||||||
|
<value>BarButtonItem4</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>BarButtonItem4.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=">>RibbonPage1.Name" xml:space="preserve">
|
<data name=">>RibbonPage1.Name" xml:space="preserve">
|
||||||
<value>RibbonPage1</value>
|
<value>RibbonPage1</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -1094,6 +1133,12 @@
|
|||||||
<data name=">>RibbonPageGroupReceiver.Type" xml:space="preserve">
|
<data name=">>RibbonPageGroupReceiver.Type" xml:space="preserve">
|
||||||
<value>DevExpress.XtraBars.Ribbon.RibbonPageGroup, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
|
<value>DevExpress.XtraBars.Ribbon.RibbonPageGroup, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name=">>RibbonPageGroup2.Name" xml:space="preserve">
|
||||||
|
<value>RibbonPageGroup2</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>RibbonPageGroup2.Type" xml:space="preserve">
|
||||||
|
<value>DevExpress.XtraBars.Ribbon.RibbonPageGroup, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a</value>
|
||||||
|
</data>
|
||||||
<data name=">>LayoutControlGroup4.Name" xml:space="preserve">
|
<data name=">>LayoutControlGroup4.Name" xml:space="preserve">
|
||||||
<value>LayoutControlGroup4</value>
|
<value>LayoutControlGroup4</value>
|
||||||
</data>
|
</data>
|
||||||
|
|||||||
@@ -4,9 +4,12 @@ Imports System.IO
|
|||||||
Imports DevExpress.Export.Xl
|
Imports DevExpress.Export.Xl
|
||||||
Imports DevExpress.Utils.CommonDialogs
|
Imports DevExpress.Utils.CommonDialogs
|
||||||
Imports DevExpress.Utils.Drawing
|
Imports DevExpress.Utils.Drawing
|
||||||
|
Imports DevExpress.Utils.Svg.CommonSvgImages
|
||||||
Imports DevExpress.XtraEditors
|
Imports DevExpress.XtraEditors
|
||||||
Imports DevExpress.XtraExport.Helpers
|
Imports DevExpress.XtraExport.Helpers
|
||||||
Imports DevExpress.XtraGrid
|
Imports DevExpress.XtraGrid
|
||||||
|
Imports DevExpress.XtraGrid.Columns
|
||||||
|
Imports DevExpress.XtraGrid.Views.Base
|
||||||
Imports DevExpress.XtraGrid.Views.Grid
|
Imports DevExpress.XtraGrid.Views.Grid
|
||||||
Imports DevExpress.XtraSplashScreen
|
Imports DevExpress.XtraSplashScreen
|
||||||
Imports DigitalData.Modules.Base
|
Imports DigitalData.Modules.Base
|
||||||
@@ -30,6 +33,7 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Private Const COL_CODE = "AccessCode"
|
Private Const COL_CODE = "AccessCode"
|
||||||
|
|
||||||
Public Property State As State
|
Public Property State As State
|
||||||
|
Private TempFiles As TempFiles
|
||||||
|
|
||||||
Public Sub New()
|
Public Sub New()
|
||||||
InitializeComponent()
|
InitializeComponent()
|
||||||
@@ -40,30 +44,30 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
'SaveEnvelopeWithValidation()
|
'SaveEnvelopeWithValidation()
|
||||||
' If Not IsNothing(Envelope) Then
|
' If Not IsNothing(Envelope) Then
|
||||||
Try
|
Try
|
||||||
' prüfen ob es schon eine Datei gibt
|
' prüfen ob es schon eine Datei gibt
|
||||||
If Documents.Count > 0 Then
|
If Documents.Count > 0 Then
|
||||||
MsgBox(Resources.Envelope.Only_one_file_is_allowed, MsgBoxStyle.Information, Text)
|
MsgBox(Resources.Envelope.Only_one_file_is_allowed, MsgBoxStyle.Information, Text)
|
||||||
Return
|
Return
|
||||||
|
End If
|
||||||
|
|
||||||
|
If OpenFileDialog1.ShowDialog() = DialogResult.OK Then
|
||||||
|
Dim oDocument = Await Controller.CreateDocument(OpenFileDialog1.FileName)
|
||||||
|
|
||||||
|
If oDocument IsNot Nothing Then
|
||||||
|
Documents.Add(oDocument)
|
||||||
|
' Update_File_DB(OpenFileDialog1.FileName)
|
||||||
|
Else
|
||||||
|
MsgBox(Resources.Envelope.Document_Could_Not_Be_Saved, MsgBoxStyle.Critical, Text)
|
||||||
End If
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
If OpenFileDialog1.ShowDialog() = DialogResult.OK Then
|
Catch ex As Exception
|
||||||
Dim oDocument = Await Controller.CreateDocument(OpenFileDialog1.FileName)
|
Logger.Error(ex)
|
||||||
|
Finally
|
||||||
|
SplashScreenManager.CloseOverlayForm(oHandle)
|
||||||
|
|
||||||
If oDocument IsNot Nothing Then
|
RibbonPageGroupAddSignature_Enabled()
|
||||||
Documents.Add(oDocument)
|
End Try
|
||||||
' Update_File_DB(OpenFileDialog1.FileName)
|
|
||||||
Else
|
|
||||||
MsgBox(Resources.Envelope.Document_Could_Not_Be_Saved, MsgBoxStyle.Critical, Text)
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
Catch ex As Exception
|
|
||||||
Logger.Error(ex)
|
|
||||||
Finally
|
|
||||||
SplashScreenManager.CloseOverlayForm(oHandle)
|
|
||||||
|
|
||||||
RibbonPageGroupAddSignature_Enabled()
|
|
||||||
End Try
|
|
||||||
' Else
|
' Else
|
||||||
' SplashScreenManager.CloseOverlayForm(oHandle)
|
' SplashScreenManager.CloseOverlayForm(oHandle)
|
||||||
' End If
|
' End If
|
||||||
@@ -72,6 +76,8 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Private Sub frmEditor_Load(sender As Object, e As EventArgs) Handles Me.Load
|
Private Sub frmEditor_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||||
Logger = State.LogConfig.GetLogger()
|
Logger = State.LogConfig.GetLogger()
|
||||||
Logger.Debug("Loading Configuration..")
|
Logger.Debug("Loading Configuration..")
|
||||||
|
TempFiles = New TempFiles(State.LogConfig)
|
||||||
|
TempFiles.Create()
|
||||||
If Envelope Is Nothing Then
|
If Envelope Is Nothing Then
|
||||||
Controller = New EnvelopeEditorController(State)
|
Controller = New EnvelopeEditorController(State)
|
||||||
|
|
||||||
@@ -93,6 +99,24 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Receivers = New BindingList(Of EnvelopeReceiver)(Controller.Envelope.Receivers)
|
Receivers = New BindingList(Of EnvelopeReceiver)(Controller.Envelope.Receivers)
|
||||||
|
|
||||||
For Each docItem As EnvelopeDocument In Documents
|
For Each docItem As EnvelopeDocument In Documents
|
||||||
|
If Not File.Exists(docItem.Filepath) Then
|
||||||
|
Dim oTempFolder = TempFiles.TempPath
|
||||||
|
Dim oTempFilename = String.Concat(oTempFolder, "\", $"ViewEnvDoc_{Envelope.Id}.pdf")
|
||||||
|
If File.Exists(oTempFilename) Then
|
||||||
|
Try
|
||||||
|
File.OpenWrite(oTempFilename)
|
||||||
|
Catch ex As Exception
|
||||||
|
MsgBox("File might already be open?", MsgBoxStyle.Exclamation)
|
||||||
|
Me.Cursor = Cursors.Default
|
||||||
|
Exit Sub
|
||||||
|
End Try
|
||||||
|
|
||||||
|
|
||||||
|
File.Delete(oTempFilename)
|
||||||
|
End If
|
||||||
|
WriteBytetoPath(oTempFilename, docItem.Byte_Data)
|
||||||
|
docItem.Filepath = oTempFilename
|
||||||
|
End If
|
||||||
If docItem.Thumbnail Is Nothing Then
|
If docItem.Thumbnail Is Nothing Then
|
||||||
docItem.Thumbnail = Controller.CreateThumbnail(docItem.Filepath)
|
docItem.Thumbnail = Controller.CreateThumbnail(docItem.Filepath)
|
||||||
docItem.PageCount = Controller.GetPageCount(docItem.Filepath)
|
docItem.PageCount = Controller.GetPageCount(docItem.Filepath)
|
||||||
@@ -141,6 +165,8 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Dim oDocument As EnvelopeDocument = DirectCast(ViewDocuments.GetFocusedRow(), EnvelopeDocument)
|
Dim oDocument As EnvelopeDocument = DirectCast(ViewDocuments.GetFocusedRow(), EnvelopeDocument)
|
||||||
If Controller.DeleteDocument(oDocument) Then
|
If Controller.DeleteDocument(oDocument) Then
|
||||||
Documents.Remove(oDocument)
|
Documents.Remove(oDocument)
|
||||||
|
GridDocuments.DataSource = Nothing
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
@@ -163,6 +189,19 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
|
|
||||||
If ViewDocuments.GetSelectedRows().Count > 0 Then
|
If ViewDocuments.GetSelectedRows().Count > 0 Then
|
||||||
Dim oDocument As EnvelopeDocument = DirectCast(ViewDocuments.GetFocusedRow(), EnvelopeDocument)
|
Dim oDocument As EnvelopeDocument = DirectCast(ViewDocuments.GetFocusedRow(), EnvelopeDocument)
|
||||||
|
Dim oEnvelope = Controller.Envelope
|
||||||
|
If Not IsNothing(oDocument.Byte_Data) Then
|
||||||
|
Dim oTempFolder = TempFiles.TempPath
|
||||||
|
Dim oTempFilename = String.Concat(oTempFolder, "\", $"ViewEnvDoc_{oEnvelope.Id}.pdf")
|
||||||
|
If Not File.Exists(oTempFilename) Then
|
||||||
|
WriteBytetoPath(oTempFilename, oDocument.Byte_Data)
|
||||||
|
oDocument.Filepath = oTempFilename
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Dim oGDPictureKey As String = MS_GDPICTUREKEY
|
Dim oGDPictureKey As String = MS_GDPICTUREKEY
|
||||||
|
|
||||||
Dim oForm As New frmFieldEditor(State) With {
|
Dim oForm As New frmFieldEditor(State) With {
|
||||||
@@ -180,7 +219,23 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
SplashScreenManager.CloseOverlayForm(oHandle)
|
SplashScreenManager.CloseOverlayForm(oHandle)
|
||||||
End Try
|
End Try
|
||||||
End Sub
|
End Sub
|
||||||
|
Private Sub WriteBytetoPath(ByVal sFileName As String, pByte As Byte())
|
||||||
|
|
||||||
|
'For Document
|
||||||
|
Try
|
||||||
|
If Not pByte Is Nothing Then
|
||||||
|
'Read image data into a file stream
|
||||||
|
Using fs As New FileStream(sFileName, FileMode.OpenOrCreate, FileAccess.Write)
|
||||||
|
fs.Write(pByte, 0, pByte.Length)
|
||||||
|
'Set image variable value using memory stream.
|
||||||
|
fs.Flush()
|
||||||
|
fs.Close()
|
||||||
|
End Using
|
||||||
|
End If
|
||||||
|
Catch ex As Exception
|
||||||
|
MsgBox(ex.Message, MsgBoxStyle.Exclamation, "Error in downloadFile")
|
||||||
|
End Try
|
||||||
|
End Sub
|
||||||
Private Function SaveEnvelopeWithValidation() As Boolean
|
Private Function SaveEnvelopeWithValidation() As Boolean
|
||||||
Return SaveEnvelope(True)
|
Return SaveEnvelope(True)
|
||||||
End Function
|
End Function
|
||||||
@@ -479,7 +534,12 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
RibbonPageGroupAddSignature_Enabled()
|
RibbonPageGroupAddSignature_Enabled()
|
||||||
End Sub
|
End Sub
|
||||||
Dim CellValueChanged As Boolean = False
|
Dim CellValueChanged As Boolean = False
|
||||||
|
Private Sub ViewReceivers_ColumnPositionChanged(sender As Object, e As EventArgs) Handles ViewReceivers.ColumnPositionChanged
|
||||||
|
|
||||||
|
|
||||||
|
End Sub
|
||||||
Private Sub ViewReceivers_CellValueChanged(sender As Object, e As Views.Base.CellValueChangedEventArgs) Handles ViewReceivers.CellValueChanged
|
Private Sub ViewReceivers_CellValueChanged(sender As Object, e As Views.Base.CellValueChangedEventArgs) Handles ViewReceivers.CellValueChanged
|
||||||
|
|
||||||
If e.Column.FieldName = COL_EMAIL And CellValueChanged = False Then
|
If e.Column.FieldName = COL_EMAIL And CellValueChanged = False Then
|
||||||
If e.Value Is Nothing Then
|
If e.Value Is Nothing Then
|
||||||
' Keine E-Mail-Adresse, also weg damit
|
' Keine E-Mail-Adresse, also weg damit
|
||||||
@@ -491,21 +551,57 @@ Partial Public Class frmEnvelopeEditor
|
|||||||
Dim oNameCellValue = ViewReceivers.GetRowCellValue(e.RowHandle, COL_NAME)
|
Dim oNameCellValue = ViewReceivers.GetRowCellValue(e.RowHandle, COL_NAME)
|
||||||
If oNameCellValue Is Nothing Then
|
If oNameCellValue Is Nothing Then
|
||||||
Dim oEmailAdress As String = DirectCast(e.Value.ToString.ToLower, String)
|
Dim oEmailAdress As String = DirectCast(e.Value.ToString.ToLower, String)
|
||||||
|
oEmailAdress = Trim(oEmailAdress)
|
||||||
|
If IsValidEmailAddress(oEmailAdress) = True Then
|
||||||
|
Dim oLastName As String = Controller.GetLastNameByEmailAdress(oEmailAdress)
|
||||||
|
Dim oAccessCode As String = Helpers.GetAccessCode()
|
||||||
|
ViewReceivers.SetRowCellValue(e.RowHandle, ViewReceivers.Columns.Item(COL_EMAIL), oEmailAdress)
|
||||||
|
ViewReceivers.SetRowCellValue(e.RowHandle, ViewReceivers.Columns.Item(COL_NAME), oLastName)
|
||||||
|
ViewReceivers.SetRowCellValue(e.RowHandle, ViewReceivers.Columns.Item(COL_CODE), oAccessCode)
|
||||||
|
CellValueChanged = False
|
||||||
|
Else
|
||||||
|
Dim oMsg = Resources.Envelope.Error_email_Validation
|
||||||
|
oMsg = oMsg.Replace("@Mail", oEmailAdress)
|
||||||
|
MsgBox(oMsg, MsgBoxStyle.Exclamation, Text)
|
||||||
|
ViewReceivers.DeleteRow(ViewReceivers.FocusedRowHandle)
|
||||||
|
End If
|
||||||
|
|
||||||
Dim oLastName As String = Controller.GetLastNameByEmailAdress(oEmailAdress)
|
|
||||||
Dim oAccessCode As String = Helpers.GetAccessCode()
|
|
||||||
ViewReceivers.SetRowCellValue(e.RowHandle, ViewReceivers.Columns.Item(COL_EMAIL), oEmailAdress)
|
|
||||||
ViewReceivers.SetRowCellValue(e.RowHandle, ViewReceivers.Columns.Item(COL_NAME), oLastName)
|
|
||||||
ViewReceivers.SetRowCellValue(e.RowHandle, ViewReceivers.Columns.Item(COL_CODE), oAccessCode)
|
|
||||||
CellValueChanged = False
|
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
Private Sub email_validation()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Function IsValidEmailAddress(pEmailAddress As String) As Boolean
|
||||||
|
Try
|
||||||
|
If pEmailAddress.Contains("@") Then
|
||||||
|
Dim oAddress = New System.Net.Mail.MailAddress(pEmailAddress)
|
||||||
|
Return oAddress.Address = pEmailAddress
|
||||||
|
Else
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
Catch ex As Exception
|
||||||
|
Logger.Error(ex)
|
||||||
|
Return False
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
Private Sub RibbonControl1_Click(sender As Object, e As EventArgs) Handles RibbonControl1.Click
|
Private Sub RibbonControl1_Click(sender As Object, e As EventArgs) Handles RibbonControl1.Click
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub BarButtonItem3_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem3.ItemClick
|
||||||
|
frmChooseDocVariant.ShowDialog()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub BarButtonItem4_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem4.ItemClick
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub ViewReceivers_CellValueChanging(sender As Object, e As CellValueChangedEventArgs) Handles ViewReceivers.CellValueChanging
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -220,6 +220,9 @@
|
|||||||
<data name=">>btCancel.ZOrder" xml:space="preserve">
|
<data name=">>btCancel.ZOrder" xml:space="preserve">
|
||||||
<value>7</value>
|
<value>7</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="cmbCertificationType.Enabled" type="System.Boolean, mscorlib">
|
||||||
|
<value>False</value>
|
||||||
|
</data>
|
||||||
<data name="cmbCertificationType.Location" type="System.Drawing.Point, System.Drawing">
|
<data name="cmbCertificationType.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
<value>207, 162</value>
|
<value>207, 162</value>
|
||||||
</data>
|
</data>
|
||||||
|
|||||||
@@ -299,6 +299,6 @@
|
|||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="$this.Text" xml:space="preserve">
|
<data name="$this.Text" xml:space="preserve">
|
||||||
<value>Sign Flow - Signature-Editor</value>
|
<value>signFLOW - Signature-Editor</value>
|
||||||
</data>
|
</data>
|
||||||
</root>
|
</root>
|
||||||
@@ -538,7 +538,7 @@
|
|||||||
<value>CenterScreen</value>
|
<value>CenterScreen</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="$this.Text" xml:space="preserve">
|
<data name="$this.Text" xml:space="preserve">
|
||||||
<value>Sign Flow - Signatur-Editor</value>
|
<value>signFLOW - Signatur-Editor</value>
|
||||||
</data>
|
</data>
|
||||||
<data name=">>BarButtonItem1.Name" xml:space="preserve">
|
<data name=">>BarButtonItem1.Name" xml:space="preserve">
|
||||||
<value>BarButtonItem1</value>
|
<value>BarButtonItem1</value>
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user