CMS-1597 Refactor storing of attachments aka binaries in tree-model