code: func (c *WorkitemController) ListChildren(ctx *app.ListChildrenWorkitemContext) error {
  	offset, limit := computePagingLimits(ctx.PageOffset, ctx.PageLimit)
  	var result []workitem.WorkItem
  	var count int
  	var wits []workitem.WorkItemType
  	err := application.Transactional(c.db, func(appl application.Application) error {
  		var err error
  		result, count, err = appl.WorkItemLinks().ListWorkItemChildren(ctx, ctx.WiID, &offset, &limit)
  		if err != nil {
  			return errs.Wrap(err, "unable to list work item children")
  		}
  		wits, err = loadWorkItemTypesFromArr(ctx.Context, appl, result)
  		if err != nil {
  			return errs.Wrap(err, "failed to load the work item types")
  		}
  		return nil
  	})
  	if err != nil {
  		return jsonapi.JSONErrorResponse(ctx, err)
  	}
  	return ctx.ConditionalEntities(result, c.config.GetCacheControlWorkItems, func() error {
  		var response app.WorkItemList
  		application.Transactional(c.db, func(appl application.Application) error {
  			hasChildren := workItemIncludeHasChildren(ctx, appl)
  			converted, err := ConvertWorkItems(ctx.Request, wits, result, hasChildren)
  			if err != nil {
  				return errs.WithStack(err)
  			}
  			response = app.WorkItemList{
  				Links: &app.PagingLinks{},
  				Meta:  &app.WorkItemListResponseMeta{TotalCount: count},
  				Data:  converted,
  			}
  			return nil
  		})
  		setPagingLinks(response.Links, buildAbsoluteURL(ctx.Request), len(result), offset, limit, count)
  		return ctx.OK(&response)
  	})
  }
docs: // ListChildren runs the list action.