TekH 5ee9efbcd9 Refactor user-related classes and properties
- Added parameterless and user-initializing constructors to `EGUser`.
- Removed unnecessary `using` directives and `#if NETFRAMEWORK` from `EGUser.cs`, `Envelope.cs`, and `EnvelopeHistory.cs`.
- Replaced `EGUser` property with `User` in `Envelope.cs` and `EnvelopeHistory.cs`.
- Retained default value for `CURRENT_WORK_APP` in `Envelope.cs`.
2025-06-26 16:21:22 +02:00

47 lines
1.2 KiB
C#

using System.ComponentModel.DataAnnotations.Schema;
using DigitalData.UserManager.Domain.Entities;
namespace EnvelopeGenerator.Domain.Entities
{
[Table("TBDD_USER", Schema = "dbo")]
public class EGUser : User
{
public EGUser()
{
}
public EGUser(User user)
{
Id = user.Id;
Prename = user.Prename;
Name = user.Name;
Username = user.Username;
Shortname = user.Shortname;
Email = user.Email;
Language = user.Language;
Comment = user.Comment;
Deleted = user.Deleted;
DateFormat = user.DateFormat;
Active = user.Active;
GeneralViewer = user.GeneralViewer;
WanEnvironment = user.WanEnvironment;
UserIdFkIntEcm = user.UserIdFkIntEcm;
DeletedWhen = user.DeletedWhen;
DeletedWho = user.DeletedWho;
}
#region FORM_APP
[NotMapped]
public bool HasAccess { get; set; }
[NotMapped]
public bool IsAdmin { get; set; }
[NotMapped]
public bool GhostModeActive { get; set; }
[NotMapped]
public string FullName => $"{Prename} {Name}";
#endregion
}
}