Ticket #882 (closed Enhancement: duplicate)
dm-files: storeFile same as with getResourceInfo
Reported by: | Malte | Owned by: | jri |
---|---|---|---|
Priority: | Major | Milestone: | Release 4.8 |
Component: | DeepaMehta Standard Distribution | Version: | 4.7 |
Keywords: | Cc: | ||
Complexity: | 3 | Area: | |
Module: | deepamehta-files |
Description
When trying to store a file into a subfolder of my repo, the global file repo is used (despite per_workspace repos are ON):
StoredFile file = fileService.storeFile(image, "/images");
leads to:
Nov 11, 2015 12:22:39 PM de.deepamehta.plugins.files.FilesPlugin storeFile INFORMATION: Storing file "tumblr_nqz7iaCoHh1qz7lxdo1_1280.jpg" (image/jpeg, 145073 bytes) at repository path "/images" Nov 11, 2015 12:22:39 PM de.deepamehta.plugins.files.FilesPlugin checkPath INFORMATION: Checking path "/home/malted/Schreibtisch/filerepo-test/images" dm4.filerepo.path="/home/malted/Schreibtisch/filerepo-test" => PATH OK
This means, currently, to store a file in the correct filerepo, plugin developers must check a) the per_workspace flag and b) inspect the "dm4_workspace_id" cookie.
Would be great if the dm4-files plugin could serve other plugin developers in doing so.
Change History
Note: See
TracTickets for help on using
tickets.
Changed title of ticket from "dm-files: createFile same as with getResourceInfo" to "dm-files: storeFile same as with getResourceInfo", cause i haven't actually checked the createFile()-call.