Untitled

mail@pastecode.io avatar
unknown
plain_text
8 months ago
473 B
3
Indexable
Never
public async Task<List<Product>> GetByGmail(string gmail)
{
    List<Product> products = await _context.Products
                                        .Join(_context.Carts.Where(c => c.EmailId == gmail),
                                              p => p.ProductId,
                                              c => c.ProductId,
                                              (p, c) => p)
                                        .ToListAsync();

    return products;
}
Leave a Comment