From 93f358f9901ef0bb597520e1c4c23e23248f540a Mon Sep 17 00:00:00 2001 From: MarcEricMartel <74071476+MarcEricMartel@users.noreply.github.com> Date: Tue, 18 Oct 2022 12:15:57 -0700 Subject: [PATCH] moneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoneymoney --- .../GrossesMitainesAPI/Controllers/InventoryController.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/GrossesMitaines/GrossesMitainesAPI/Controllers/InventoryController.cs b/GrossesMitaines/GrossesMitainesAPI/Controllers/InventoryController.cs index 40baa59..5869410 100644 --- a/GrossesMitaines/GrossesMitainesAPI/Controllers/InventoryController.cs +++ b/GrossesMitaines/GrossesMitainesAPI/Controllers/InventoryController.cs @@ -62,10 +62,10 @@ public class InventoryController : Controller { switch (order) { case "Price": - ret = ret.OrderBy(x => x.Status == Product.States.Promotion? x.PromoPrice: x.Price); + ret = ret.OrderBy(x => x.Status == Product.States.Promotion || x.Status == Product.States.Clearance? x.PromoPrice: x.Price); break; case "PriceDesc": - ret = ret.OrderByDescending(x => x.Status == Product.States.Promotion ? x.PromoPrice : x.Price); + ret = ret.OrderByDescending(x => x.Status == Product.States.Promotion || x.Status == Product.States.Clearance ? x.PromoPrice : x.Price); break; case "Title": ret = ret.OrderBy(x => x.Title);