cancel
Showing results for 
Search instead for 
Did you mean: 

metadata extension

Former Member
0 Kudos

Hello !

I need a property which has different lists of values depending on a folder of the resource. I'm trying to create metadata extension using <a href="https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/645d4357-0701-0010-07bd-a2e">Prerequisites and Relevant Knowledge Management APIs</a> as an example.

There is a problem - how to get the folder of the resource from the method getAllowedValues ?

The parameter metaContext is always null and there seems to be no other way to get it.

Accepted Solutions (0)

Answers (2)

Answers (2)

thilo_brandt
Employee
Employee
0 Kudos

Hi Alex,

the meta context information is bound to the property definition of the property metadata service. It get onlny then not equal null (!=null), if the property the dynamic value provider is assigned to, is already persisted in the RF (repository framework). Espacially if you call a creator function like New Textfile, Upload, etc. it will always be null.

Kind regards,

Thilo

Former Member
0 Kudos

Hello !

Maybe there is another means to get current folder of the user, who create resource ?

Former Member
0 Kudos

Hi,

Have you read Working with Metadata Properties in KM document and How to configure Predefined Properties with Dependent Values ?

Both of document can be downloaded from this site.

The idea is that you can have different metadata values depending on the folder.

Patricio.

Former Member
0 Kudos

Hello !

Thank you for the interesting links. But I do not see how they can help me. Dependent properties is not my case because it requires the user to choose some property to change the list of values for the other property.

Former Member
0 Kudos

Hi Alex,

You can download an example about metadata extension from:

https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/6b30b090-0201-0010-829d-e98...

Guide to examples:

Sample for implementing a metadata extension for KMC properties.

com.sap.netweaver.kmc.metaextension.zip

Patricio.

Former Member
0 Kudos

Hello !

Sorry, I have given a wrong link in my previous message. I have used the same example which you have given.

The problem is how to get the folder of new created or edited resource from getAllowedValues. If I will know it I can change the list of values.