Skip to content

Missing constraint type support for 'digit' #90

@robertfausk

Description

@robertfausk

Javascript-Error in Chrome console:

    Uncaught The wrong "digit" type was passed to the Type constraint

SymfonyComponentValidatorConstraintsType.validate   @   fp_js_validator.js?version=v2:1847
validateConstraints @   fp_js_validator.js?version=v2:507
validateElement @   fp_js_validator.js?version=v2:460
FpJsFormElement.validate    @   fp_js_validator.js?version=v2:29
FpJsFormElement.validateRecursively @   fp_js_validator.js?version=v2:48
FpJsFormElement.validateRecursively @   fp_js_validator.js?version=v2:50
(anonymous function)    @   fp_js_validator.js?version=v2:267
each    @   fp_js_validator.js?version=v2:836
FpJsCustomizeMethods.submitForm @   fp_js_validator.js?version=v2:262
customize   @   fp_js_validator.js?version=v2:815
(anonymous function)    @   fp_js_validator.js?version=v2:687
#validation.yml
...
            - Type:
                type: digit
                message: "In diesem Feld sind nur numerische Zeichen zugelassen."


I think it' because there is no constraint type defined for 'digit' in
https://github.com/formapro/JsFormValidatorBundle/blob/656484231056ea9f7f312ceedbff37e6fee0452e/Resources/public/js/constraints/Type.js#L72

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions