item mng with sync

This commit is contained in:
Kalana B. Thilakarathna
2026-08-19 12:49:04 +05:30
parent 45f374133f
commit 397af8fd59
42 changed files with 5191 additions and 16 deletions
@@ -16,10 +16,57 @@ namespace Distribution.Migrations
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "10.0.9")
.HasAnnotation("Relational:MaxIdentifierLength", 64);
modelBuilder.Entity("Distribution.Models.Brand", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("char(36)");
b.Property<DateTime>("CreatedAt")
.HasColumnType("datetime(6)");
b.Property<int?>("ExternalErpId")
.HasColumnType("int");
b.Property<bool>("IsActive")
.HasColumnType("tinyint(1)");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("longtext");
b.HasKey("Id");
b.ToTable("Brands");
});
modelBuilder.Entity("Distribution.Models.Category", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("char(36)");
b.Property<DateTime>("CreatedAt")
.HasColumnType("datetime(6)");
b.Property<int?>("ExternalErpId")
.HasColumnType("int");
b.Property<bool>("IsActive")
.HasColumnType("tinyint(1)");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("longtext");
b.HasKey("Id");
b.ToTable("Categories");
});
modelBuilder.Entity("Distribution.Models.DeliveryRun", b =>
{
b.Property<Guid>("Id")
@@ -62,11 +109,54 @@ namespace Distribution.Migrations
b.Property<DateTime>("CreatedAt")
.HasColumnType("datetime(6)");
b.Property<string>("Description")
.HasColumnType("longtext");
b.Property<int?>("ExternalErpItemId")
.HasColumnType("int");
b.Property<Guid>("FK_BaseUomId")
.HasColumnType("char(36)");
b.Property<Guid?>("FK_BrandId")
.HasColumnType("char(36)");
b.Property<Guid>("FK_CategoryId")
.HasColumnType("char(36)");
b.Property<Guid?>("FK_SubCategoryId")
.HasColumnType("char(36)");
b.Property<bool>("IsActive")
.HasColumnType("tinyint(1)");
b.Property<DateTime?>("LastSyncedAt")
.HasColumnType("datetime(6)");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("longtext");
b.Property<decimal?>("SalePrice")
.HasColumnType("decimal(18,2)");
b.Property<string>("Sku")
.IsRequired()
.HasColumnType("longtext");
b.Property<int>("SyncSource")
.HasColumnType("int");
b.HasKey("Id");
b.HasIndex("FK_BaseUomId");
b.HasIndex("FK_BrandId");
b.HasIndex("FK_CategoryId");
b.HasIndex("FK_SubCategoryId");
b.ToTable("Items");
});
@@ -118,6 +208,9 @@ namespace Distribution.Migrations
b.Property<int>("Quantity")
.HasColumnType("int");
b.Property<decimal>("UnitPrice")
.HasColumnType("decimal(18,2)");
b.HasKey("FK_OrderId", "FK_ItemId");
b.HasIndex("FK_ItemId");
@@ -389,6 +482,70 @@ namespace Distribution.Migrations
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "Assign region/route/store scope to a user",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000031"),
Code = "items.view",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "View items, brands and UOMs",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000032"),
Code = "items.create",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "Create items, brands and UOMs",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000033"),
Code = "items.update",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "Update items, brands and UOMs",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000034"),
Code = "items.delete",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "Delete items, brands and UOMs",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000035"),
Code = "categories.view",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "View categories",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000036"),
Code = "categories.create",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "Create categories and subcategories",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000037"),
Code = "categories.update",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "Update categories and subcategories",
IsActive = true
},
new
{
Id = new Guid("20000000-0000-0000-0000-000000000038"),
Code = "categories.delete",
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Description = "Delete categories and subcategories",
IsActive = true
});
});
@@ -552,6 +709,22 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000001"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000031"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("7596f703-c6ab-316c-7c80-3f4e3daa174e"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000001"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000035"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("aa120c36-488e-34ba-e10a-2ac45e46e119"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000002"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000021"),
@@ -592,6 +765,22 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000002"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000031"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("b7dee5e3-f329-95a5-75c1-d02c3e40e229"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000002"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000035"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("e5506b30-527d-08f9-6caa-8a45d3d02999"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000002"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000024"),
@@ -656,6 +845,22 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000003"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000031"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("7780d277-9597-84ff-1a1a-f63fc6b4d3cb"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000003"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000035"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("1e7fe1b6-5150-4b99-38ed-088d9495cfd8"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000003"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000024"),
@@ -696,6 +901,22 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000003"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000032"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("8083c659-9506-0bd9-b793-3d6148ce9192"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000003"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000033"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("d49f086e-30f0-6ce8-ae96-4395d5e04472"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000021"),
@@ -736,6 +957,22 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000031"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("a701da28-aa75-3c1d-abdb-4317404f8df6"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000035"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("9afe507e-191e-bdee-0c5a-cfbcbf1efb3e"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000024"),
@@ -776,6 +1013,22 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000032"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("2c025310-765f-7d07-ab9a-50524c13d1d3"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000033"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("7c392a13-1a57-0d85-dffa-2fb9e892abe9"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000006"),
@@ -792,6 +1045,38 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000034"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("97708eed-6ce4-7710-abde-01d00c0c879b"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000036"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("9c278616-4289-96fb-944d-b8f1495ccb00"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000037"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("d1dcef02-d4c3-caba-372f-dab82011e9c1"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000004"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000038"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("9cc36229-dfba-49b9-1d6e-8929546e894d"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000021"),
@@ -968,6 +1253,70 @@ namespace Distribution.Migrations
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000031"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("69f93a29-1df1-7b20-9d5c-94c264f8c4b8"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000032"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("070813f7-4053-2889-0d14-d0d5834208c2"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000033"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("0efa7259-aadb-0019-4be5-38d3f8f4cd54"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000034"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("9e60e7d7-8bd6-c1c7-4bf1-4de2c9dcb91c"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000035"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("5df82318-bc01-1947-09ef-60508e02b257"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000036"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("34f478f4-6c96-4b31-b68a-28c7942c0789"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000037"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("69598e0e-b7ad-477b-c587-7abf6189162d"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000005"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000038"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("b36fb2d4-43df-44f8-ff51-de6d88644c94"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000001"),
@@ -1206,6 +1555,70 @@ namespace Distribution.Migrations
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("ace990cf-6654-5e68-3dc8-1e62347e0946"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000031"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("bd209f90-6671-8ea0-eb20-aa151faec6a0"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000032"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("4cc32686-8391-0214-5747-db14f53c5b6f"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000033"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("26c6d86a-835d-6f0d-3730-66a46ea26b11"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000034"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("e8039d9c-a286-fb74-5abb-b5c6c67f243a"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000035"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("d9e038cb-bcff-cce1-5d34-b4e63a9ce694"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000036"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("343e71f0-da6b-2489-5571-f8d7c6378ee7"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000037"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("ac894328-a935-8e6e-8427-6c0f36ac75da"),
IsActive = true
},
new
{
FK_RoleId = new Guid("10000000-0000-0000-0000-000000000006"),
FK_PermissionId = new Guid("20000000-0000-0000-0000-000000000038"),
CreatedAt = new DateTime(2026, 8, 18, 0, 0, 0, 0, DateTimeKind.Unspecified),
Id = new Guid("1d6273d4-db6a-d70e-4b5f-98cb634d668a"),
IsActive = true
});
});
@@ -1309,6 +1722,88 @@ namespace Distribution.Migrations
b.ToTable("Stores");
});
modelBuilder.Entity("Distribution.Models.SubCategory", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("char(36)");
b.Property<DateTime>("CreatedAt")
.HasColumnType("datetime(6)");
b.Property<int?>("ExternalErpId")
.HasColumnType("int");
b.Property<Guid>("FK_CategoryId")
.HasColumnType("char(36)");
b.Property<bool>("IsActive")
.HasColumnType("tinyint(1)");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("longtext");
b.HasKey("Id");
b.HasIndex("FK_CategoryId");
b.ToTable("SubCategories");
});
modelBuilder.Entity("Distribution.Models.Uom", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("char(36)");
b.Property<DateTime>("CreatedAt")
.HasColumnType("datetime(6)");
b.Property<int?>("ExternalErpId")
.HasColumnType("int");
b.Property<bool>("IsActive")
.HasColumnType("tinyint(1)");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("longtext");
b.HasKey("Id");
b.ToTable("Uoms");
});
modelBuilder.Entity("Distribution.Models.UomConversion", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("char(36)");
b.Property<Guid>("FK_FromUomId")
.HasColumnType("char(36)");
b.Property<Guid>("FK_ItemId")
.HasColumnType("char(36)");
b.Property<Guid>("FK_ToUomId")
.HasColumnType("char(36)");
b.Property<decimal>("Factor")
.HasColumnType("decimal(18,2)");
b.HasKey("Id");
b.HasIndex("FK_FromUomId");
b.HasIndex("FK_ItemId");
b.HasIndex("FK_ToUomId");
b.ToTable("UomConversions");
});
modelBuilder.Entity("Distribution.Models.User", b =>
{
b.Property<Guid>("Id")
@@ -1503,6 +1998,37 @@ namespace Distribution.Migrations
b.Navigation("Vehicle");
});
modelBuilder.Entity("Distribution.Models.Item", b =>
{
b.HasOne("Distribution.Models.Uom", "BaseUom")
.WithMany()
.HasForeignKey("FK_BaseUomId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Distribution.Models.Brand", "Brand")
.WithMany()
.HasForeignKey("FK_BrandId");
b.HasOne("Distribution.Models.Category", "Category")
.WithMany()
.HasForeignKey("FK_CategoryId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Distribution.Models.SubCategory", "SubCategory")
.WithMany()
.HasForeignKey("FK_SubCategoryId");
b.Navigation("BaseUom");
b.Navigation("Brand");
b.Navigation("Category");
b.Navigation("SubCategory");
});
modelBuilder.Entity("Distribution.Models.Order", b =>
{
b.HasOne("Distribution.Models.Store", "Store")
@@ -1574,6 +2100,44 @@ namespace Distribution.Migrations
b.Navigation("Route");
});
modelBuilder.Entity("Distribution.Models.SubCategory", b =>
{
b.HasOne("Distribution.Models.Category", "Category")
.WithMany()
.HasForeignKey("FK_CategoryId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Category");
});
modelBuilder.Entity("Distribution.Models.UomConversion", b =>
{
b.HasOne("Distribution.Models.Uom", "FromUom")
.WithMany()
.HasForeignKey("FK_FromUomId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Distribution.Models.Item", "Item")
.WithMany("Conversions")
.HasForeignKey("FK_ItemId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Distribution.Models.Uom", "ToUom")
.WithMany()
.HasForeignKey("FK_ToUomId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("FromUom");
b.Navigation("Item");
b.Navigation("ToUom");
});
modelBuilder.Entity("Distribution.Models.User", b =>
{
b.HasOne("Distribution.Models.User", "ReportsTo")
@@ -1657,6 +2221,11 @@ namespace Distribution.Migrations
b.Navigation("Vehicle");
});
modelBuilder.Entity("Distribution.Models.Item", b =>
{
b.Navigation("Conversions");
});
#pragma warning restore 612, 618
}
}