using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using Microsoft.EntityFrameworkCore; namespace IM_API.Models; [Table("roles")] [MySqlCharSet("utf8mb4")] [MySqlCollation("utf8mb4_general_ci")] public partial class Role { [Key] [Column("ID", TypeName = "int(11)")] public int Id { get; set; } /// /// 角色名称 /// [StringLength(20)] public string Name { get; set; } = null!; /// /// 角色描述 /// [Column(TypeName = "text")] public string Description { get; set; } = null!; /// /// 创建时间 /// [Column(TypeName = "datetime")] public DateTime Created { get; set; } [InverseProperty("Role")] public virtual ICollection Admins { get; set; } = new List(); [InverseProperty("RoleldNavigation")] public virtual ICollection Permissionaroles { get; set; } = new List(); }