// using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Migrations; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; using PokedexApi.Data; #nullable disable namespace PokedexApi.Migrations { [DbContext(typeof(PokemonContext))] [Migration("20260911142245_PokemonTable")] partial class PokemonTable { /// protected override void BuildTargetModel(ModelBuilder modelBuilder) { #pragma warning disable 612, 618 modelBuilder .HasAnnotation("ProductVersion", "10.0.4") .HasAnnotation("Relational:MaxIdentifierLength", 63); NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder); modelBuilder.Entity("PokedexApi.Data.Models.Pokemon", b => { b.Property("Id") .HasColumnType("integer") .HasColumnName("pokemon_id"); b.Property("Height") .HasColumnType("double precision") .HasColumnName("pokemon_height_m"); b.Property("Name") .IsRequired() .HasMaxLength(30) .HasColumnType("character varying(30)") .HasColumnName("pokemon_name"); b.Property("Weight") .HasColumnType("double precision") .HasColumnName("pokemon_weight_kg"); b.HasKey("Id"); b.HasIndex("Name") .IsUnique(); b.ToTable("pokemon"); }); modelBuilder.Entity("PokedexApi.Data.Models.Type", b => { b.Property("TypeId") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasColumnName("type_id"); NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("TypeId")); b.Property("Name") .IsRequired() .HasColumnType("text") .HasColumnName("type_name"); b.HasKey("TypeId"); b.HasIndex("Name") .IsUnique(); b.ToTable("type"); }); #pragma warning restore 612, 618 } } }