ProjectLib/ProjectLibrary/Entites/Reader.cs

22 lines
667 B
C#

namespace ProjectLibrary.Entities
{
public class Reader
{
public int Id { get; private set; }
public string Name { get; private set; } = string.Empty;
public int ReaderTicket { get; private set; }
public DateTime RegistrationDateRT { get; private set; } // Изменение на DateTime
public static Reader CreateEntity(int id, string name, int readerTicket)
{
return new Reader
{
Id = id,
Name = name ?? string.Empty,
ReaderTicket = readerTicket,
RegistrationDateRT = DateTime.Now
};
}
}
}