public IEnumerable <FileInfo> Get() { try { return(_repo.GetImagesInfo()); } catch (Exception e) { _logger.Error(e); throw; } }
public IEnumerable <FileInfo> GetProductImages(Guid idProduct) { var ids = _commonDb.Query <Guid>("select idImage from ProductImages where idProduct = @idProduct", new { idProduct }).ToArray(); if (ids.Length == 0) { return new FileInfo[] { } } ; return(_imageRepo.GetImagesInfo(ids)); } }