AnsweredAssumed Answered

User details selected from authority.ftl not saving

Question asked by radder5 on Oct 25, 2013
Latest reply on Apr 24, 2014 by radder5
Hi,
I'm very new to Alfresco development. Recently done some tutorials on Alfresco customisation (JPotts) and bought the Alfresco Dev Book. My issue though doesn't appear to be covered in there.

I want to add a property to my custom model who is a user of Alfresco. The end game is to assign a simple workflow to them in script.
So, the user name added has to be constrained to a user in the system.
I have tried modeling it like
<blockcode>
<property name="kpcc:passedTo">
   <type>d:text</type>
   <mandatory>true</mandatory>
   <constraints>
      <constraint ref="cm:userNameConstraint" />
   </constraints>
</property>
</blockcode>
then in my share custom file, I have used the authority.ftl form component.

The edit form shows fine, and I can use the user picker to select a user. This also is shown in the edit form when the picker closes. However, when the form is saved, the value isn't retained.

Is there a better way to model this? I was thinking cm:person but don't really know how to go with that.

Thanks
Conrad

Outcomes