diff --git a/LittleShop/Services/ProductService.cs b/LittleShop/Services/ProductService.cs index 9ba2bf8..9b86a9d 100644 --- a/LittleShop/Services/ProductService.cs +++ b/LittleShop/Services/ProductService.cs @@ -21,8 +21,8 @@ public class ProductService : IProductService return await _context.Products .Include(p => p.Category) .Include(p => p.Photos) - .Include(p => p.MultiBuys.Where(v => v.IsActive)) - .Include(p => p.Variants.Where(v => v.IsActive)) + .Include(p => p.MultiBuys) + .Include(p => p.Variants) .Where(p => p.IsActive) .Select(p => new ProductDto { @@ -143,8 +143,8 @@ public class ProductService : IProductService var product = await _context.Products .Include(p => p.Category) .Include(p => p.Photos) - .Include(p => p.MultiBuys.Where(v => v.IsActive)) - .Include(p => p.Variants.Where(v => v.IsActive)) + .Include(p => p.MultiBuys) + .Include(p => p.Variants) .FirstOrDefaultAsync(p => p.Id == id); if (product == null) return null;