32 lines
644 B
C#
Raw Normal View History

2024-04-16 16:17:48 -05:00
using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace DAL.Models.Audits
{
[Table("audit_grants")]
[Index("id", Name = "audit_grants_grants_id_fk")]
[Keyless]
2024-04-22 17:34:27 -05:00
public class AuditGrant : AuditModel<Grant>
2024-04-16 16:17:48 -05:00
{
[Column("name")]
[MaxLength(128)]
public string name { get; set; } = null!;
[Column("permissionId")]
public ulong permissionId { get; set; }
2024-04-22 17:34:27 -05:00
public override Grant adaptToModel()
{
return new Grant
{
id = id,
name = name,
permissionId = permissionId,
updated = updated,
updater = updater
};
}
2024-04-16 16:17:48 -05:00
}
}