From ae32af3c9f2eac095b57379c79359755f69bfa82 Mon Sep 17 00:00:00 2001 From: David Meincke Date: Tue, 30 May 2023 10:26:59 +0200 Subject: [PATCH] add timestamp --- .gitignore | 1 + Application/Helpers/SessionFiles.cs | 3 ++- Application/Session.cs | 1 + 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 83129e6..53230b0 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ /Application/bin /Application/obj /Application/Properties +/.vs/ProjectEvaluation diff --git a/Application/Helpers/SessionFiles.cs b/Application/Helpers/SessionFiles.cs index 1968784..70fe251 100644 --- a/Application/Helpers/SessionFiles.cs +++ b/Application/Helpers/SessionFiles.cs @@ -131,7 +131,8 @@ namespace CodeEditorApi.Helpers var session = new Session { Id = Guid.Parse(strId), - NumberOfChanges = files.Length + NumberOfChanges = files.Length, + Timestamp = Directory.GetCreationTime(path) }; return session; diff --git a/Application/Session.cs b/Application/Session.cs index 8a3d5ac..e2ef29c 100644 --- a/Application/Session.cs +++ b/Application/Session.cs @@ -4,5 +4,6 @@ { public Guid Id { get; set; } public int NumberOfChanges { get; set; } + public DateTime Timestamp { get; set; } } }