diff --git a/src/ApiGateways/Web.Bff.Shopping/aggregator/Startup.cs b/src/ApiGateways/Web.Bff.Shopping/aggregator/Startup.cs index edbb232f4..c1df2553e 100644 --- a/src/ApiGateways/Web.Bff.Shopping/aggregator/Startup.cs +++ b/src/ApiGateways/Web.Bff.Shopping/aggregator/Startup.cs @@ -20,14 +20,15 @@ public class Startup .AddUrlGroup(new Uri(Configuration["OrderingUrlHC"]), name: "orderingapi-check", tags: new string[] { "orderingapi" }) .AddUrlGroup(new Uri(Configuration["BasketUrlHC"]), name: "basketapi-check", tags: new string[] { "basketapi" }) .AddUrlGroup(new Uri(Configuration["IdentityUrlHC"]), name: "identityapi-check", tags: new string[] { "identityapi" }) - .AddUrlGroup(new Uri(Configuration["PaymentUrlHC"]), name: "paymentapi-check", tags: new string[] { "paymentapi" }); + .AddUrlGroup(new Uri(Configuration["PaymentUrlHC"]), name: "paymentapi-check", tags: new string[] { "paymentapi" }) + .AddUrlGroup(new Uri(Configuration["CouponUrlHC"]), name: "couponapi-check", tags: new string[] { "couponapi" }); // HC dependency is configured this way to save one build step on ACR - var couponHealthEndpoint = Configuration["CouponUrlHC"]; - if (!string.IsNullOrWhiteSpace(couponHealthEndpoint)) - { - healthCheckBuilder.AddUrlGroup(new Uri(couponHealthEndpoint), name: "couponapi-check", tags: new string[] { "couponapi" }); - } + //var couponHealthEndpoint = Configuration["CouponUrlHC"]; + //if (!string.IsNullOrWhiteSpace(couponHealthEndpoint)) + //{ + // healthCheckBuilder.AddUrlGroup(new Uri(couponHealthEndpoint), name: "couponapi-check", tags: new string[] { "couponapi" }); + //} services.AddCustomMvc(Configuration) .AddCustomAuthentication(Configuration) diff --git a/src/ApiGateways/Web.Bff.Shopping/aggregator/appsettings.localhost.json b/src/ApiGateways/Web.Bff.Shopping/aggregator/appsettings.localhost.json index 09b165a03..feec6edca 100644 --- a/src/ApiGateways/Web.Bff.Shopping/aggregator/appsettings.localhost.json +++ b/src/ApiGateways/Web.Bff.Shopping/aggregator/appsettings.localhost.json @@ -7,6 +7,6 @@ "grpcBasket": "http://localhost:5580", "grpcCatalog": "http://localhost:81", "grpcOrdering": "http://localhost:5581", - "coupon": "http://localhost:55106" + "coupon": "http://localhost:5106" } } diff --git a/src/Services/Ordering/Ordering.API/Application/Queries/OrderQueries.cs b/src/Services/Ordering/Ordering.API/Application/Queries/OrderQueries.cs index 8871a441f..6db5506eb 100644 --- a/src/Services/Ordering/Ordering.API/Application/Queries/OrderQueries.cs +++ b/src/Services/Ordering/Ordering.API/Application/Queries/OrderQueries.cs @@ -20,9 +20,9 @@ public class OrderQueries @"select o.[Id] as ordernumber,o.OrderDate as date, o.Description as description, o.Address_City as city, o.Address_Country as country, o.Address_State as state, o.Address_Street as street, o.Address_ZipCode as zipcode, os.Name as status, - oi.ProductName as productname, oi.Units as units, oi.UnitPrice as unitprice, oi.PictureUrl as pictureurl - o.DiscountCode as coupon - o.Discount as discount, + oi.ProductName as productname, oi.Units as units, oi.UnitPrice as unitprice, oi.PictureUrl as pictureurl, + o.DiscountCode as coupon, + o.Discount as discount FROM ordering.Orders o LEFT JOIN ordering.Orderitems oi ON o.Id = oi.orderid LEFT JOIN ordering.orderstatus os on o.OrderStatusId = os.Id diff --git a/src/docker-compose.override.yml b/src/docker-compose.override.yml index db11c71e8..4625c5eb8 100644 --- a/src/docker-compose.override.yml +++ b/src/docker-compose.override.yml @@ -189,7 +189,7 @@ services: - IdentityUrlExternal=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5105 - UseLoadTest=${USE_LOADTEST:-False} - PORT=80 - - PATH_BASE=/catalog-api + - PATH_BASE=/coupon-api - ConnectionString=mongodb://nosqldata:27017 ports: - "5106:80" @@ -222,6 +222,7 @@ services: - urls__grpcOrdering=http://ordering-api:81 - CatalogUrlHC=http://catalog-api/hc - OrderingUrlHC=http://ordering-api/hc + - CouponUrlHC=http://coupon-api/hc - IdentityUrlHC=http://identity-api/hc - BasketUrlHC=http://basket-api/hc - PaymentUrlHC=http://payment-api/hc @@ -242,6 +243,7 @@ services: - urls__grpcOrdering=http://ordering-api:81 - CatalogUrlHC=http://catalog-api/hc - OrderingUrlHC=http://ordering-api/hc + - CouponUrlHC=http://coupon-api/hc - IdentityUrlHC=http://identity-api/hc - BasketUrlHC=http://basket-api/hc - PaymentUrlHC=http://payment-api/hc diff --git a/src/docker-compose.prod.yml b/src/docker-compose.prod.yml index 73e52822c..7a6df312c 100644 --- a/src/docker-compose.prod.yml +++ b/src/docker-compose.prod.yml @@ -119,6 +119,7 @@ services: - IdentityUrlHC=http://identity-api/hc #Local: Use ${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}, if using external IP or DNS name from browser. - BasketUrlHC=http://basket-api/hc - PaymentUrlHC=http://payment-api/hc + - CouponUrlHC=http://coupon-api/hc - UseCustomizationData=True - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY} - OrchestratorType=${ORCHESTRATOR_TYPE} @@ -136,6 +137,7 @@ services: - IdentityUrlHC=http://identity-api/hc #Local: Use ${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}, if using external IP or DNS name from browser. - BasketUrlHC=http://basket-api/hc - PaymentUrlHC=http://payment-api/hc + - CouponUrlHC=http://coupon-api/hc - UseCustomizationData=True - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY} - OrchestratorType=${ORCHESTRATOR_TYPE}