コード例 #1
0
        public async Task <IReadOnlyList <Order1> > GetOrdersForUserAsync(string buyerEmail)
        {
            var spec = new OrdersWithItemsAndOrderingSpecification1(buyerEmail);

            return(await _unitOfWork.Repository <Order1>().ListAsync(spec));
        }
コード例 #2
0
        public async Task <Order1> GetOrderByIdAsync(int id, string buyerEmail)
        {
            var spec = new OrdersWithItemsAndOrderingSpecification1(id, buyerEmail);

            return(await _unitOfWork.Repository <Order1>().GetEntityWithSpec(spec));
        }