From d7f782808303d9a64098265954b7a34d325767b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Zieli=C5=84ski?= Date: Mon, 3 Mar 2025 08:53:48 +0100 Subject: [PATCH] Include modified by --- WebAPI/Controllers/LayersController.cs | 1 + WebAPI/Helpers/DbSeed/Admin-Monthly/CreateImportWorker.sql | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/WebAPI/Controllers/LayersController.cs b/WebAPI/Controllers/LayersController.cs index 202a542..a2f1a68 100644 --- a/WebAPI/Controllers/LayersController.cs +++ b/WebAPI/Controllers/LayersController.cs @@ -73,6 +73,7 @@ public class LayersController : Controller { return Ok(_db.Layers .Include(x => x.CreatedBy) + .Include(x => x.ModifiedBy) .Include(x => x.Records).AsNoTracking().First(x => x.Id == id && !x.IsDeleted)); } catch (Exception e) diff --git a/WebAPI/Helpers/DbSeed/Admin-Monthly/CreateImportWorker.sql b/WebAPI/Helpers/DbSeed/Admin-Monthly/CreateImportWorker.sql index 05a0d4b..aa5db40 100644 --- a/WebAPI/Helpers/DbSeed/Admin-Monthly/CreateImportWorker.sql +++ b/WebAPI/Helpers/DbSeed/Admin-Monthly/CreateImportWorker.sql @@ -111,6 +111,6 @@ VALUES ((SELECT NEWID()), 'IsEnabled', 'True', GETDATE(), GETDATE(), '117be4f0-b INSERT INTO [diunabi-morska].[dbo].[Records] ([Id], [Code], [Desc1], [CreatedAt], [ModifiedAt], [CreatedById], [ModifiedById], [IsDeleted], [LayerId]) -VALUES ((SELECT NEWID()), 'ImportType', 'Standard', GETDATE(), GETDATE(), '117be4f0-b5d1-41a1-a962-39dc30cce368', '117be4f0-b5d1-41a1-a962-39dc30cce368', 0, @LayerId); +VALUES ((SELECT NEWID()), 'ImportType', @ImportType, GETDATE(), GETDATE(), '117be4f0-b5d1-41a1-a962-39dc30cce368', '117be4f0-b5d1-41a1-a962-39dc30cce368', 0, @LayerId); SELECT 'ImportWorker created' AS Logger; \ No newline at end of file