using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Microsoft.EntityFrameworkCore;

namespace Managing.Infrastructure.Databases.PostgreSql.Entities;

[Table("Users")]
[Index(nameof(Name), IsUnique = true)]
public class UserEntity
{
    [Key] public int Id { get; set; }
    [Required] [MaxLength(255)] public required string Name { get; set; }
    [MaxLength(255)] public string? AgentName { get; set; }
    public string? AvatarUrl { get; set; }
    public string? TelegramChannel { get; set; }
}