BusinessTemplate: fix removing and trashing a document and its container
Because we were backing up to trash documents in the wrong order (in the example from the test, portal_categories/test_category/removed_container/removed_document first and then portal_categories/test_category/removed_container), first the document was backed-up and some intermediate trash folders were created to keep the hierarchy. Then when backing up the container, there was an error like:
BadRequest: The id "removed_container" is invalid - it is already in use.
Similar error happens when upgrading erp5_configurator_standard, it was failing with:
BadRequest: The id "officejs_sdk_workflow" is invalid - it is already in use.
The fix is to backup in reverse order, to back up first the containers and then the document in containers.