SmartClient: PUT data duplication

231 views Asked by At

I am using SmartClient 8.1 and using XML data sources for GET and PUT operations.

Following is a sample of data I GET.

<data>
 <user>
  <group1>
   <value1>abc</value1>
   <value2>def</value2>
  </group1>
  <group2>
   <value3>123</value3>
   <value4>456</value4>
  </group2>
 </user>
</data>

When I update the values and submit the form, SmartClient sends the following data as PUT payload.

<dsMyDataSource>
 <value1>abc_updated</value1>
 <value2>def_updated</value2>
 <value3>123_updated</value3>
 <value4>456_updated</value4>
 <group1>
  <value1>abc</value1>
  <value2>def</value2>
 </group1>
 <group2>
  <value3>123</value3>
  <value4>456</value4>
 </group2>
</dsMyDataSource>

In the PUT payload the updated values are sent without the group elements (flattened) along with the old values in the groups. These grouped, old values are not required/desired here.

Can anybody tell why it is happening and what I should do to remove these values from the PUT payload?

Is this something to do with DynamicForm.submit() vs DynamicForm.saveData()?

I have asked this question here on the SmartClient forums, but still no answer. I hope somebody can help me here.

0

There are 0 answers