Netcore3.0 (#323)
* Updates based on documentation * Getting the build passing * Getting app functioning * A few cleanups to confirm it's working as expected * Fixing functional tests * Updating dockerfile for 3.0 * Functional Tests now run sequentially * Updating to latest version of moq * Adding migration for post 3.0 upgrades * Removing commented out lines * Moving address and catalogitemordered configuration in to classes that own them * Minor cleanups
This commit is contained in:
committed by
Steve Smith
parent
9a21db6979
commit
4442015835
@@ -15,7 +15,7 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
#pragma warning disable 612, 618
|
||||
modelBuilder
|
||||
.HasAnnotation("ProductVersion", "2.2.6-servicing-10079")
|
||||
.HasAnnotation("ProductVersion", "3.0.0")
|
||||
.HasAnnotation("Relational:MaxIdentifierLength", 128)
|
||||
.HasAnnotation("Relational:Sequence:.catalog_brand_hilo", "'catalog_brand_hilo', '', '1', '10', '', '', 'Int64', 'False'")
|
||||
.HasAnnotation("Relational:Sequence:.catalog_hilo", "'catalog_hilo', '', '1', '10', '', '', 'Int64', 'False'")
|
||||
@@ -26,9 +26,13 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
||||
|
||||
b.Property<string>("BuyerId");
|
||||
b.Property<string>("BuyerId")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(40)")
|
||||
.HasMaxLength(40);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
@@ -39,13 +43,17 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
||||
|
||||
b.Property<int>("BasketId");
|
||||
b.Property<int>("BasketId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("CatalogItemId");
|
||||
b.Property<int>("CatalogItemId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("Quantity");
|
||||
b.Property<int>("Quantity")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<decimal>("UnitPrice")
|
||||
.HasColumnType("decimal(18,2)");
|
||||
@@ -61,36 +69,44 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:HiLoSequenceName", "catalog_brand_hilo")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.SequenceHiLo);
|
||||
|
||||
b.Property<string>("Brand")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(100)")
|
||||
.HasMaxLength(100);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("CatalogBrand");
|
||||
b.ToTable("CatalogBrands");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.eShopWeb.ApplicationCore.Entities.CatalogItem", b =>
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:HiLoSequenceName", "catalog_hilo")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.SequenceHiLo);
|
||||
|
||||
b.Property<int>("CatalogBrandId");
|
||||
b.Property<int>("CatalogBrandId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<int>("CatalogTypeId");
|
||||
b.Property<int>("CatalogTypeId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<string>("Description");
|
||||
b.Property<string>("Description")
|
||||
.HasColumnType("nvarchar(max)");
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(50)")
|
||||
.HasMaxLength(50);
|
||||
|
||||
b.Property<string>("PictureUri");
|
||||
b.Property<string>("PictureUri")
|
||||
.HasColumnType("nvarchar(max)");
|
||||
|
||||
b.Property<decimal>("Price")
|
||||
.HasColumnType("decimal(18,2)");
|
||||
@@ -108,27 +124,32 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:HiLoSequenceName", "catalog_type_hilo")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.SequenceHiLo);
|
||||
|
||||
b.Property<string>("Type")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(100)")
|
||||
.HasMaxLength(100);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("CatalogType");
|
||||
b.ToTable("CatalogTypes");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.Order", b =>
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
||||
|
||||
b.Property<string>("BuyerId");
|
||||
b.Property<string>("BuyerId")
|
||||
.HasColumnType("nvarchar(max)");
|
||||
|
||||
b.Property<DateTimeOffset>("OrderDate");
|
||||
b.Property<DateTimeOffset>("OrderDate")
|
||||
.HasColumnType("datetimeoffset");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
@@ -139,14 +160,17 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
||||
|
||||
b.Property<int?>("OrderId");
|
||||
b.Property<int?>("OrderId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<decimal>("UnitPrice")
|
||||
.HasColumnType("decimal(18,2)");
|
||||
|
||||
b.Property<int>("Units");
|
||||
b.Property<int>("Units")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
@@ -157,10 +181,11 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
|
||||
modelBuilder.Entity("Microsoft.eShopWeb.ApplicationCore.Entities.BasketAggregate.BasketItem", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.BasketAggregate.Basket")
|
||||
b.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.BasketAggregate.Basket", null)
|
||||
.WithMany("Items")
|
||||
.HasForeignKey("BasketId")
|
||||
.OnDelete(DeleteBehavior.Cascade);
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.eShopWeb.ApplicationCore.Entities.CatalogItem", b =>
|
||||
@@ -168,12 +193,14 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
b.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.CatalogBrand", "CatalogBrand")
|
||||
.WithMany()
|
||||
.HasForeignKey("CatalogBrandId")
|
||||
.OnDelete(DeleteBehavior.Cascade);
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.CatalogType", "CatalogType")
|
||||
.WithMany()
|
||||
.HasForeignKey("CatalogTypeId")
|
||||
.OnDelete(DeleteBehavior.Cascade);
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.Order", b =>
|
||||
@@ -182,41 +209,45 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
b1.Property<int>("OrderId")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
||||
|
||||
b1.Property<string>("City")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(100)")
|
||||
.HasMaxLength(100);
|
||||
|
||||
b1.Property<string>("Country")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(90)")
|
||||
.HasMaxLength(90);
|
||||
|
||||
b1.Property<string>("State")
|
||||
.HasColumnType("nvarchar(60)")
|
||||
.HasMaxLength(60);
|
||||
|
||||
b1.Property<string>("Street")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(180)")
|
||||
.HasMaxLength(180);
|
||||
|
||||
b1.Property<string>("ZipCode")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(18)")
|
||||
.HasMaxLength(18);
|
||||
|
||||
b1.HasKey("OrderId");
|
||||
|
||||
b1.ToTable("Orders");
|
||||
|
||||
b1.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.Order")
|
||||
.WithOne("ShipToAddress")
|
||||
.HasForeignKey("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.Address", "OrderId")
|
||||
.OnDelete(DeleteBehavior.Cascade);
|
||||
b1.WithOwner()
|
||||
.HasForeignKey("OrderId");
|
||||
});
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.OrderItem", b =>
|
||||
{
|
||||
b.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.Order")
|
||||
b.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.Order", null)
|
||||
.WithMany("OrderItems")
|
||||
.HasForeignKey("OrderId");
|
||||
|
||||
@@ -224,24 +255,26 @@ namespace Microsoft.eShopWeb.Infrastructure.Data.Migrations
|
||||
{
|
||||
b1.Property<int>("OrderItemId")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("int")
|
||||
.HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
|
||||
|
||||
b1.Property<int>("CatalogItemId");
|
||||
b1.Property<int>("CatalogItemId")
|
||||
.HasColumnType("int");
|
||||
|
||||
b1.Property<string>("PictureUri");
|
||||
b1.Property<string>("PictureUri")
|
||||
.HasColumnType("nvarchar(max)");
|
||||
|
||||
b1.Property<string>("ProductName")
|
||||
.IsRequired()
|
||||
.HasColumnType("nvarchar(50)")
|
||||
.HasMaxLength(50);
|
||||
|
||||
b1.HasKey("OrderItemId");
|
||||
|
||||
b1.ToTable("OrderItems");
|
||||
|
||||
b1.HasOne("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.OrderItem")
|
||||
.WithOne("ItemOrdered")
|
||||
.HasForeignKey("Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate.CatalogItemOrdered", "OrderItemId")
|
||||
.OnDelete(DeleteBehavior.Cascade);
|
||||
b1.WithOwner()
|
||||
.HasForeignKey("OrderItemId");
|
||||
});
|
||||
});
|
||||
#pragma warning restore 612, 618
|
||||
|
||||
Reference in New Issue
Block a user