Feature(s) impacted
While submitting smart action form in FA, if there is validation error message is displayed due to custom validation. Clicking on error message triggers browser alert saying, ‘Form Values will be lost, are you willing to continue.’
Observed behavior
Clicking on error message triggers browser alert saying, ‘Form Values will be lost, are you willing to continue.’
Expected behavior
Clicking on error message should not perform any activity.
Context
- Package Version: 8.3 (forest-express-sequelize)
- Express Version: 4.17.1
- Sequelize Version: 6.6.5
- Database Dialect: MySql
- Database Version: 5.7.24
Please provide in this mandatory section, the relevant information about your configuration:
- Project name: Curator
- Team name: Developer
- Environment name: All
Hello @Nilesh_Shirsat,
Thank you for reporting this.
Would you mind sharing with us the definition and code of your SmartAction, the validation code which triggers the error, and maybe an example of input values you use in the form?
This will help to reproduce the issue and to be sure we understand it.
Thank you
Hello @anon79585656,
Here is the snippet of code for validation on smart action.
One of the field in smart action expects color value in hex format. And if user input invalid hex color value, validation error will be thrown while submitting form.
If user click on validation error message then browser alert is thrown.
Hope this information is enough to reproduce this issue. Let me know if you need anything else.
Thank you @Nilesh_Shirsat,
I would help to see how this validation code is called. Is it in you model definition? Manually when checking values?
Again, seeing you SmartAction code would help.
The error message is a custom one, do you send it yourself in the SmartAction code?
You could also share the headers and response for the SmartAction call that you can find in the network tab of your browser’s developper tools.