Page 2 of 2

Re: [INFO REQ] TextField with error

Posted: Tue Nov 01, 2022 1:23 pm
by henrique

I understand your suggestion, but um my case, the user is filling the field with an invalid value, that's my server return an error. So, the user changes the value to the correct value, but this value isn't updating the class model, filled in the container, so this new value doesn't go to the server, and the return of validation, continues been invalid, because the old value was sent.

If I must fill the value in my source, will be a problem, because is a lot of text fields, combo, and a lot more. So, the issue open is especially important for my company to be executed.


Re: [INFO REQ] TextField with error

Posted: Wed Nov 02, 2022 9:39 am
by alex.l

You could try yo move some logic into base class that you'll be using for all fields in your application.
I am not sure how can I help you here. The logic is clear: it won't update record with invalid values. If you manually set error, you need to manually clear it.
If you'll provide a test case, we might try to help you with the code sample.


Re: [INFO REQ] TextField with error

Posted: Thu Nov 03, 2022 12:49 pm
by henrique

Yes, I manually set error.

But my request is simple, can be with a configuration, to clear all manually filled error, when the user change de field. Selecting a new value in the combo or typing a new value in a text field.

Of course, I can use the override, to change this behaver, but I guess isn't the best option.


Re: [INFO REQ] TextField with error

Posted: Thu Nov 03, 2022 9:25 pm
by alex.l

We already opened a ticket to improve validation by your request https://github.com/bryntum/support/issues/5178
For now, I cannot give you more overrides except those I already provided here.
It won't be required in override or custom code, when the ticket will be fixed.