<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Custom content type with LIST constraint in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/custom-content-type-with-list-constraint/m-p/262129#M215259</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;As a practice, I am trying to extend the custom content model in "Working with Custom Content Types", 2nd edition by Jeff Potts, which BTW is a must read. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Basically, I created an aspect sc:reviewable with a multi-value property sc:reviewer. I also created a LIST constraint sc:reviewerList - the list of allowed values are hard-coded in scModel.xml for now. The LIST constraint sc:reviewerList was applied to sc:reviewer property. The configuration was loaded to Alfresco and tomcat was restarted. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In SomeCoCMISDataCreator.java, I tried to create a document as below&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;…&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;properties.put(PropertyIds.OBJECT_TYPE_ID, "D:sc:whitepaper,P:sc:reviewable");&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;…&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;properties.put("sc:reviewer", Arrays.asList("John Smith", "Jane Doe"));&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;…&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Somehow, the code threw an error "Constraint violation… the value is not an allowed value: John Smith". To verify the definition, I browsed to &lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://localhost:8080/alfresco/s/cmis/type/P:sc:reviewable" rel="nofollow noopener noreferrer"&gt;http://localhost:8080/alfresco/s/cmis/type/P:sc:reviewable&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;and found "John Smith" was indeed listed as one of the cmis:choiceString/cmis:value. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Why would the code complain then? What am I missing? Thanks.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 10 Feb 2012 21:44:51 GMT</pubDate>
    <dc:creator>zliu</dc:creator>
    <dc:date>2012-02-10T21:44:51Z</dc:date>
    <item>
      <title>Custom content type with LIST constraint</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/custom-content-type-with-list-constraint/m-p/262129#M215259</link>
      <description>As a practice, I am trying to extend the custom content model in "Working with Custom Content Types", 2nd edition by Jeff Potts, which BTW is a must read. Basically, I created an aspect sc:reviewable with a multi-value property sc:reviewer. I also created a LIST constraint sc:reviewerList - the list</description>
      <pubDate>Fri, 10 Feb 2012 21:44:51 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/custom-content-type-with-list-constraint/m-p/262129#M215259</guid>
      <dc:creator>zliu</dc:creator>
      <dc:date>2012-02-10T21:44:51Z</dc:date>
    </item>
    <item>
      <title>Re: Custom content type with LIST constraint</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/custom-content-type-with-list-constraint/m-p/262130#M215260</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;When you are saying you have created the custom constrains. you have created the list of allowable values for one property.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Here you are mixing the concept of multivalue property and property constrain.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;What I thought is that It is expecting only one of the value from the list directly to set as the value of that property.not the list.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Feb 2012 12:14:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/custom-content-type-with-list-constraint/m-p/262130#M215260</guid>
      <dc:creator>mitpatoliya</dc:creator>
      <dc:date>2012-02-14T12:14:47Z</dc:date>
    </item>
  </channel>
</rss>

