I created a document-type called "Item-List-Folder" that is a generic object to hold any and all lists of other document types.
I am currently setup to use it as a News folder and a Video folder.
I have been through ALL of the video tutorials and they are referencing the use of Services.ContentService.
So I have been trying to return a list of all the videos under the video item-list-folder and not getting anywhere.
public class VideoApiController : UmbracoApiController
{
public IEnumerable GetAllVideos()
{
var videoList = Services.ContentService.GetChildren(1077);
return videoList;
}
}
How do I return a list of all items under a node assigend as ListView?
API - return all items under listview node
I created a document-type called "Item-List-Folder" that is a generic object to hold any and all lists of other document types.
I am currently setup to use it as a News folder and a Video folder.
I have been through ALL of the video tutorials and they are referencing the use of Services.ContentService.
So I have been trying to return a list of all the videos under the video item-list-folder and not getting anywhere.
How do I return a list of all items under a node assigend as ListView?
Hi Brett,
Try like that:
What wrong with your code?
1077 - is it id of parent node what you want?
Is your content published ?
Thanks
Alex
is working on a reply...