Date support functions for consistent date handling in Liquid script & fetch Create 2 variables: 1. var_today for Liquid scripts 2. var_today_fetch for fetch (data) operations Limitations using var_today: a. Now function returns UTC with date AND time. b. Now function is not always accurate as the value is cached (??). Now = 5/16/2022 7:09:33 PM 1. var_today is an integer used to compare current date to CRM dates (without the time component) in Liquid script var_todayAEST = 5/17/2022 6:09:33 AM var_today = 20220516 Example test run on 13/10/21 10 AM (in AEST) Liquid now returns 12/10/21 11 PM CRM sample record has display date=13/10/21; when retrieved in Liquid (in UTC) it returns 12/10/21 1 PM In Liquid script: Convert CRM date using '| date: "yyyyMMdd" | integer' returns '20211012' To compare to current date as integer var_today needs to have value '20211012' (prior day taking into account time-zone differences) 2. var_today_fetch is date in format yyyy-MM-dd used for fetch XML run directly on database Fetch resolves date's time component var_today_fetch = 2022-05-17 Example test run on 13/10/21 10 AM (in AEST) CRM sample record has display date=13/10/21; when retrieved in Liquid (in UTC) it returns 12/10/21 1 PM In Fetch to test current date need to set 'value="2021-10-13"'

Welcome to ADC Connect

 

ADC Connect is the online portal for the Australian Dental Council. Through ADC Connect you can interact with us anywhere, anytime, and on any device.

Are you a new candidate?

New candidates starting their dental practitioner assessment process will need to create an ADC Connect account. You can do this by selecting the create an account link below.

Site login