Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Should Request include not updated fields in <data> tag?

    Hi

    My environment:
    1. SmartClient Version: SNAPSHOT_v8.3d_2012-06-12/LGPL Development Only (built 2012-06-12)
    2. browser IE8

    When I update one field in ListGrid and save record, my request <data> tag contains key and updated field only:

    Code:
    <request>
      <data>
        <idActivity>3</idActivity>
        <activityFinish>2012-06-21T06:09:00</activityFinish>
      </data>
      <oldValues>
        <updateTime>2012-06-29T13:03:22</updateTime>
        <updateIdUser>9</updateIdUser>
        <idActivity>3</idActivity>
        <idObject>33</idObject>
        <comment>my comment here</comment>
        <activityStart>2012-06-20T22:09:02</activityStart>
        <activityFinish>2012-06-20T22:09:02</activityFinish>
        <idActivityStatus>0</idActivityStatus>
      </oldValues>
      <dataSource>isc_ActivityDS_0</dataSource>
      <operationType>update</operationType>
      <componentId>isc_ActivityForm_0</componentId>
    </request>
    When I put record to DynamicForm

    Code:
    editForm.editSelectedData(grid);
    and update the same field, <data> tag includes full set of fields whether they were updated or not:

    Code:
    <request>
      <data>
        <updateTime>2012-06-29T13:03:22</updateTime>
        <updateIdUser>9</updateIdUser>
        <idActivity>3</idActivity>
        <idObject>33</idObject>
        <comment>my comment here</comment>
        <activityStart>2012-06-20T22:09:02</activityStart>
        <activityFinish>2012-06-21T06:09:00</activityFinish>
        <idActivityStatus>0</idActivityStatus>
      </data>
      <oldValues>
        <updateTime>2012-06-29T13:03:22</updateTime>
        <updateIdUser>9</updateIdUser>
        <idActivity>3</idActivity>
        <idObject>33</idObject>
        <comment>my comment here</comment>
        <activityStart>2012-06-20T22:09:02</activityStart>
        <activityFinish>2012-06-20T22:09:02</activityFinish>
        <idActivityStatus>0</idActivityStatus>
      </oldValues>
      <dataSource>isc_ActivityDS_0</dataSource>
      <operationType>update</operationType>
      <componentId>isc_ActivityForm_0</componentId>
    </request>
    In both cases I use the same datasource inherited from RestDataSource.

    Why the number of fields in <data> tag is different?
    Is there some option which could allow me to apply the same <data> format for whole application?

    Thanks in advance
    Last edited by Oleg; 1 Jul 2012, 11:19.
Working...
X