pimcore/data-hub

[Improvement]: create folder GraphQL endpoints should recursively create folders

dkarlovi opened this issue · 0 comments

Improvement description

Currently, you need to manually create folders at each level by passing parent and key.

A much nicer UX would be to do it all in one go, meaning you create the folders recursively just like Pimcore already allows:

mutation {
  createObjectFolder(
    path:"/foo/bar"
    key:"bat"
  ) {
    id
    success
    message
  }
}

This would created /foo/bar/bat regardless if parents exist or not. If they don't, the request auto-creates them. This could be opt-in with a feature flag like recurse: true.