From 9cf7900fd2c45c11ff24aafee0cd59ae4ecafda7 Mon Sep 17 00:00:00 2001 From: tschumpr Date: Mon, 26 Feb 2024 11:18:02 +0100 Subject: [PATCH] Add kind for date --- src/api/Controllers/StratigraphyController.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/api/Controllers/StratigraphyController.cs b/src/api/Controllers/StratigraphyController.cs index 5296c7469..e8513645f 100644 --- a/src/api/Controllers/StratigraphyController.cs +++ b/src/api/Controllers/StratigraphyController.cs @@ -260,6 +260,7 @@ public override async Task> EditAsync(Stratigraphy en return Problem("The borehole is locked by another user or you are missing permissions."); } + entity.Date = entity.Date != null ? DateTime.SpecifyKind(entity.Date.Value, DateTimeKind.Utc) : null; var editResult = await base.EditAsync(entity).ConfigureAwait(false); if (editResult.Result is not OkObjectResult) return editResult;