diff --git a/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/20230407135446_clientmigration.Designer.cs b/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/20230407135446_clientmigration.Designer.cs new file mode 100644 index 0000000..b6861d5 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/20230407135446_clientmigration.Designer.cs @@ -0,0 +1,506 @@ +// +using System; +using ComputerShopDatabaseImplement; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Metadata; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace ComputerShopDatabaseImplement.Migrations +{ + [DbContext(typeof(ComputerShopDatabase))] + [Migration("20230407135446_clientmigration")] + partial class clientmigration + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "7.0.4") + .HasAnnotation("Relational:MaxIdentifierLength", 128); + + SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Assembly", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("AssemblyName") + .IsRequired() + .HasColumnType("nvarchar(max)"); + + b.Property("ClientId") + .HasColumnType("int"); + + b.Property("Price") + .HasColumnType("float"); + + b.HasKey("Id"); + + b.HasIndex("ClientId"); + + b.ToTable("Assemblies"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.AssemblyComponent", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("AssemblyId") + .HasColumnType("int"); + + b.Property("ComponentId") + .HasColumnType("int"); + + b.Property("Count") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AssemblyId"); + + b.HasIndex("ComponentId"); + + b.ToTable("AssemblyComponents"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.AssemblyOrder", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("AssemblyId") + .HasColumnType("int"); + + b.Property("Count") + .HasColumnType("int"); + + b.Property("OrderId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AssemblyId"); + + b.HasIndex("OrderId"); + + b.ToTable("AssemblyOrders"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.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("ComputerShopDatabaseImplement.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("ComputerShopDatabaseImplement.Models.ComponentSupply", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ComponentId") + .HasColumnType("int"); + + b.Property("Count") + .HasColumnType("int"); + + b.Property("SupplyId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("ComponentId"); + + b.HasIndex("SupplyId"); + + b.ToTable("ComponentSupplies"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.EquipmentReceiving", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ClientId") + .HasColumnType("int"); + + b.Property("DateImplement") + .HasColumnType("datetime2"); + + b.Property("Status") + .HasColumnType("int"); + + b.Property("SupplyId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("ClientId"); + + b.HasIndex("SupplyId"); + + b.ToTable("EquipmentReceivings"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Order", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ClientId") + .HasColumnType("int"); + + b.Property("DateCreate") + .HasColumnType("datetime2"); + + b.Property("DateImplement") + .HasColumnType("datetime2"); + + b.Property("Status") + .HasColumnType("int"); + + b.Property("Sum") + .HasColumnType("float"); + + b.HasKey("Id"); + + b.HasIndex("ClientId"); + + b.ToTable("Orders"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Purchase", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ClientId") + .HasColumnType("int"); + + b.Property("ComponentId") + .HasColumnType("int"); + + b.Property("ComponentName") + .IsRequired() + .HasColumnType("nvarchar(max)"); + + b.Property("Count") + .HasColumnType("int"); + + b.Property("DateCreate") + .HasColumnType("datetime2"); + + b.Property("DateImplement") + .HasColumnType("datetime2"); + + b.Property("Status") + .HasColumnType("int"); + + b.Property("Sum") + .HasColumnType("float"); + + b.HasKey("Id"); + + b.HasIndex("ClientId"); + + b.HasIndex("ComponentId"); + + b.ToTable("Purchases"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Supply", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("ClientId") + .HasColumnType("int"); + + b.Property("DateCreate") + .HasColumnType("datetime2"); + + b.Property("DateImplement") + .HasColumnType("datetime2"); + + b.Property("OrderId") + .HasColumnType("int"); + + b.Property("ReceivingId") + .HasColumnType("int"); + + b.Property("Status") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("ClientId"); + + b.ToTable("Supplies"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.SupplyOrder", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + + b.Property("Count") + .HasColumnType("int"); + + b.Property("OrderId") + .HasColumnType("int"); + + b.Property("SupplyId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("OrderId"); + + b.HasIndex("SupplyId"); + + b.ToTable("SupplyOrders"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Assembly", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Assemblies") + .HasForeignKey("ClientId"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.AssemblyComponent", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Assembly", "Assembly") + .WithMany("Components") + .HasForeignKey("AssemblyId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("ComputerShopDatabaseImplement.Models.Component", "Component") + .WithMany("AssemblyComponents") + .HasForeignKey("ComponentId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Assembly"); + + b.Navigation("Component"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.AssemblyOrder", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Assembly", "Assembly") + .WithMany("Orders") + .HasForeignKey("AssemblyId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("ComputerShopDatabaseImplement.Models.Order", "Order") + .WithMany("Assemblies") + .HasForeignKey("OrderId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Assembly"); + + b.Navigation("Order"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.ComponentSupply", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Component", "Component") + .WithMany("Supplies") + .HasForeignKey("ComponentId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("ComputerShopDatabaseImplement.Models.Supply", "Supply") + .WithMany("Supplies") + .HasForeignKey("SupplyId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Component"); + + b.Navigation("Supply"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.EquipmentReceiving", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("EquipmentReceivings") + .HasForeignKey("ClientId"); + + b.HasOne("ComputerShopDatabaseImplement.Models.Supply", null) + .WithMany("Receivings") + .HasForeignKey("SupplyId"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Order", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Orders") + .HasForeignKey("ClientId"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Purchase", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Purchases") + .HasForeignKey("ClientId"); + + b.HasOne("ComputerShopDatabaseImplement.Models.Component", "Component") + .WithMany("Purchases") + .HasForeignKey("ComponentId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Component"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Supply", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Supplies") + .HasForeignKey("ClientId"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.SupplyOrder", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Order", "Order") + .WithMany("SupplyOrders") + .HasForeignKey("OrderId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("ComputerShopDatabaseImplement.Models.Supply", "Supply") + .WithMany("Orders") + .HasForeignKey("SupplyId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Order"); + + b.Navigation("Supply"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Assembly", b => + { + b.Navigation("Components"); + + b.Navigation("Orders"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Client", b => + { + b.Navigation("Assemblies"); + + b.Navigation("EquipmentReceivings"); + + b.Navigation("Orders"); + + b.Navigation("Purchases"); + + b.Navigation("Supplies"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Component", b => + { + b.Navigation("AssemblyComponents"); + + b.Navigation("Purchases"); + + b.Navigation("Supplies"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Order", b => + { + b.Navigation("Assemblies"); + + b.Navigation("SupplyOrders"); + }); + + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Supply", b => + { + b.Navigation("Orders"); + + b.Navigation("Receivings"); + + b.Navigation("Supplies"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/20230407135446_clientmigration.cs b/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/20230407135446_clientmigration.cs new file mode 100644 index 0000000..d7bae25 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/20230407135446_clientmigration.cs @@ -0,0 +1,186 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace ComputerShopDatabaseImplement.Migrations +{ + /// + public partial class clientmigration : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AddColumn( + name: "ClientId", + table: "Supplies", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "ClientId", + table: "Purchases", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "ClientId", + table: "Orders", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "ClientId", + table: "EquipmentReceivings", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "ClientId", + table: "Assemblies", + type: "int", + nullable: true); + + migrationBuilder.CreateTable( + name: "Clients", + columns: table => new + { + Id = table.Column(type: "int", nullable: false) + .Annotation("SqlServer:Identity", "1, 1"), + ClientFIO = table.Column(type: "nvarchar(max)", nullable: false), + Email = table.Column(type: "nvarchar(max)", nullable: false), + Password = table.Column(type: "nvarchar(max)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Clients", x => x.Id); + }); + + migrationBuilder.CreateIndex( + name: "IX_Supplies_ClientId", + table: "Supplies", + column: "ClientId"); + + migrationBuilder.CreateIndex( + name: "IX_Purchases_ClientId", + table: "Purchases", + column: "ClientId"); + + migrationBuilder.CreateIndex( + name: "IX_Orders_ClientId", + table: "Orders", + column: "ClientId"); + + migrationBuilder.CreateIndex( + name: "IX_EquipmentReceivings_ClientId", + table: "EquipmentReceivings", + column: "ClientId"); + + migrationBuilder.CreateIndex( + name: "IX_Assemblies_ClientId", + table: "Assemblies", + column: "ClientId"); + + migrationBuilder.AddForeignKey( + name: "FK_Assemblies_Clients_ClientId", + table: "Assemblies", + column: "ClientId", + principalTable: "Clients", + principalColumn: "Id"); + + migrationBuilder.AddForeignKey( + name: "FK_EquipmentReceivings_Clients_ClientId", + table: "EquipmentReceivings", + column: "ClientId", + principalTable: "Clients", + principalColumn: "Id"); + + migrationBuilder.AddForeignKey( + name: "FK_Orders_Clients_ClientId", + table: "Orders", + column: "ClientId", + principalTable: "Clients", + principalColumn: "Id"); + + migrationBuilder.AddForeignKey( + name: "FK_Purchases_Clients_ClientId", + table: "Purchases", + column: "ClientId", + principalTable: "Clients", + principalColumn: "Id"); + + migrationBuilder.AddForeignKey( + name: "FK_Supplies_Clients_ClientId", + table: "Supplies", + column: "ClientId", + principalTable: "Clients", + principalColumn: "Id"); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropForeignKey( + name: "FK_Assemblies_Clients_ClientId", + table: "Assemblies"); + + migrationBuilder.DropForeignKey( + name: "FK_EquipmentReceivings_Clients_ClientId", + table: "EquipmentReceivings"); + + migrationBuilder.DropForeignKey( + name: "FK_Orders_Clients_ClientId", + table: "Orders"); + + migrationBuilder.DropForeignKey( + name: "FK_Purchases_Clients_ClientId", + table: "Purchases"); + + migrationBuilder.DropForeignKey( + name: "FK_Supplies_Clients_ClientId", + table: "Supplies"); + + migrationBuilder.DropTable( + name: "Clients"); + + migrationBuilder.DropIndex( + name: "IX_Supplies_ClientId", + table: "Supplies"); + + migrationBuilder.DropIndex( + name: "IX_Purchases_ClientId", + table: "Purchases"); + + migrationBuilder.DropIndex( + name: "IX_Orders_ClientId", + table: "Orders"); + + migrationBuilder.DropIndex( + name: "IX_EquipmentReceivings_ClientId", + table: "EquipmentReceivings"); + + migrationBuilder.DropIndex( + name: "IX_Assemblies_ClientId", + table: "Assemblies"); + + migrationBuilder.DropColumn( + name: "ClientId", + table: "Supplies"); + + migrationBuilder.DropColumn( + name: "ClientId", + table: "Purchases"); + + migrationBuilder.DropColumn( + name: "ClientId", + table: "Orders"); + + migrationBuilder.DropColumn( + name: "ClientId", + table: "EquipmentReceivings"); + + migrationBuilder.DropColumn( + name: "ClientId", + table: "Assemblies"); + } + } +} diff --git a/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/ComputerShopDatabaseModelSnapshot.cs b/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/ComputerShopDatabaseModelSnapshot.cs index 5328692..369f9c9 100644 --- a/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/ComputerShopDatabaseModelSnapshot.cs +++ b/ComputerShopProvider/ComputerShopDatabaseImplement/Migrations/ComputerShopDatabaseModelSnapshot.cs @@ -34,11 +34,16 @@ namespace ComputerShopDatabaseImplement.Migrations .IsRequired() .HasColumnType("nvarchar(max)"); + b.Property("ClientId") + .HasColumnType("int"); + b.Property("Price") .HasColumnType("float"); b.HasKey("Id"); + b.HasIndex("ClientId"); + b.ToTable("Assemblies"); }); @@ -94,6 +99,31 @@ namespace ComputerShopDatabaseImplement.Migrations b.ToTable("AssemblyOrders"); }); + modelBuilder.Entity("ComputerShopDatabaseImplement.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("ComputerShopDatabaseImplement.Models.Component", b => { b.Property("Id") @@ -148,6 +178,9 @@ namespace ComputerShopDatabaseImplement.Migrations SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + b.Property("ClientId") + .HasColumnType("int"); + b.Property("DateImplement") .HasColumnType("datetime2"); @@ -159,6 +192,8 @@ namespace ComputerShopDatabaseImplement.Migrations b.HasKey("Id"); + b.HasIndex("ClientId"); + b.HasIndex("SupplyId"); b.ToTable("EquipmentReceivings"); @@ -172,6 +207,9 @@ namespace ComputerShopDatabaseImplement.Migrations SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + b.Property("ClientId") + .HasColumnType("int"); + b.Property("DateCreate") .HasColumnType("datetime2"); @@ -186,6 +224,8 @@ namespace ComputerShopDatabaseImplement.Migrations b.HasKey("Id"); + b.HasIndex("ClientId"); + b.ToTable("Orders"); }); @@ -197,6 +237,9 @@ namespace ComputerShopDatabaseImplement.Migrations SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + b.Property("ClientId") + .HasColumnType("int"); + b.Property("ComponentId") .HasColumnType("int"); @@ -221,6 +264,8 @@ namespace ComputerShopDatabaseImplement.Migrations b.HasKey("Id"); + b.HasIndex("ClientId"); + b.HasIndex("ComponentId"); b.ToTable("Purchases"); @@ -234,6 +279,9 @@ namespace ComputerShopDatabaseImplement.Migrations SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id")); + b.Property("ClientId") + .HasColumnType("int"); + b.Property("DateCreate") .HasColumnType("datetime2"); @@ -251,6 +299,8 @@ namespace ComputerShopDatabaseImplement.Migrations b.HasKey("Id"); + b.HasIndex("ClientId"); + b.ToTable("Supplies"); }); @@ -280,6 +330,13 @@ namespace ComputerShopDatabaseImplement.Migrations b.ToTable("SupplyOrders"); }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Assembly", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Assemblies") + .HasForeignKey("ClientId"); + }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.AssemblyComponent", b => { b.HasOne("ComputerShopDatabaseImplement.Models.Assembly", "Assembly") @@ -339,13 +396,28 @@ namespace ComputerShopDatabaseImplement.Migrations modelBuilder.Entity("ComputerShopDatabaseImplement.Models.EquipmentReceiving", b => { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("EquipmentReceivings") + .HasForeignKey("ClientId"); + b.HasOne("ComputerShopDatabaseImplement.Models.Supply", null) .WithMany("Receivings") .HasForeignKey("SupplyId"); }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Order", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Orders") + .HasForeignKey("ClientId"); + }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Purchase", b => { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Purchases") + .HasForeignKey("ClientId"); + b.HasOne("ComputerShopDatabaseImplement.Models.Component", "Component") .WithMany("Purchases") .HasForeignKey("ComponentId") @@ -355,6 +427,13 @@ namespace ComputerShopDatabaseImplement.Migrations b.Navigation("Component"); }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Supply", b => + { + b.HasOne("ComputerShopDatabaseImplement.Models.Client", null) + .WithMany("Supplies") + .HasForeignKey("ClientId"); + }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.SupplyOrder", b => { b.HasOne("ComputerShopDatabaseImplement.Models.Order", "Order") @@ -381,6 +460,19 @@ namespace ComputerShopDatabaseImplement.Migrations b.Navigation("Orders"); }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Client", b => + { + b.Navigation("Assemblies"); + + b.Navigation("EquipmentReceivings"); + + b.Navigation("Orders"); + + b.Navigation("Purchases"); + + b.Navigation("Supplies"); + }); + modelBuilder.Entity("ComputerShopDatabaseImplement.Models.Component", b => { b.Navigation("AssemblyComponents");