From 348a55fc60481dc5e1355b2d0d2e026b5e78e7fd Mon Sep 17 00:00:00 2001 From: Developer 02 Date: Fri, 16 Jan 2026 00:59:23 +0100 Subject: [PATCH] Add UpdateEndpointProcedure record for endpoint updates A new `UpdateEndpointProcedure` record was introduced in the `ReC.Application.Common.Procedures.UpdateProcedure` namespace. This record implements the `IUpdateProcedure` interface and includes nullable properties `Active`, `Description`, and `Uri`. The `ToObjectProcedure` method was added to convert the record into an `UpdateObjectProcedure` instance, setting the `Entity` to `"ENDPOINT"`, the `Guid` to the provided parameter, and the `Endpoint` to the current instance. The method also supports tracking changes via the optional `changedWho` parameter. --- .../UpdateProcedure/UpdateEndpointProcedure.cs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/ReC.Application/Common/Procedures/UpdateProcedure/UpdateEndpointProcedure.cs diff --git a/src/ReC.Application/Common/Procedures/UpdateProcedure/UpdateEndpointProcedure.cs b/src/ReC.Application/Common/Procedures/UpdateProcedure/UpdateEndpointProcedure.cs new file mode 100644 index 0000000..ab2ada3 --- /dev/null +++ b/src/ReC.Application/Common/Procedures/UpdateProcedure/UpdateEndpointProcedure.cs @@ -0,0 +1,18 @@ +namespace ReC.Application.Common.Procedures.UpdateProcedure; + +public record UpdateEndpointProcedure : IUpdateProcedure +{ + public bool? Active { get; set; } + public string? Description { get; set; } + public string? Uri { get; set; } + + public UpdateObjectProcedure ToObjectProcedure(long guid, string? changedWho = null) + { + return new UpdateObjectProcedure + { + Entity = "ENDPOINT", + Guid = guid, + Endpoint = this + }.ChangedBy(changedWho); + } +}