automation : how to find a way to access real document linked to a proxy document
In nuxeo automation, I don't see a way using the api to get, from a Document published in a section (this document is a Proxy document) how to get the identifier of the associated document stored in the workspace.
Any idea to solve this problem
You can try to use getSourceDocument
:
coreSession.getSourceDocument(proxyDocument.getRef());
This way you get the original document. Once you achieve that, you can retrieve its identifier.
doc.getVersionSeriesId()
should give you that.
Unfortunately I think it's not workng in my context as I used the api of automation and .getVersionSeriesId() (accesible from DocumentMode)is not accessible from org.nuxeo.ecm.automation.client.model.Document instance !
any other sugestion ?
If yes, I will have to wait 5.8 release to use this feature