Import XML

Mergeable Properties and Child Nodes

How to declare properties or child nodes as „mergeable“ for further handling in the Sophora DeskClient.

Properties or child nodes that are marked as mergeable will not be imported by the importer. Instead they will be written into a merge info field of the imported document. This field will be used by the DeskClient to propose those properties and child nodes to be merged manually.

To mark properties or child nodes to be mergeable you can use the attribute merge.

<?xml version="1.0" encoding="UTF-8"?>
<documents xmlns="http://ww.sophoracms.com/import/4.2">
  <document externalID="$externalId1$">
    <properties>
      <property name="sophora-content:headline" merge="true">
        <value>The new headline</value>
      </property>
    </properties>
    <childNodes>
      <childNode nodeType="sophora-extension-nt:copytext" name="sophora-content:copytext" merge="true">
        </properties>
        <childNodes>
          <childNode nodeType="sophora-extension-nt:paragraph" name="sophora-extension:paragraph">
            <properties>
              <property name="sophora-extension:style">
                <value>headline</value>
              </property>
              <property name="sophora-extension:text">
                <value>...</value>
              </property>
            </properties>
            <childNodes />
            <resourceList />
          </childNode>
        </childNodes>
        <resourceList />
      </childNode>
      <childNode nodeType="sophora-content-nt:storyref" name="sophora-content:teaser" merge="true">
        <properties>
          <property name="sophora:reference">
            <value>eeeed196-343f-4c8a-bbe1-632bb0ef5fa9</value>
          </property>
        </properties>
        <childNodes />
        <resourceList />
      </childNode>
      <childNode nodeType="sophora-content-nt:storyref" name="sophora-content:teaser" merge="true">
        <properties>
          <property name="sophora:reference">
            <value>3ea5af02-b6e3-4609-84f0-1e2b67a357f1</value>
          </property>
        </properties>
        <childNodes />
        <resourceList />
      </childNode>
    </childNodes>
    <resourceList />
    <fields>
      [...]
    </fields>
    <instructions>
      [...]
    </instructions>
  </document>
</documents>

Last modified on 10/16/20

The content of this page is licensed under the CC BY 4.0 License. Code samples are licensed under the MIT License.

Icon