// using System; using FlowerShopDatabaseImplement; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Metadata; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; #nullable disable namespace FlowerShopDatabaseImplement.Migrations { [DbContext(typeof(FlowerShopDatabase))] partial class FlowerShopDatabaseModelSnapshot : ModelSnapshot { protected override void BuildModel(ModelBuilder modelBuilder) { #pragma warning disable 612, 618 modelBuilder .HasAnnotation("ProductVersion", "7.0.3") .HasAnnotation("Relational:MaxIdentifierLength", 128); SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Bouquet", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int"); SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); b.Property("BouquetName") .IsRequired() .HasColumnType("nvarchar(max)"); b.Property("Price") .HasColumnType("float"); b.HasKey("Id"); b.ToTable("Bouquets"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.BouquetComponent", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int"); SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); b.Property("BouquetId") .HasColumnType("int"); b.Property("ComponentId") .HasColumnType("int"); b.Property("Count") .HasColumnType("int"); b.HasKey("Id"); b.HasIndex("BouquetId"); b.HasIndex("ComponentId"); b.ToTable("BouquetComponents"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Client", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int"); SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); b.Property("ClientFIO") .IsRequired() .HasColumnType("nvarchar(max)"); b.Property("Email") .IsRequired() .HasColumnType("nvarchar(max)"); b.Property("Password") .IsRequired() .HasColumnType("nvarchar(max)"); b.HasKey("Id"); b.ToTable("Clients"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Component", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int"); SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); b.Property("ComponentName") .IsRequired() .HasColumnType("nvarchar(max)"); b.Property("Cost") .HasColumnType("float"); b.HasKey("Id"); b.ToTable("Components"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Implementer", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int"); SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); b.Property("ImplementerFIO") .IsRequired() .HasColumnType("nvarchar(max)"); b.Property("Password") .IsRequired() .HasColumnType("nvarchar(max)"); b.Property("Qualification") .HasColumnType("int"); b.Property("WorkExperience") .HasColumnType("int"); b.HasKey("Id"); b.ToTable("Implementers"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Order", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("int"); SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); b.Property("BouquetId") .HasColumnType("int"); b.Property("ClientId") .HasColumnType("int"); b.Property("Count") .HasColumnType("int"); b.Property("DateCreate") .HasColumnType("datetime2"); b.Property("DateImplement") .HasColumnType("datetime2"); b.Property("ImplementerId") .HasColumnType("int"); b.Property("Status") .HasColumnType("int"); b.Property("Sum") .HasColumnType("float"); b.HasKey("Id"); b.HasIndex("BouquetId"); b.HasIndex("ClientId"); b.HasIndex("ImplementerId"); b.ToTable("Orders"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.BouquetComponent", b => { b.HasOne("FlowerShopDatabaseImplement.Models.Bouquet", "Bouquet") .WithMany("Components") .HasForeignKey("BouquetId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("FlowerShopDatabaseImplement.Models.Component", "Component") .WithMany("BouquetComponents") .HasForeignKey("ComponentId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Bouquet"); b.Navigation("Component"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Order", b => { b.HasOne("FlowerShopDatabaseImplement.Models.Bouquet", "Bouquet") .WithMany("Orders") .HasForeignKey("BouquetId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("FlowerShopDatabaseImplement.Models.Client", "Client") .WithMany("Orders") .HasForeignKey("ClientId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("FlowerShopDatabaseImplement.Models.Implementer", "Implementer") .WithMany("Orders") .HasForeignKey("ImplementerId"); b.Navigation("Bouquet"); b.Navigation("Client"); b.Navigation("Implementer"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Bouquet", b => { b.Navigation("Components"); b.Navigation("Orders"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Client", b => { b.Navigation("Orders"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Component", b => { b.Navigation("BouquetComponents"); }); modelBuilder.Entity("FlowerShopDatabaseImplement.Models.Implementer", b => { b.Navigation("Orders"); }); #pragma warning restore 612, 618 } } }