on 10-12-2007 9:53 AM
We use WebDAV intensively to migrate content from our legacy portal to EP6. Creating folders and uploading documents from Excel/VBA works just fine.
For one of our projects we would like to create Internal link objects pointing to other KM resources (HTML pages, actually). Luckily, the WebDAV service supports the MKREDIRECTREF function of RFC. So sending a HTTP request with the action MKREDIRECTREF and the body
<D:mkredirectref xmlns:D="DAV:">
<D:reftarget>
<D:href>/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/.../Testtext.txt</D:href>
</D:reftarget>
</D:mkredirectref>
creates indeed a link. The links works like a link created in the Portal, except for one thing: if the target of the links is moved, the link is not updated.
This is even visible in the WebDAV property "resourcetype" of the link object.
For a link created in KM with the KM UI, the resourcetype is this.
<D:resourcetype>
<D:redirectref>
<internal-link xmlns="http://sapportals.com/xmlns/cm/webdav">
<dynamic/>
</internal-link>
</D:redirectref>
</D:resourcetype>
For my WebDAV link I receive:
<D:resourcetype>
<D:redirectref/>
</D:resourcetype>
Question: how can links of the type internal-link/dynamic be created using WebDAV?
I believe you'll need a SAP-specific extension in the request.
Try:
<D:mkredirectref xmlns:D="DAV:">
<link-type xmlns="http://sapportals.com/xmlns/cm/webdav">
<internal-link xmlns="http://sapportals.com/xmlns/cm/webdav"><dynamic/></internal-link>
</link-type>
<D:reftarget>
<D:href>/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/.../Testtext.txt</D:href>
</D:reftarget>
</D:mkredirectref>
The response should contain a similar element signaling whether the extension was understood.
Note that dynamic internal links aren't understood by all repository managers, though.
Best regards, Julian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The link nearly acts, works and looks like one created using the KM user interface - with one exception: for the display name the Portal does not use the ID, but the name of the link target minus extension.
Adding a displayname element to the mkredirectref did not help. I guess I'll have to PROPPTACH the link to change the display name...
User | Count |
---|---|
95 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.