Basket : Improve, reduce, remove duplication call to database (#610)

This commit is contained in:
Cédric Michel
2021-11-01 22:09:34 +01:00
committed by GitHub
parent 47f69eb294
commit 984740d422
9 changed files with 76 additions and 79 deletions

View File

@@ -1,4 +1,5 @@
using Microsoft.eShopWeb.Web.Pages.Basket;
using Microsoft.eShopWeb.ApplicationCore.Entities.BasketAggregate;
using Microsoft.eShopWeb.Web.Pages.Basket;
using System.Threading.Tasks;
namespace Microsoft.eShopWeb.Web.Interfaces
@@ -6,5 +7,9 @@ namespace Microsoft.eShopWeb.Web.Interfaces
public interface IBasketViewModelService
{
Task<BasketViewModel> GetOrCreateBasketForUser(string userName);
Task<int> CountTotalBasketItems(string username);
Task<BasketViewModel> Map(Basket basket);
}
}