using System; using FreeSql.DataAnnotations; using System.ComponentModel.DataAnnotations; using System.Collections.Generic; namespace Admin.Core.Model.Admin { /// /// 用户 /// [Table(Name = "ad_user")] [Index("uk_user_username", nameof(UserName), true)] public class UserEntity: EntityBase { /// /// 账号 /// [Column(StringLength = 60)] public string UserName { get; set; } /// /// 密码 /// [Column(StringLength = 60)] public string Password { get; set; } /// /// 昵称 /// [Column(StringLength = 60)] public string NickName { get; set; } /// /// 头像 /// [Column(StringLength = 100)] public string Avatar { get; set; } /// /// 状态 /// public int Status { get; set; } /// /// 备注 /// [Column(StringLength = 500)] public string Remark { get; set; } [Navigate(ManyToMany = typeof(UserRoleEntity))] public ICollection Roles { get; set; } } }