On 5 Apr 2008, at 18:19, Florent Guillaume wrote:
On 1 Apr 2008, at 09:02, [EMAIL PROTECTED] wrote:
I am not able to input a custom property of a custom document type in the 'Modify' tab.
In my schema I have an element like this :

<xs:complexType name="stringList">
  <xs:sequence>
    <xs:element name="stringItem" type="xs:string" default=""/>
  </xs:sequence>
</xs:complexType>

<xs:element name="keywords" type="nxs:stringList" />

Note that this complex syntax can be simplified starting with Nuxeo 5.1.3. Remove all of the above and just write:

 <xs:simpleType name="keywords">
   <xs:list itemType="xs:string" />
 </xs:simpleType>

This is standard XMLSchema syntax.

Hmm sorry, I'm tired. That should be:

  <xs:simpleType name="stringList">
    <xs:list itemType="xs:string" />
  </xs:simpleType>

  <xs:element name="keywords" type="nxs:stringList"/>

Note that in this case, when you get a property of this (simple) type, you'll get a String[], instead of List<String> which corresponds to a complex type.
See the unit tests in the nuxeo project sample.

Florent

--
Florent Guillaume, Director of R&D, Nuxeo
Open Source Enterprise Content Management (ECM)
http://www.nuxeo.com   http://www.nuxeo.org   +33 1 40 33 79 87



_______________________________________________
ECM mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm

Reply via email to