cancel
Showing results for 
Search instead for 
Did you mean: 
resplin
Elite Collaborator
Elite Collaborator

Obsolete Pages{{Obsolete}}

The official documentation is at: http://docs.alfresco.com



Content Modeling
Depending on how complex the forums functionality needs to be and it's intended use the model we use could be very simple, mainly because a lot of the infrastructure required is already in the Alfresco stack i.e. users, categories, forums/topics/posts map to folders/content and we have an inline editor.

Functionality to build


  • Forum, topic and post view renderers
  • We'll also need a way to tell the browse view which default renderer to use for a given node type (we may also want this at a higher level i.e. dispatch a completely different JSP for a given node type)
  • Additional pages to allow posting and attachment of discussions to 'nodes'
  • If we want to support smilies we'll need a way to interpret those i.e. display images in view mode, this may be an opportunity to start working on a very simple wiki text transformation engine.

Model

As mentioned above the whole forums model maps quite nicely to folders and contents. We could therefore extend the Alfresco model as shown below, all new types are highlighted in green.



Forums-model.gif



A post is just an extentsion of cm:content, the subject can be driven from the name and the text of the post can be stored in the content property of cm:content. To store the 'poster' we can make use of the creator property from the auditable aspect.

A topic is just an extenstion of cm:folder. The orderedchildren property could be used to order the posts or we could just make the view order by createddate. The title, description and icon for the topic are supplied via the titled and uifacets aspects (the icon could be used to denote what the topic is about i.e. a question, a bug report etc.). The type property is used to show whether the topic is sticky, an announcement or a 'normal' topic. The creator property will be used to represent the author of the topic.

Again, a forum is just an extenstion of cm:folder (it may have a further constraint in the data dictionary though of only have topic or forum children). The status property allows the forum to be locked or set to read-only.

Sub forums are modelled using the implicit contains association inherited from the cm:folder type.

An attachable aspect will also be added to the system. This will allow arbitary cmSmiley Surprisedbjects in the repository to be attached to objects that have the attachable aspect applied. This aspect will allow attachments to be added to forum articles.

Finally, any cmSmiley Surprisedbject in the repository can be discussed by applying the discussable aspect. This new aspect will have an association or property that points to a forum.