Files
EnvelopeGenerator/EnvelopeGenerator.Application/DocStatus/Commands/ModifyDocStatusCommandBase.cs
TekH 01f3335238 Refactor ModifyDocStatusCommandBase properties
Replaced computed EnvelopeId and ReceiverId with virtual settable properties for greater flexibility. Removed Status, Receiver, and StatusChangedWhen properties. Made Value property virtual and cleaned up related code and comments.
2026-02-19 14:32:35 +01:00

38 lines
977 B
C#

using EnvelopeGenerator.Application.Common.Query;
namespace EnvelopeGenerator.Application.DocStatus.Commands;
/// <summary>
///
/// </summary>
public record ModifyDocStatusCommandBase : EnvelopeReceiverQueryBase
{
/// <summary>
///
/// </summary>
public virtual int EnvelopeId { get; set; }
/// <summary>
///
/// </summary>
public virtual int ReceiverId { get; set; }
/// <summary>
/// Gets or sets the display value associated with the status.
/// </summary>
public virtual string? Value { get; set; }
/// <summary>
/// Maps the current command to a new instance of the specified type.
/// </summary>
/// <typeparam name="TDest"></typeparam>
/// <returns></returns>
public TDest To<TDest>() where TDest : ModifyDocStatusCommandBase, new()
=> new()
{
Key = Key,
Envelope = Envelope,
Receiver = Receiver,
Value = Value
};
}