using System; using LEA.Data; using LEA.Models; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Metadata; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; using Pomelo.EntityFrameworkCore.MySql.Metadata; #nullable disable namespace LEA.Migrations { [DbContext(typeof(AppDbContext))] partial class AppDbContextModelSnapshot : ModelSnapshot { protected override void BuildModel(ModelBuilder modelBuilder) { modelBuilder .HasAnnotation("ProductVersion", "8.0.8") .HasAnnotation("Relational:MaxIdentifierLength", 64); MySqlModelBuilderExtensions.HasCharSet(modelBuilder, "utf8mb4"); modelBuilder.Entity("LEA.Models.Application", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int") .HasAnnotation("MySql:ValueGenerationStrategy", MySqlValueGenerationStrategy.IdentityColumn); b.Property("AppliedOn") .HasColumnType("date"); b.Property("Company") .IsRequired() .HasMaxLength(150) .HasColumnType("varchar(150)"); b.Property("Notes") .HasColumnType("longtext"); b.Property("Role") .IsRequired() .HasMaxLength(150) .HasColumnType("varchar(150)"); b.Property("Source") .HasMaxLength(200) .HasColumnType("varchar(200)"); b.Property("Status") .HasMaxLength(50) .HasColumnType("varchar(50)") .HasConversion(); b.Property("UpdatedAt") .HasColumnType("datetime(6)"); b.Property("UserId") .IsRequired() .HasColumnType("varchar(255)"); b.HasKey("Id"); b.HasIndex("UserId"); b.ToTable("Applications"); b.HasOne("LEA.Models.ApplicationUser", "User") .WithMany() .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Contact"); b.Navigation("User"); }); modelBuilder.Entity("LEA.Models.ApplicationUser", b => { b.Property("Id") .HasColumnType("varchar(255)"); b.Property("AccessFailedCount") .HasColumnType("int"); b.Property("ConcurrencyStamp") .HasColumnType("longtext"); b.Property("CreatedAt") .HasColumnType("datetime(6)"); b.Property("Email") .HasMaxLength(256) .HasColumnType("varchar(256)"); b.Property("EmailConfirmed") .HasColumnType("tinyint(1)"); b.Property("FullName") .IsRequired() .HasMaxLength(100) .HasColumnType("varchar(100)"); b.Property("LockoutEnabled") .HasColumnType("tinyint(1)"); b.Property("LockoutEnd") .HasColumnType("datetime(6)"); b.Property("NormalizedEmail") .HasMaxLength(256) .HasColumnType("varchar(256)"); b.Property("NormalizedUserName") .HasMaxLength(256) .HasColumnType("varchar(256)"); b.Property("PasswordHash") .HasColumnType("longtext"); b.Property("PhoneNumber") .HasColumnType("longtext"); b.Property("PhoneNumberConfirmed") .HasColumnType("tinyint(1)"); b.Property("SecurityStamp") .HasColumnType("longtext"); b.Property("TwoFactorEnabled") .HasColumnType("tinyint(1)"); b.Property("UserName") .HasMaxLength(256) .HasColumnType("varchar(256)"); b.HasKey("Id"); b.HasIndex("NormalizedEmail") .HasDatabaseName("EmailIndex"); b.HasIndex("NormalizedUserName") .IsUnique() .HasDatabaseName("UserNameIndex"); b.ToTable("AspNetUsers", (string)null); }); modelBuilder.Entity("LEA.Models.Contact", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int") .HasAnnotation("MySql:ValueGenerationStrategy", MySqlValueGenerationStrategy.IdentityColumn); b.Property("ApplicationId") .HasColumnType("int"); b.Property("Email") .HasColumnType("longtext"); b.Property("FullName") .HasMaxLength(100) .HasColumnType("varchar(100)"); b.Property("Phone") .HasColumnType("longtext"); b.HasKey("Id"); b.HasIndex("ApplicationId") .IsUnique(); b.ToTable("Contacts"); b.HasOne("LEA.Models.Application", "Application") .WithOne("Contact") .HasForeignKey("LEA.Models.Contact", "ApplicationId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Application"); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRole", b => { b.Property("Id") .HasColumnType("varchar(255)"); b.Property("ConcurrencyStamp") .HasColumnType("longtext"); b.Property("Name") .HasMaxLength(256) .HasColumnType("varchar(256)"); b.Property("NormalizedName") .HasMaxLength(256) .HasColumnType("varchar(256)"); b.HasKey("Id"); b.HasIndex("NormalizedName") .IsUnique() .HasDatabaseName("RoleNameIndex"); b.ToTable("AspNetRoles", (string)null); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int") .HasAnnotation("MySql:ValueGenerationStrategy", MySqlValueGenerationStrategy.IdentityColumn); b.Property("ClaimType") .HasColumnType("longtext"); b.Property("ClaimValue") .HasColumnType("longtext"); b.Property("RoleId") .IsRequired() .HasColumnType("varchar(255)"); b.HasKey("Id"); b.HasIndex("RoleId"); b.ToTable("AspNetRoleClaims", (string)null); b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null) .WithMany() .HasForeignKey("RoleId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int") .HasAnnotation("MySql:ValueGenerationStrategy", MySqlValueGenerationStrategy.IdentityColumn); b.Property("ClaimType") .HasColumnType("longtext"); b.Property("ClaimValue") .HasColumnType("longtext"); b.Property("UserId") .IsRequired() .HasColumnType("varchar(255)"); b.HasKey("Id"); b.HasIndex("UserId"); b.ToTable("AspNetUserClaims", (string)null); b.HasOne("LEA.Models.ApplicationUser", null) .WithMany() .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin", b => { b.Property("LoginProvider") .HasMaxLength(128) .HasColumnType("varchar(128)"); b.Property("ProviderKey") .HasMaxLength(128) .HasColumnType("varchar(128)"); b.Property("ProviderDisplayName") .HasColumnType("longtext"); b.Property("UserId") .IsRequired() .HasColumnType("varchar(255)"); b.HasKey("LoginProvider", "ProviderKey"); b.HasIndex("UserId"); b.ToTable("AspNetUserLogins", (string)null); b.HasOne("LEA.Models.ApplicationUser", null) .WithMany() .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole", b => { b.Property("UserId") .HasColumnType("varchar(255)"); b.Property("RoleId") .HasColumnType("varchar(255)"); b.HasKey("UserId", "RoleId"); b.HasIndex("RoleId"); b.ToTable("AspNetUserRoles", (string)null); b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null) .WithMany() .HasForeignKey("RoleId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("LEA.Models.ApplicationUser", null) .WithMany() .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); }); modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken", b => { b.Property("UserId") .HasColumnType("varchar(255)"); b.Property("LoginProvider") .HasMaxLength(128) .HasColumnType("varchar(128)"); b.Property("Name") .HasMaxLength(128) .HasColumnType("varchar(128)"); b.Property("Value") .HasColumnType("longtext"); b.HasKey("UserId", "LoginProvider", "Name"); b.ToTable("AspNetUserTokens", (string)null); b.HasOne("LEA.Models.ApplicationUser", null) .WithMany() .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); }); } } }