replace counter by specific query to avoid load each items in memory (#611)

* replace counter by specific query to avoid load each items in memory

* Create IBasketQueryService
This commit is contained in:
Cédric Michel
2021-11-02 15:16:57 +01:00
committed by GitHub
parent 553a10187d
commit 64f150dc07
7 changed files with 50 additions and 129 deletions

View File

@@ -0,0 +1,9 @@
using System.Threading.Tasks;
namespace Microsoft.eShopWeb.ApplicationCore.Interfaces
{
public interface IBasketQueryService
{
Task<int> CountTotalBasketItems(string username);
}
}

View File

@@ -1,11 +0,0 @@
using Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate;
using System.Threading.Tasks;
namespace Microsoft.eShopWeb.ApplicationCore.Interfaces
{
//public interface IOrderRepository : IAsyncRepository<Order>
//{
// Task<Order> GetByIdWithItemsAsync(int id);
//}
}