Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validation tutorial - incorrect usage of setValidator/validatorFactory #5515

Closed
phillipspc opened this issue Jul 1, 2016 · 0 comments
Closed
Assignees

Comments

@phillipspc
Copy link

In the tutorial, both in the written explanation and the accompanying example, the setValidator method returns a function which takes a series of arguments in the following order: function(newValue, oldValue, rowEntity, colDef).

However, from my experience using this method, this is incorrect, and should instead be: function(oldValue, newValue, rowEntity, colDef). This would appear to be consistent with how the validatorFactory is used in the source as well: https://github.com/angular-ui/ui-grid/blob/93c9d0b/src/features/validate/js/gridValidate.js#L380

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants