Open Closed

Need to add validation messages for Add Tenant #4422


User avatar
0
dev3.advantiss created

Need to add validation messages for Add Tenant form
as on Add User form
If click Save on empty user form I will get error messages

add_user_form.png

but on empty Add Tenant form button Save disables, and users can not get information for incorrect fields

add_tenant_form.png

I removed code for disabling button, but I could not get any messages from field validations
I used Volo.Identity.Pro
How I can do this in best way?

  • ABP Framework version: v5.3.3

  • UI type: Angular

  • DB provider: MongoDB

  • Tiered (MVC) or Identity Server Separated (Angular): yes

Thank you.
Best regards Advantiss.


1 Answer(s)
  • User Avatar
    0
    mahmut.gundogdu created

    That validation message was shown when the form was submitted. As an example, when you focused the input, you might press enter.

    image.png

    That changed in the newer version of ABP. My suggestion is that you should update your ABP version.
    You should change the button type to "submit."
    Add a value form's id attribute. Set this id to the submit button's form attribute. Then your save code should be in (ngSubmit)="save()"

    https://stackoverflow.com/a/12567605/3928982

Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
Do you need assistance from an ABP expert?
Schedule a Meeting
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v9.2.0-preview. Updated on March 18, 2025, 10:42