AnsweredAssumed Answered

Cannot set properties using createDocument??

Question asked by syberyan on Jul 13, 2010
Latest reply on Jul 5, 2012 by jpotts
I am currently trying to upgrade our cmis client application from Alfresco 3.2 community to 3.3g.

But no matter what I try, createDocument won't set my custom properties. (Which worked fine in 3.2)
(createFolder does set them …)

This is what I post to a children uri:

    <entry xmlns="http://www.w3.org/2005/Atom">
        <title type="text">image1.jpg</title>
        <summary type="text">my summary</summary>
        <object xmlns="http://docs.oasis-open.org/ns/cmis/restatom/200908/">
            <properties xmlns="http://docs.oasis-open.org/ns/cmis/core/200908/">
                <propertyString propertyDefinitionId="cmis:objectTypeId">
                    <value>D:mymodel:image</value>
                </propertyString>
                <propertyString propertyDefinitionId="mymodel:prop">
                    <value>a value</value>
                </propertyString>
            </properties>
        </object>
    </entry>

The entry that is returned has no value for 'mymodel:prop' . Also the summary isn't set. This can also be reproduced with the default cmis:document type:

Posting

<entry xmlns=\"http://www.w3.org/2005/Atom\">
<summary>a summary</summary>"
<title>image6</title>"
<object xmlns="http://docs.oasis-open.org/ns/cmis/restatom/200908/">"
<properties xmlns="http://docs.oasis-open.org/ns/cmis/core/200908/">"
  <propertyString propertyDefinitionId="cmis:objectTypeId">"
    <value>cmis:document</value>"
  </propertyString>"
</properties>"
</object>"
</entry>

returns

<?xml version="1.0" encoding="UTF-8"?>
<entry xmlns="http://www.w3.org/2005/Atom" xmlns:app="http://www.w3.org/2007/app" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:alf="http://www.alfresco.org">

<summary>image6</summary>
<title>image6</title>

</entry>

Am I doing something wrong here or is this really a bug?
(would be weird that nobody has filed this before)

Outcomes