AnsweredAssumed Answered

adding metadata sets multiple times

Question asked by abruzzi on Sep 25, 2014
Latest reply on Sep 29, 2014 by kaynezhang
I got the following request from a user:

We have Sheriff case files that are used to track investigations/citations/etc..  We use an aspect to add case specific meta.  They would like to be able to add an indeterminate amount of "suspects" as meta data.  Most cases will only have one, some will have two, some more, depending on the crime and investigation, etc.

The only way I can see doing this with an aspect is picking a large number–say 8–and if you only have one, then you only fill the first field and leave the rest blank.  This is bad for several reasons–useless clutter for most crimes, can't expand beyond 8 for the rare crime that has more, and most problematic, each of those 8 fields is technically a different field making searching across them difficult.

I haven't seen anything in the content modelling, i.e. types, aspects, properties, that would cover this.  Am I correct?

It seems like the most likely way to make something like this happen is through association (either parent/child or peer/peer).  It seems like, for example, the way you can comment on a document in share, and the comments show up as child nodes (actually I think with comments, there is a forum node that is a child of the document, then the comments are children of the forum.) 

Anyway, is this the best approach to solve this problem?  Are there any good (simple) examples out there of how you would begin to implement this?  I'm not entirely sure where to begin. 

I'm guessing I'd create a type "sheriff-suspect"  that has the necessary properties, but should it be derived from cm:content, sys:base or somewhere else?  Any other thoughts on how you would implement something like this would be helpful.