refactoring

This commit is contained in:
2023-06-22 10:01:27 +03:00
parent e9d4053e65
commit d549877567
116 changed files with 1216 additions and 11709 deletions
@@ -119,7 +119,7 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.ToTable("AccountCategories");
});
modelBuilder.Entity("MyOffice.Data.Models.Accounts.AccountMotion", b =>
modelBuilder.Entity("MyOffice.Data.Models.Accounts.Motion", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
@@ -145,7 +145,7 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.Property<string>("Description")
.HasColumnType("text");
b.Property<int>("MotionId")
b.Property<int>("ItemId")
.HasColumnType("integer");
b.Property<Guid?>("UserId")
@@ -155,11 +155,11 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.HasIndex("AccountId");
b.HasIndex("MotionId");
b.HasIndex("ItemId");
b.HasIndex("UserId");
b.ToTable("AccountMotions");
b.ToTable("Motions");
});
modelBuilder.Entity("MyOffice.Data.Models.Currencies.Currency", b =>
@@ -240,7 +240,7 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.ToTable("CurrencyRates");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionAccount", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.Item", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@@ -251,19 +251,19 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.Property<Guid>("CategoryId")
.HasColumnType("uuid");
b.Property<Guid>("MotionGlobalId")
b.Property<Guid>("ItemGlobalId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("CategoryId");
b.HasIndex("MotionGlobalId");
b.HasIndex("ItemGlobalId");
b.ToTable("Motions");
b.ToTable("Items");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionCategory", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.ItemCategory", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
@@ -280,10 +280,10 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.HasIndex("UserId");
b.ToTable("MotionCategories");
b.ToTable("ItemCategories");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionGlobal", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.ItemGlobal", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
@@ -295,7 +295,7 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.HasKey("Id");
b.ToTable("GlobalMotions");
b.ToTable("ItemGlobals");
});
modelBuilder.Entity("MyOffice.Data.Models.Users.User", b =>
@@ -439,7 +439,7 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.Navigation("User");
});
modelBuilder.Entity("MyOffice.Data.Models.Accounts.AccountMotion", b =>
modelBuilder.Entity("MyOffice.Data.Models.Accounts.Motion", b =>
{
b.HasOne("MyOffice.Data.Models.Accounts.Account", "Account")
.WithMany("Motions")
@@ -447,9 +447,9 @@ namespace MyOffice.Migrations.Postgres.Migrations
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("MyOffice.Data.Models.Motions.MotionAccount", "Motion")
b.HasOne("MyOffice.Data.Models.Motions.Item", "Item")
.WithMany("Motions")
.HasForeignKey("MotionId")
.HasForeignKey("ItemId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
@@ -459,7 +459,7 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.Navigation("Account");
b.Navigation("Motion");
b.Navigation("Item");
});
modelBuilder.Entity("MyOffice.Data.Models.Currencies.Currency", b =>
@@ -492,29 +492,29 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.Navigation("Currency");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionAccount", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.Item", b =>
{
b.HasOne("MyOffice.Data.Models.Motions.MotionCategory", "Category")
.WithMany("Motions")
b.HasOne("MyOffice.Data.Models.Motions.ItemCategory", "Category")
.WithMany("Items")
.HasForeignKey("CategoryId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("MyOffice.Data.Models.Motions.MotionGlobal", "MotionGlobal")
.WithMany("Motions")
.HasForeignKey("MotionGlobalId")
b.HasOne("MyOffice.Data.Models.Motions.ItemGlobal", "ItemGlobal")
.WithMany("Items")
.HasForeignKey("ItemGlobalId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Category");
b.Navigation("MotionGlobal");
b.Navigation("ItemGlobal");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionCategory", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.ItemCategory", b =>
{
b.HasOne("MyOffice.Data.Models.Users.User", "User")
.WithMany("MotionCategories")
.WithMany("ItemCategories")
.HasForeignKey("UserId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
@@ -570,19 +570,19 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.Navigation("Currencies");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionAccount", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.Item", b =>
{
b.Navigation("Motions");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionCategory", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.ItemCategory", b =>
{
b.Navigation("Motions");
b.Navigation("Items");
});
modelBuilder.Entity("MyOffice.Data.Models.Motions.MotionGlobal", b =>
modelBuilder.Entity("MyOffice.Data.Models.Motions.ItemGlobal", b =>
{
b.Navigation("Motions");
b.Navigation("Items");
});
modelBuilder.Entity("MyOffice.Data.Models.Users.User", b =>
@@ -595,7 +595,7 @@ namespace MyOffice.Migrations.Postgres.Migrations
b.Navigation("Currencies");
b.Navigation("MotionCategories");
b.Navigation("ItemCategories");
b.Navigation("UserClaims");
});