[MGNLDMS-72] dms : paths to documents can be improved (duplicate objectname) Created: 06/Dec/06 Updated: 03/Jul/14 Resolved: 29/Nov/07 |
|
| Status: | Closed |
| Project: | Document Management System (closed) |
| Component/s: | None |
| Affects Version/s: | 1.1 |
| Fix Version/s: | 1.2-rc2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Magnolia International | Assignee: | Philipp Bärfuss |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Template: |
|
| Acceptance criteria: |
Empty
|
| Date of First Response: |
| Description |
|
From Matthew Schmidt: That sounds like a very valid remark to me |
| Comments |
| Comment by Philipp Bracher [ 08/Dec/06 ] |
|
The reason lays in the case you have a UTF8 document name. In magnolia we don't allow UTF8 names for node names to simplfy the urls. But in the dms you can provide an additional Title which supports UTF8. To support the UTF8 name of the file we add the title at the end of the url (properly encoded). This was the only way working through out the browser world. But in most of the cases the node name and the titlle are equal and the link looks a bit courious. Perhaps we should make the code checking the equality of name and title. |
| Comment by Rick Ross [ 08/Dec/06 ] |
|
Philipp, this seems like one of those cases where the original logic, viewed in isolation, appears to be solid. When viewed in the context of a large site with lots of resources, however, it just doesn't make sense to have this pathname element duplication be the default. Perhaps it could be an available option for those who wish to enable it, but be off by default. Or, as you suggested, Magnolia could examine the document name for UTF8 chars, and only add the extra pathname element where it is necessary. Rick |
| Comment by Tom Jensen [ 20/Aug/07 ] |
|
What if you made the process() method more forgiving in the DMSDownloadServlet to accommodate this? I'm thinking that using the same logic for finding the node on the redirect would be the most consistent behavior. It would just be replacing line 110 with something like this: String url = request.getRequestURI(); That would allow someone to use the URL /dms/directory/objectname.pdf and it would just automatically redirect to /dms/directory/objectname/UTF8objectname.pdf but the existing functionality of giving the full path would remain in tact. This also has the side benefit of allowing the UUIDLink class to work for generating portable links in paragraphs so if the file is moved in the dms the pages pointing to it will repoint appropriately. |
| Comment by Philipp Bracher [ 29/Nov/07 ] |
|
not duplicated anymore (only in cases where the node and file name differ) |