07-20-2017 10:25 AM
In the PathSegmentServiceDefault
class the method generatePathSegment
has some logic to replace a doc name composed entirely of special characters (e.g. -.,;?!:'-.,;?!:'-.,;?!:'
) with a random number, but then it allows the doc to be created anyway with the name as originally provided. Is there any particular reason one should preserve this functionality if overriding the default path segment service?
07-20-2017 10:50 AM
What do you mean by then it allows the doc to be created anyway with the name as originally provided? The idea here is to generate the path segment only (visible in the url or in the database as the "name" column, and unique per folder). This service does nothing about changing the document's title.
07-20-2017 01:29 PM
I guess what I'm asking is - if I save a document "FOO" the name field in the hierarchy table is "FOO" but if I save a document called (odd name from above) then the name field in the hierarchy table is "123523452345425764"... So the question is - am I in peril if I modify this behavior
07-20-2017 02:16 PM
No there's no danger in changing this behavior. Nuxeo only does it to avoid ugly URLs with lots of escaped characters in the rare cases where documents have strange names without alphanumeric parts.
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.