cancel
Showing results for 
Search instead for 
Did you mean: 

Categories: Own classification and lucene search

ironman77
Champ in-the-making
Champ in-the-making
Hi,

following this wiki article (and using alfresco-community-2.1):
http://wiki.alfresco.com/wiki/Classification_And_Categories [

i tried to add my own classification aspect. This includes the following steps:

1. Add a new aspect:

<aspect name="cm:workEquipment">
   <title>Work Equipment</title>
   <parent>cm:classifiable</parent>
   <properties>
      <property name="cm:workEquipment">
         <type>d:category</type>
         <index enabled="true">
            <atomic>true</atomic>
            <stored>true</stored>
            <tokenised>true</tokenised>
         </index>
      </property>
   </properties>
</aspect>


Following the wiki article, i extended cm:classifiable.

2. Adding a new node to cm:categoryRoot (Store: workspace://SpacesStore)

/cm:categoryRoot/cm:workEquipment

Using the CategoryService im am able to add new RootCategories and Categories beneath this node.

Searching via lucene for categories does work:

PATH:"/cm:workEquipment/cm:test123/*"

3. Adding a new document with the aspect cm:workEquipment and the property cm:workEquipment which contains a link to my category test123.

The following lucene search does not work:

PATH:"/cm:workEquipment/cm:test123/member"

It returns a empty result.

That leeds to some questions:

1. What is the weak link mentioned in the wiki between the aspect and the classification?
Assumption: apsect name cm:workEquipment , classification name cm:workEquipment
2. Does the namespace prefix needs to be equal, for example cm or could the aspect have another namespace?
3. Why does the query with member has no results? What is my setup error?
1 REPLY 1

rivarola
Champ on-the-rise
Champ on-the-rise
2. Adding a new node to cm:categoryRoot (Store: workspace://SpacesStore)

/cm:categoryRoot/cm:workEquipment


Using the CategoryService im am able to add new RootCategories and Categories beneath this node.

Hello,

This node cm:workEquipment should be your category root and not contain it.