// using Entities; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; #nullable disable namespace Entities.Migrations { [DbContext(typeof(ChampionDbContext))] partial class ChampionDbContextModelSnapshot : ModelSnapshot { protected override void BuildModel(ModelBuilder modelBuilder) { #pragma warning disable 612, 618 modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); modelBuilder.Entity("Entities.ChampionEntity", b => { b.Property("Name") .HasMaxLength(256) .HasColumnType("TEXT"); b.Property("Bio") .IsRequired() .HasMaxLength(500) .HasColumnType("TEXT"); b.Property("Class") .HasColumnType("INTEGER"); b.Property("Icon") .HasColumnType("TEXT"); b.HasKey("Name"); b.ToTable("champions"); b.HasData( new { Name = "Dave", Bio = "Le meilleur Jazzman de France", Class = 2 }, new { Name = "Armure", Bio = "Solide", Class = 6 }); }); modelBuilder.Entity("Entities.SkinEntity", b => { b.Property("Name") .HasMaxLength(256) .HasColumnType("TEXT"); b.Property("ChampionForeignKey") .IsRequired() .HasColumnType("TEXT"); b.Property("Description") .IsRequired() .HasMaxLength(500) .HasColumnType("TEXT"); b.Property("Icon") .IsRequired() .HasColumnType("TEXT"); b.Property("Price") .HasColumnType("REAL"); b.HasKey("Name"); b.HasIndex("ChampionForeignKey"); b.ToTable("skins"); b.HasData( new { Name = "Dave de glace", ChampionForeignKey = "Dave", Description = "Enneigé", Icon = "aaa", Price = 7.99f }, new { Name = "Armure Fullspeed", ChampionForeignKey = "Armure", Description = "Deja vu", Icon = "aaa", Price = 9.99f }); }); modelBuilder.Entity("Entities.SkinEntity", b => { b.HasOne("Entities.ChampionEntity", "Champion") .WithMany() .HasForeignKey("ChampionForeignKey") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Champion"); }); #pragma warning restore 612, 618 } } }