Files
jdescopingtool/OLD/DataModel/Models/SearchUpdate.cs
T
Joseph Doherty 26ff8d9b4f Initial commit: JDE Scoping Tool migration project
Set up repository with legacy .NET Framework 4.8 source (OLD/),
new .NET 10 Blazor solution (NEW/), OpenSpec specifications,
documentation, and project configuration.
2026-01-02 07:43:29 -05:00

77 lines
2.0 KiB
C#
Executable File

using System;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
namespace DataModel.Models
{
/// <summary>
/// Search status update message
/// </summary>
public class SearchUpdate
{
/// <summary>
/// Search PK ID
/// </summary>
public int ID { get; set; }
/// <summary>
/// User name of user that submitted search
/// </summary>
public string UserName { get; set; }
/// <summary>
/// Name of user that submitted search
/// </summary>
public string Name { get; set; }
/// <summary>
/// Search status code
/// </summary>
[JsonConverter(typeof(StringEnumConverter))]
public SearchStatus Status { get; set; }
/// <summary>
/// Timestamp search was submitted
/// </summary>
public DateTime? SubmitDT { get; set; }
/// <summary>
/// Timestamp search was started
/// </summary>
public DateTime? StartDT { get; set; }
/// <summary>
/// Timestamp search was completed
/// </summary>
public DateTime? EndDT { get; set; }
/// <summary>
/// Timestamp when update was generated
/// </summary>
public DateTime Timestamp { get; set; }
/// <summary>
/// Constructor
/// </summary>
public SearchUpdate()
{
}
/// <summary>
/// Constructor
/// </summary>
/// <param name="search">Search to copy values from</param>
public SearchUpdate(Search search)
{
ID = search.ID;
UserName = search.UserName;
Name = search.Name;
Status = search.Status;
SubmitDT = search.SubmitDT;
StartDT = search.StartDT;
EndDT = search.EndDT;
Timestamp = DateTime.Now;
}
}
}