cancel
Showing results for 
Search instead for 
Did you mean: 

Create a form in share with fields of a custom metadata type

armedia
Champ in-the-making
Champ in-the-making
Im using Alf3.3.3 , and Im trying to create a custom form (custom metadata) in ALfresco Share.

Modifications Performed:

toolbar.get.config.xml.

 <toolbar>
   <createContent>    
     <content mimetype="text/plain" icon="plain-text" label="menu.create-content.custom" formid="custom-form-id" />   
   </createContent>
   <actionSets>
      <actionSet id="default">
         <action type="action-link" id="onActionCopyTo" label="menu.selected-items.copy" />         
      </actionSet>
   </actionSets>
</toolbar>

share-custom-config.xml

<!– portal content configuration creating nodes –>
        <config evaluator="model-type" condition="vp:portalContent">
            <forms>
                <form id= "custom-form-id">
                    <field-visibility>
                                   <show id="vp:portalContent_program" for-mode="view,edit,create" />
                                  <show id="vp:portalContent_publication_date" for-mode="view,edit,create" />
   
                                  <show id="vp:portalContent_page" for-mode="view,edit,create" />
                                  <show id="vp:portalContent_section" for-mode="view,edit,create" />
                                  <show id="vp:portalContent_category" for-mode="view,edit,create" />
                                  <show id="vp:portalContent_article" for-mode="view,edit,create" />
                      </field-visibility>
                   </form>
                </forms>
        </config>

When I restart tomcat, i do get the custom form content in the drop down, but when i click on that, I get the "cm:content" fields displayed. I am not sure what are the other chnages I need to make this working so that all the custom fields mentioned in the share-custom-config.xml get sdisplayed during the form creation.

Note:
The type "vpSmiley TongueortalContent" is of type "cm:content".
2 REPLIES 2

erikwinlof
Confirmed Champ
Confirmed Champ
Hi,

I'm sorry but you are not doing anything wrong actually, this is a bug in both v3.3 & v3.4 😞
There is a jira ticket for it that I'm fixing as we speak:
http://issues.alfresco.com/jira/browse/ALF-5092

Thanks for spottong this!

erikwinlof
Confirmed Champ
Confirmed Champ
The fix for this will be in 3.3.5 & 3.4E, in which your toolbar.get.config.xml should have a <content> element like below:
<content mimetype="text/plain" icon="plain-text" label="menu.create-content.custom" formid="custom-form-id" itemid="vpSmiley TongueortalContent"/>  

Cheers again for spotting this!

:: Erik