Hi, I have a problem, I can upload a file with normal metadata, but I have a subtype of metadata like this:
<xs:complexType name="blobList">
<xs:sequence>
<xs:element name="item" type="nxs:content" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
/>
<xs:element name="field1" type="xs:string"/>
<xs:element name="field2" type="xs:date"/>
<xs:element name="example1" type="nxs:exampleListType"/>
<xs:complexType name="exampleListType">
<xs:sequence>
<xs:element name="item" type="nxs:exampleListType" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="nxs:exampleListType">
<xs:sequence>
<xs:element name="field_01" type="xs:string"/>
<xs:element name="field_02" type="xs:string"/>
<xs:element name="field_03" type="xs:string"/>
<xs:element name="field_04" type="xs:string"/>
<xs:element name="field_05" type="xs:string"/>
</xs:sequence>
</xs:complexType>
and I trying to upload a file adding metadata like this:
$answer= $session->newRequest("Document.Create")
->set('input', 'doc:' . $array1['PATH'])
->set('params', 'type', 'example_doc')
->set('params', 'name', $array2['name'])
->sendRequest();
$ls_path = $answer->getDocument(0)->getPath();
$ls_UID = $answer->getDocument(0)->getUid();
$answer= $session->newRequest("Document.SetProperty")
->set('input', 'doc:' . $ls_path)
->set('params', 'value', $array2['name'])
->set('params', 'xpath', 'dc:title')
->sendRequest();
how can I do for upload a file to nuxeo with subtype and his properties?
thanks