Refactor: Replace EnvelopeType with EnvelopeTypeDefaults
Replaced the `EnvelopeType` class with `EnvelopeTypeDefaults` across the codebase to standardize the data model. Updated DTOs, repositories, services, mappings, and database contexts to reflect this change. Key updates include: - Updated `EnvelopeDto` to use `EnvelopeTypeDefaults`. - Modified `IEnvelopeTypeRepository` and `IEnvelopeTypeService` interfaces. - Adjusted mappings in `MappingProfile.cs` for `EnvelopeTypeDefaults`. - Updated `ReadEnvelopeTypesQueryHandler` and `CreateEnvelopeCommandHandler` to use `EnvelopeTypeDefaults`. - Replaced `EnvelopeType` with `EnvelopeTypeDefaults` in `EnvelopeTypeModel.vb`, `frmEnvelopeMainData.vb`, and `EGDbContextBase`. - Introduced the `EnvelopeTypeDefaults` class with updated schema mappings. - Updated `EnvelopeTypeRepository` and `TestEnvelopeTypeController` to use `EnvelopeTypeDefaults`. These changes ensure consistency and improve maintainability across the application.
This commit is contained in:
@@ -41,7 +41,7 @@ public class CreateEnvelopeCommandHandler(IServiceProvider Provider, IMapper Map
|
||||
|
||||
private IRepository<EnvelopeReceiver> EnvelopeReceiverRepository => Provider.GetRequiredService<IRepository<EnvelopeReceiver>>();
|
||||
|
||||
private IRepository<EnvelopeType> EnvelopeTypeRepository => Provider.GetRequiredService<IRepository<EnvelopeType>>();
|
||||
private IRepository<EnvelopeTypeDefaults> EnvelopeTypeRepository => Provider.GetRequiredService<IRepository<EnvelopeTypeDefaults>>();
|
||||
|
||||
private IRepository<Receiver> ReceiverRepository => Provider.GetRequiredService<IRepository<Receiver>>();
|
||||
|
||||
@@ -233,7 +233,7 @@ public class CreateEnvelopeCommandHandler(IServiceProvider Provider, IMapper Map
|
||||
|
||||
private async Task<EnvelopeSettings> ResolveEnvelopeSettingsAsync(CreateEnvelopeCommand request, Envelope? existing, CancellationToken cancel)
|
||||
{
|
||||
EnvelopeType? selectedType = null;
|
||||
EnvelopeTypeDefaults? selectedType = null;
|
||||
if (request.EnvelopeTypeId is int envelopeTypeId && envelopeTypeId > 0)
|
||||
{
|
||||
selectedType = await EnvelopeTypeRepository.Query
|
||||
|
||||
Reference in New Issue
Block a user