Client-Side DateTime Conversion

Stable Version 1.0.1 (OutSystems 11)
Published on 19 November 2019 by 
Stable Version 1.0.1 (OutSystems 11)
Published on 19 November 2019 by 
Created on 15 November 2019

Client-Side DateTime Conversion

Converts DateTimes and Times to the browser's local timezone using moment.js.
Read More

Contains 2 web blocks, DateTimeBlock and TimeBlock.  Use these in your Traditional Web screens and pass your DateTime or Time values to them, and they will render to the screen in the browser's local timezone.  Supports AJAX updates of DateTimes and Times as well.

In order to load the necessary supporting code, add a call to InitDateTimeConverter in your Theme's Layout's Preparation.

Important: If your server is not in UTC, adjust the Site Property "ServerTimeZone" in ClientSideDateTimeConverter to the name of the timezone your server is in (e.g. America/New_York, Europe/Lisbon, etc.)

Adjust other Site Properties to change how formatting is done, or if the time zone abbreviation will be shown after the time.  Default is in US date format with 12-hour time.

Uses moment.js and moment.js timezone

What’s new (1.0.1)

Added LocalTimeZoneBlock to show just the user's timezone

Added the ability to override the default DateTime or Time format in DateTimeBlock and TimeBlock

Reviews (0)
User interface, Date, time & calendar
Support Options
This component is not supported by OutSystems. You may use the discussion forums to leave suggestions or obtain best-effort support from the community, including from Craig St.Jean who created this component.
Client-Side DateTime Conversion has no dependencies.
Component Consumers
No consumers yet.
Weekly Downloads