Normalize certification type handling

Introduce `NormalizeCertificationType` method to ensure consistent handling of certification types across the application. Update `CreateEnvelopeCommandHandler`, `CreateEnvelopeWizardPopup.razor`, and `SenderEditorPage.razor` to use this method. Modify `CertificationType` enum to include `ElectronicSignature` and remove `QualifiedSignature`. Update UI components to reflect these changes by removing the `QualifiedSignature` option.
This commit is contained in:
2026-10-26 16:58:06 +01:00
parent 4dcfe67038
commit ae1ecbc15f
5 changed files with 33 additions and 13 deletions

View File

@@ -267,10 +267,10 @@ public class CreateEnvelopeCommandHandler : IRequestHandler<CreateEnvelopeComman
EnvelopeTypeId: request.EnvelopeTypeId ?? existing?.EnvelopeTypeId,
Language: ResolveLanguage(request.Language, selectedType?.Language, existing?.Language),
UseAccessCode: useAccessCode,
CertificationType: request.CertificationType
CertificationType: NormalizeCertificationType(request.CertificationType
?? (int?)selectedType?.CertificationType
?? existing?.CertificationType
?? (int)CertificationType.AdvancedElectronicSignature,
?? (int)CertificationType.AdvancedElectronicSignature),
FinalEmailToCreator: request.FinalEmailToCreator
?? (int?)selectedType?.FinalEmailToCreator
?? existing?.FinalEmailToCreator
@@ -316,6 +316,13 @@ public class CreateEnvelopeCommandHandler : IRequestHandler<CreateEnvelopeComman
return "de-DE";
}
private static int NormalizeCertificationType(int value)
{
return value == 2
? 2
: (int)CertificationType.AdvancedElectronicSignature;
}
private sealed record EnvelopeSettings(
int? EnvelopeTypeId,
string Language,