cancel
Showing results for 
Search instead for 
Did you mean: 

Metadata formed by spaces

ruizja
Champ in-the-making
Champ in-the-making
I need to create a property for a custom node that contains a list of drop-down spaces children of another space. For example:

Space1 contains Space2 and Space3

I need a custom node with a property formed by Space2 or Space3.

Is it possible?
Thanks,
Javier
1 REPLY 1

cbosdonnat
Champ in-the-making
Champ in-the-making
Hi Javier,

I need to create a property for a custom node that contains a list of drop-down spaces children of another space.

This is completely possible. You will have to have a look at this page of the wiki:
http://wiki.alfresco.com/wiki/Displaying_Custom_Metadata#Component_Generators

To summarize it:
  • You need to add an element in the web-client-config-custom.xml file to tell the web client to render your property. In this configuration, you will need to refer to a custom Component Generator, let's say MySpacesPickerGenerator.

  • You will need to define your component generator in the faces-config-custom.xml file like this:

<managed-bean>
   <description>
      Bean that generates a list of spaces
   </description>
   <managed-bean-name>MySpacesPickerGenerator</managed-bean-name>
   <managed-bean-class>org.alfresco.sample.MySpacesPickerGenerator</managed-bean-class>
   <managed-bean-scope>request</managed-bean-scope>
</managed-bean>
  • Then create the implementation of the component generator (here: org.alfresco.sample.MySpacePickerGenerator).
You can get some inspiration from the classes extending BaseComponentGenerator.

HTH