예제 #1
0
        public ICollection <ProductImage> GetProductImagesByProduct(int productId)
        {
            List <BLL.Models.ProductImage> list = new List <BLL.Models.ProductImage>();

            foreach (var item in _dal.GetProductImagesByProduct(productId))
            {
                var image = new BLL.Models.ProductImage
                {
                    Id        = item.Id,
                    ProductId = item.ProductId,
                    Image     = item.Image
                };
                list.Add(image);
            }
            return(list);
        }