← Back to team overview

dhis2-devs-core team mailing list archive

Re: LastUpdated field and dashboard item modifications.

 

Great, thats correct.

Lars
On Jun 15, 2015 12:46 PM, "Araz Abishov" <araz.abishov.gsoc@xxxxxxxxx>
wrote:

> Hello Lars,
>
> Many thanks for explanation.
>
> Initially I thought that lastUpdated field in dashboardItems should change
> after modifications in them.
> Now I understood that dashboardItems are just "glue" for grouping elements
> in dashboards, and changes applied to them in fact are changes in dashboard
> itself.
>
> One more time, thanks :)
>
> Best Regards,
> Araz
>
> On Sun, Jun 14, 2015 at 2:45 PM, Lars Helge Øverland <larshelge@xxxxxxxxx>
> wrote:
>
>> Hi Araz,
>>
>> you should not add reports etc to existing dashboard items. You should
>> either add new or remove existing dashboard items (no updates).
>>
>> Have a look at the docs here:
>>
>> https://www.dhis2.org/doc/snapshot/en/developer/html/ch01s23.html#d5e3470
>>
>> A POST request URL for adding a chart to a specific dashboard could look
>> like this, where the last id query parameter value is the chart resource
>> identifier:
>>
>> /api/dashboards/vQFhmLJU5sK/items/content?type=chart&id=LW0O27b7TdD
>>
>> or inspect the requests while using the web-based dashboard:
>>
>> https://apps.dhis2.org/demo/dhis-web-dashboard-integration/index.action
>>
>> To add new dashboard items you can POST to
>> /dashboards/<uid>/items/content. Through that resource, the last updated
>> property of the dashboard itself will be updated.
>>
>> best regards,
>>
>> Lars
>>
>>
>>
>>
>> On Sat, Jun 13, 2015 at 10:14 AM, Araz Abishov <
>> araz.abishov.gsoc@xxxxxxxxx> wrote:
>>
>>> Hello team,
>>>
>>> The problem I have noticed is related to the way how dashboard items
>>> react to changes. For example if I add/remove a report/user/document
>>> to/from existing dashboard item (like this one
>>> https://apps.dhis2.org/demo/api/dashboardItems/vG7Prz2vAhn), the
>>> lastUpdated field won't change.
>>>
>>> When REST client will be pooling updates for dashboard items from API,
>>> it won't be able to determine that something has changed.
>>>
>>> Could you please fix this in 2.20 and backport changes to 2.19?
>>>
>>> Best Regards,
>>> Araz
>>>
>>> --
>>> Mailing list: https://launchpad.net/~dhis2-devs-core
>>> Post to     : dhis2-devs-core@xxxxxxxxxxxxxxxxxxx
>>> Unsubscribe : https://launchpad.net/~dhis2-devs-core
>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
>>
>> --
>> Lars Helge Øverland
>> Lead developer, DHIS 2
>> University of Oslo
>> Skype: larshelgeoverland
>> http://www.dhis2.org <https://www.dhis2.org>
>>
>>
>

References