Updated RecentReceiverSuggestionDto to use `init` properties, adding immutability and a new `LastUsedAt` field. Refactored ReadRecentReceiverSuggestionsQueryHandler to simplify query logic, remove `IMapper` dependency, and improve determinism in results. Introduced tie-breaking for duplicate timestamps and optimized ordering by `LastUsedAt` and `EmailAddress`. Removed redundant `Include` and mapping steps for clarity.
11 lines
270 B
C#
11 lines
270 B
C#
namespace EnvelopeGenerator.Application.Common.Dto.Receiver;
|
|
|
|
public class RecentReceiverSuggestionDto
|
|
{
|
|
public required string FullName { get; init; }
|
|
|
|
public required string EmailAddress { get; init; }
|
|
|
|
public required DateTime LastUsedAt { get; init; }
|
|
}
|