cancel
Showing results for 
Search instead for 
Did you mean: 

URL iview with <user.id> as part of the URL address

Former Member
0 Kudos

Dear all,

I want to create an URL iview in order to display a KMfile, which its access link depends on <user.id>.

e.g

http://PORTAL_PATH/com.sap.km.cm.docs/<b><user.id>/</b>File.pdf

Any hint or idea, is more than welcome

Many thanks

Vasso

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Try this:

http://PORTAL_PATH/com.sap.km.cm.docs/documents/alias/<user.id>/File.pdf

so when the userId is "user01" the RID for this document is:

/documents/user01/File.pdf

Check (decompile) class <b>com.sapportals.wcm.service.urlgenerator.URLGenerator</b> method <b>replacePlaceholder</b>, <b>replace</b> for possible entries.

Romano

Former Member
0 Kudos

hi Romano,

thanks for your reply, but unfortunately but it doesn't work.

No replacement did happened. The "alias/<user.id>" is part of the URL address as a string.

Because I am new in portal enviroment, what do you mean by "Check (decompile) class com.sapportals..."

Thanks again

Vasso

Former Member
0 Kudos

Uf, sorry

the alias has to be the first element of the RID.

So if the RID is:

/documents/user01/tester.txt

and user01 is logged in, call:

.../irj/go/km/docs/~alias~/documents/<user.id>/tester.txt

or:

.../irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/~alias~/documents/<user.id>/tester.txt

(i've tested it now for being sure).

Romano

Former Member
0 Kudos

hi Romano,

many many thanks!!!

It is working!!

thanks

vasso

detlev_beutner
Active Contributor
0 Kudos

Hi Vasso,

just don't use an URL iView but directly a km.cm.docs iView to show the document.

> what do you mean by

> "Check (decompile) class com.sapportals..."

To understand portal functionality, even if documentation gets better and better, it is <i>very often</i> needed to decompile the class implementations to get further insight how things happen. For this a good Java knowledge as well as a good decompiler (e.g. DJ/JAD) is needed.

Hope it helps

Detlev

Former Member
0 Kudos

Detlev,

thank you very much, for your advice about KM iview. I haven't thought about it.

Is there any option in order to open the document (excel in my case) as Readonly?

many thanks

again

detlev_beutner
Active Contributor
0 Kudos

Hi,

you can lock documents on KM. This is maybe what you are thinking of?! See http://help.sap.com/saphelp_nw04/helpdata/en/1b/ceabdb2883a1418e8da5d973d7983b/frameset.htm

Hope it helps

Detlev

Answers (0)