public Image GetImageWithThumbnailsAndGallery(int idImage) { var builder = new BuilderImage(DbSet); builder.Id(idImage); builder.IncludeGallery(); builder.IncludeThumbnails(); return(builder.Query.FirstOrDefault()); }
public List <Image> GetParentImagesByGallery(int idGallery, bool?visible = null) { var builder = new BuilderImage(DbSet); if (visible.HasValue) { builder.IsVisible(visible.Value); } builder.InGallery(idGallery); builder.IsParent(); builder.IncludeThumbnails(); return(builder.ToList()); }