volume_up

A critical vulnerability was discovered in React Server Components (Next.js). Our systems remain protected but we advise to update packages to newest version. Learn More

volume_up

A critical vulnerability was discovered in React Server Components (Next.js). Our systems remain protected but we advise to update packages to newest version. Learn More

List unpublished children

Hi! It seems that GetChildren() in IContentRepository only returns published pages. How do I get a list of all children, including the unpublished ones?

Regards Christer

#87592
Jun 17, 2014 15:58
Vote:
try this
 var pages = DataFactory.Instance.GetChildren(CurrentPage.PageLink, LanguageSelector.AutoDetect(true));
#87595
Jun 17, 2014 17:01

I find it odd but maybe there is a reason for this that in ordered to get unpublished pages, you have to pass in a language.  This is right K Khan but you would think and overload for Publish status or booleaon for get children would accept the following.  I have always been baffled by this but I am not the dev but have found it curious.

#87600
Jun 17, 2014 18:57

Thanks! Adding a languageselector to GetChildren() returns all the pages. Weird...

#87631
Jun 18, 2014 13:34
error This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.