Hello, I have a product table list with an input per row, and upon Input Onchange I want to do some validation and highlight the input if it is invalid. However I can't find the Input Id (for the Valid and ValidationMessage attributes) on the assign node when I'm trying to do so, not sure why. I only noticed this when the input is inside a table, but I can see the id if it is in a form. Any idea how to do this?
Attached is the oml
You need to pass through input parameter to the validation action.
I marked this reply also as solution, the solution marked by the original poster as solution does mention that MƔrcio's solution is the good solution.
Hi @ars art -You can pass the widgetId as mentioned by Marcio in the above comments. In addition to that, using javascript you can validate the textbox (i.e. highlight particular text box) if it exceeds the quantity value. Also, if you add lesser order quantity the bordor will be removed. I am attaching the OML for your reference.
Also, please go through the test URL - https://tejas-mendse.outsystemscloud.com/ProductSample/Products?_ts=637962666237052475
@ars art
You can build your custom validation using boolean var and CSS. I have created functionality in your oml.
please find below
Thanks
Shriyash
Hi @Shriyash Dixit -Your solution will not work correctly. It will highlight bordor red for all the text box in the list even if it is less than the quantity. Please see below image. You can try to reproduce it.
Hi @Tejas Mendse As you have mentioned in my solution "It will highlight border red for all the text boxes in the list even if it is less than the quantity. "
I cross-checked it, I only removed text validation functionality it is working, it is not highlighting all the boxes. we can see In your attached screenshot also, you can try once - remove text from UI screen