33 lines
656 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_images")]
[Index("id", Name = "audit_images_images_id_fk")]
[Keyless]
2024-04-22 17:34:27 -05:00
public class AuditImage : AuditModel<Image>
2024-04-16 16:17:48 -05:00
{
[Column("name")]
[MaxLength(64)]
public string name { get; set; } = null!;
[Column("filename")]
[MaxLength(128)]
public string filename { get; set; } = null!;
2024-04-22 17:34:27 -05:00
public override Image adaptToModel()
{
return new Image
{
id = id,
name = name,
filename = filename,
updated = updated,
updater = updater
};
}
2024-04-16 16:17:48 -05:00
}
}