Designer
Using designer
- Start Alfresco;
- Initialize beCPG. Go to beCPG menu --> Administration and click on "Initialize repository";
- Designer is then accessible to the url: /share/page/model-designer.
This vidéo shows a demonstration of designer usage.
To add a new model to the designer, load a model file into folder "Data dictionnary/Models". To add a form config file, load the xml file into folder "Data dictionnary/Configs".
Warning:
Once a model is published and you start using it, it's really hard to remove it without scripting. So consider always testing your model before production. Once a model is published, only incremental changes are permitted (fields addons).
Designer FAQ
How can I see my published model into change-type menu ?
The designer doesn't allow showing types and aspects automatically into Alfresco Share.
Create the file tomcat/shared/classes/alfresco/web-extension/share-config-custom.xml and as in the sample file add your aspects and types as this:
<code class="xml">
<config evaluator="string-compare" condition="DocumentLibrary" replace="true">
<aspects>
<!-- Aspects that a user can see -->
<visible>
<aspect name="cm:generalclassifiable" />
<aspect name="cm:complianceable" />
<aspect name="cm:dublincore" />
<aspect name="cm:effectivity" />
<aspect name="cm:summarizable" />
<aspect name="cm:versionable" />
<aspect name="cm:templatable" />
<aspect name="cm:emailed" />
<aspect name="emailserver:aliasable" />
<aspect name="cm:taggable" />
<aspect name="app:inlineeditable" />
<aspect name="gd:googleEditable" />
<aspect name="cm:geographic" />
<aspect name="exif:exif" />
</visible>
<!-- Aspects that a user can add. Same as "visible" if left empty -->
<addable>
</addable>
<!-- Aspects that a user can remove. Same as "visible" if left empty -->
<removeable>
</removeable>
</aspects>
<!--
Used by the "Change Type" action
Define valid subtypes using the following example:
<type name="cm:content">
<subtype name="cm:mysubtype" />
</type>
Remember to also add the relevant i18n string(s):
cm_mysubtype=My SubType
-->
<types>
<type name="cm:content">
</type>
<type name="cm:folder">
</type>
</types>
</config>
</code>
How to create a type that you can use directly as dataList ?
- Define your content types. Make sure all your types inherit d:dataListItem;
- Define your forms;
- Publish the models and forms;
- Go to "Datalist" page on the template (ie: project template) and try to add new list. You will see your types in the dialog.
Why do I get found non-incrementally updated TYPE ?
Once a model is published and you start using it, it's really hard to remove it without scripting. So consider always testing your model before production. Once a model is published, only incremental changes are permitted (fields addons).
Next version will permit to force removing existing fields and to force non-incremental changes.