UI Policy when using condition on date field with is less/more than 'quarter' fields throws 'onChange script error: TypeError: theDate.getMonth is not a function function () { [native code] }'


Description

When creating a UI Policy with Condition using date fields with 'is less/more than' combine with interval condition 'Quarters' throws some errors javascript error which displays on the field:

'onChange script error: TypeError: theDate.getMonth is not a function function () { [native code] }' (see screenshot for details)

Note that the issue only happens when using interval condition for 'Quarters' in the condition field.

Steps to Reproduce

1. Login to instance (orlando, paris)
2. Navigate to list table ast_contract.list.
3. Create a new UI policy entry for ast_contract table
4. Under the When To Apply tab, create the following Condition (see screenshot attached):
End date --> is less than --> 5 --> Quarter --> before --> Start Date
5. Submit/Save the UI policy
6. Create a new record for ast_contract
7. Enter value Start Date
8. Enter valeu for End Date

Actual behaviour: Error message is thrown and display under the field 'onChange script error: TypeError: theDate.getMonth is not a function function () { [native code] }' (see screenshot for details)

Expected behaviour: No error message should be displayed.

Workaround

This problem has been fixed. If you are able to upgrade, review the Fixed In or Intended Fix Version fields to determine whether any versions have a planned or permanent fix.


Related Problem: PRB1481268