AnsweredAssumed Answered

utcOffset in Popup Template

Question asked by iaguilera14 on Oct 16, 2014
Latest reply on Oct 20, 2014 by iaguilera14

So I have a popup template that is referencing a date field that is not stored in UTC so by default the popup converts what it thinks is UTC to our time zone. However the date field is already stored in our local time so I need to specify the UTC offset manually. I see there is a way to do this in the API docs for popuptemplate and it is called utcOffset however it is not clear on where exactly to put it.  I have tried various places but have not been successful. Any help would be greatly appreciated.

 

var template = new PopupTemplate({
            title: "Incident",
            fieldInfos: [{
                fieldName: "alarmdate",
                label: "Alarm Date:",
                visible: true
            }, {
                fieldName: "incidentnumber",
                label: "Inc. #:",
                visible: true
            }, {
                fieldName: "CallCode",
                label: "Call Code:",
                visible: true
            }, {
                fieldName: "compositeaddress",
                label: "Address:",
                visible: true
            },{
                fieldName: "Units",
                label: "Unit(s):",
                visible: true
            }],
            showAttachments: true
        });

The alarmdate field is the one I am trying to add the utcOffset to I would need it to be something like +7.

 

Thanks,

Outcomes