func (r *GormWorkItemTypeRepository) ListPlannerItems(ctx context.Context, spaceID uuid.UUID) ([]WorkItemType, error) {
	var rows []WorkItemType
	path := path.Path{}
	db := r.db.Select("id").Where("space_id = ? AND path::text LIKE '"+path.ConvertToLtree(SystemPlannerItem)+".%'", spaceID.String())

	if err := db.Find(&rows).Error; err != nil {
		log.Error(ctx, map[string]interface{}{
			"space_id": spaceID,
			"err":      err,
		}, "unable to list the work item types that derive of planner item")
		return nil, errs.WithStack(err)
	}
	return rows, nil
}
// List returns work item types that derives from PlannerItem type
List returns work item types that derives from PlannerItem type
// List returns work item types that derives from PlannerItem type
func (r *GormWorkItemTypeRepository) ListPlannerItems(ctx context.Context, spaceID uuid.UUID) ([]WorkItemType, error) {
	var rows []WorkItemType
	path := path.Path{}
	db := r.db.Select("id").Where("space_id = ? AND path::text LIKE '"+path.ConvertToLtree(SystemPlannerItem)+".%'", spaceID.String())
	if err := db.Find(&rows).Error; err != nil {
		log.Error(ctx, map[string]interface{}{
			"space_id": spaceID,
			"err":      err,
		}, "unable to list the work item types that derive of planner item")
		return nil, errs.WithStack(err)
	}
	return rows, nil
}
func ( r * GormWorkItemTypeRepository ) ListPlannerItems ( ctx context . Context , spaceID uuid . UUID ) ( [ ] WorkItemType , error ) { var rows [ ] WorkItemType path := path . Path { } db := r . db . Select ( " " ) . Where ( " " + path . ConvertToLtree ( SystemPlannerItem ) + " " , spaceID . String ( ) ) if err := db . Find ( & rows ) . Error ; err != nil { log . Error ( ctx , map [ string ] interface { } { " " : spaceID , " " : err , } , " " ) return nil , errs . WithStack ( err ) } return rows , nil }
List returns work item types that derives from PlannerItem type
List returns work item types that derives from PlannerItem type