AnsweredAssumed Answered

Seeking answer for a Custom content model case study

Question asked by ishachadha on Aug 2, 2011
Hi aLL,

I am after some more piece of information regarding the custom content model.
We are storing documents in our repository and each have got a reference id. Now these documents could be 'questions' and 'answers' or may be a different category.

We want to be able to figure out a way to assiciate the two or more; so that in the Alfreso user interface when we see the properties
for Question1 document, we are able to display 'Related documents' list as below:

Question1:
Reference Id:  Ques1
Title:         ABC question

Related Documents:
Reference Id                             Category
Answer1                                    Answer
Answer2                                    Answer
Question2                                 Question

I have created following so far:

1) <type name="my:relatedDocument">
   <title>Related Document</title>
   <parent>cm:cmobject</parent>
   <properties>
      <property name="my:relatedDocsRefId">
             <title>Related Document Reference ID</title>
        <type>d:text</type>
      </property>
      <property name="my:relatedDocsCategory">
        <title>Related Document Category</title>
        <type>d:text</type>
      </property>
   </properties>
  </type>   

2) <aspect name="my:aspect-related-documents">
         <title>Related Documents</title>
         <properties>
         <property name="my:relatedDocument">
               <title>Related Document</title>
               <type>d:text</type>
               <multiple>true</multiple>
               <index enabled="true">
                  <atomic>true</atomic>
                  <stored>true</stored>
                  <tokenised>false</tokenised>
               </index>
         </property>
         </properties>
</aspect>

Can you please suggest the best possible way of doing this?

Thanks and Regards,
Isha

Outcomes