Validation does not start, or starts too often (email, phone, address)

Support DQE
Support DQE
  • Updated

Symptom: a validation does not start, starts too often, or a field is not revalidated after an error. You want to know when each call is sent.

Affected versions: 1.0.0.

Address: two separate calls

CallTriggerDelayDQE service
SuggestionsThe customer types in the address line (at least 2 characters)600 ms after the last keystrokeSINGLEV
ValidationForm submission, if validation is still required for the addressImmediateRNVP

Validation is required again each time the customer edits an address field, and is no longer required once a suggestion is selected, depending on the validation mode.

Validation modes

The mode is set by the Business Manager site preference dqeAddressValidationMode. If the preference is absent, the default value is validate_on_manual_change.

ModeBehaviour
validate_alwaysValidation on every submission.
validate_on_manual_inputValidation only if no suggestion has been selected.
validate_on_manual_changeAfter a suggestion is selected, no validation until the customer changes a field again.

If a customer does not see validation on submit, first check the configured mode and whether a suggestion was selected.

Email and phone

EventBehaviour
The customer leaves the field after changing itImmediate call, if the value is not empty.
The customer typesCall 2 seconds after the last keystroke, only if the field has already been changed once on the page.

A call is not sent:

  • if the value is identical to the last validated value;
  • if a previous call is still in progress;
  • if the value is empty;
  • on the first pass, if the value does not match the expected format of the field.

The phone field ignores spaces when comparing values. If DQE returns a formatted number, that number becomes the reference value.

Form blocking

  • An invalid response disables the submit button and displays a message.
  • A warn or valid response does not block the form.
  • An error response does not block the form on the client side (see the article on the cartridge behaviour when the DQE API does not respond).

Good to know

  • The last value sent is remembered even when DQE returned an error: the same email or phone number is not revalidated until the value changes.
  • If validation of a field no longer reacts after a network problem, reload the page. If the issue persists, contact DQE support.

Verification

  1. Open the browser developer tools, Network tab, and filter on DQE-.
  2. Change an email field, then leave the field: a DQE-ValidateEmail call should be sent.
  3. Type without leaving the field: no call is sent before the field has been left for the first time.

Related to

Was this article helpful?

0 out of 0 found this helpful