How to re-prompt entity ?


(yogesh bhargav) #1

I want date to be entered from user which should not be a back date means it should be ahead of today’s date. If date is a back date then the same date entity should be re-prompted.


How to reprompt the same entity ?
(Yoga Ramya Mendu) #2

Hi @yogeshbhargav420,

You can validate the entity value as per your requirement using javascript once the user enters the entity value.
There is no provision to restrict the user conditionally while entering. Hence, we will validate the value only after the user-entered value is received to the entity.

1- Prompt the user with Entity node for date value.
2- Then, add a script node after the entity node.
Retrieve the entity value as context.entities.EntityNodeName and validate this value through javascript.
3- If the date entered is previous date, then return false otherwise true.
If returned value through script is true, then you can proceed with the flow, otherwise, connect to the entity node again.

image

image

image

Let us know if you need any further clarification.

Regards,
Yoga Ramya.