Added validation js callbacks

- `beforeValidateAll`
- `afterValidateAll`

fixes #4234, close #4559