By JawnDoh - Mon Nov 09, 2020 1:19 am
- Mon Nov 09, 2020 1:19 am
#828642
Hi all
I'm fairly new to ProcessMaker. I'm sure I'll consult this forum frequently and hopefully I can contribute as well.
On to my issue....
In addition to a dynaform field's validate and validation error message properties, I would like to also programmatically set a field to invalid and invoke the PM invalid-field formatting, based on various logic.
Using the following chunk of Javascript, I am able to set a field to invalid (and set the message); HOWEVER, it only invokes the browser's default invalid-field indicator/formatting:
... shows:
How can I show the ProcessMaker default field formatting like below?
Thanks!
I'm fairly new to ProcessMaker. I'm sure I'll consult this forum frequently and hopefully I can contribute as well.
On to my issue....
In addition to a dynaform field's validate and validation error message properties, I would like to also programmatically set a field to invalid and invoke the PM invalid-field formatting, based on various logic.
Using the following chunk of Javascript, I am able to set a field to invalid (and set the message); HOWEVER, it only invokes the browser's default invalid-field indicator/formatting:
Code: Select all
var element = document.getElementById("form[dob]");
element.setCustomValidity("Test error");
element.reportValidity();
... shows:
How can I show the ProcessMaker default field formatting like below?
Thanks!