cancel
Showing results for 
Search instead for 
Did you mean: 

Person as a property

rwilson1982
Champ in-the-making
Champ in-the-making
Hello,

I am creating a custom aspect for my data model for approvable documents. I want to add a property to the aspect called "Primary Contact" which would be a user in system. The reason for this is I want to send notification emails but its not always going to be to the create or owner of the document. I do not wish to give the user a plain text field to type in to and would much rather they were able to select an existing user from perhaps an "address book" widget. Does such a thing exist? I have seen a similar widget in the "Send email" action which allows for the selection of a user or group but i'm not sure how to use this as a property?

At the moment my aspect looks like this:


<aspect name="cc:approvabledoc">
    <title>Approvable Document</title>
    <properties>
        <property name="cc:primarycontact">
            <type>d:text</type>
            <mandatory>true</mandatory>
        </property>
        <property name="cc:approveddate">
            <type>d:date</type>
        </property>
        <property name="cc:reviewdate">
            <type>d:date</type>
        </property>
    </properties>
</aspect>
1 REPLY 1

scapeler
Champ in-the-making
Champ in-the-making
Add an association to your aspect like:


            <association name="cc:approvabledocAssignee">
               <title>Assignee</title>
               <source>
                  <mandatory>false</mandatory>
                  <many>true</many>
               </source>
               <target>
                  <class>cm:person</class>
                  <mandatory>false</mandatory>
                  <many>false</many>
               </target>
            </association>