date comparison in data-sly-test?

jakej40603950 19-11-2018

Can two touchUI date fields (granite/ui/components/foundation/form/datepicker) be compared in HTML using data-sly-test? Also is there a way to get current date in HTL?

Thanks.

Mark Solution

Are these answers useful?
Help other community members by marking useful answers as accepted.

Accepted Solutions (0)

Answers (1)

Answers (1)

Arun_Patidar
MVP
19-11-2018

Hi,

You can try below but you can't get the current date in HTL. You need to use JAVA or JS Use API.

<div data-sly-test="${properties.date1 == properties.date2}">TEST</div>