Skip to main content
Mar 9, 2022 3:52 PM UTC
Solved

DateTime Property in ThingTemplate

We was using 10 datetime remote properties in Thing from Thingtemplate in all services. Hereafter those properties wont receive data from device. So we planned to pass new Date() time in all services. Is there any option to set current time in all those properties directly instead of editing all services. ??

PaiChungAnswer
Mar 9, 2022 6:49 PM UTC

You can set them in composer or write a service to fill them in? You can edit the ThingTemplate as well and provide a default value for each of those properties.

2 replies

PaiChungAnswer
Mar 9, 2022 6:49 PM UTC

You can set them in composer or write a service to fill them in? You can edit the ThingTemplate as well and provide a default value for each of those properties.

Mar 11, 2022 5:27 AM UTC

Every time when the services invoking those properties, it should fetch the current time. If iam editing the ThingTemplate to provide a default value for each of those properties, the default value which saved only will pass to services everytime. That value becomes a past value in one minute right.