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

UserForm hooks unable to be called #350

Closed
frankmullenger opened this issue Sep 22, 2015 · 3 comments
Closed

UserForm hooks unable to be called #350

frankmullenger opened this issue Sep 22, 2015 · 3 comments
Assignees

Comments

@frankmullenger
Copy link
Contributor

There are calls to getFormFields(), getFormActions() and getRequiredFields() in the UserForm constructor:
https://github.com/silverstripe/silverstripe-userforms/blob/master/code/forms/UserForm.php#L17

These methods include updateFormFields, updateFormActions and updateRequiredFields hooks, however at the time they are called Object constructor hasn't had a chance to set up extension_instances.

Using version 3.0.2.

@brandoniffert
Copy link

@frankmullenger Running into this same problem right now on 3.1.0. Any idea on how to fix it?

@frankmullenger
Copy link
Contributor Author

@brandoniffert: @tractorcow has kindly offered to fix this, shouldn't be too far off :-)

@tractorcow
Copy link
Contributor

I'm just writing tests for this. :)

tractorcow pushed a commit to tractorcow/silverstripe-userforms that referenced this issue Dec 11, 2015
Fixes silverstripe#350 and fixes silverstripe#404
This change abandons validation via EditableFormField::validateField, as it bypassed too many core validation mechanisms (RequiredFields, etc).
In order to enforce consistency of editable field validation, display rules have been hard-disabled when a field is marked as required.
Since this removes functionality, I have incremented the major version number
@tractorcow tractorcow self-assigned this Dec 11, 2015
tractorcow pushed a commit to tractorcow/silverstripe-userforms that referenced this issue Mar 1, 2016
Fixes silverstripe#350 and fixes silverstripe#404
This change abandons validation via EditableFormField::validateField, as it bypassed too many core validation mechanisms (RequiredFields, etc).
In order to enforce consistency of editable field validation, display rules have been hard-disabled when a field is marked as required.
Since this removes functionality, I have incremented the major version number
tractorcow pushed a commit to tractorcow/silverstripe-userforms that referenced this issue Apr 18, 2016
Fixes silverstripe#350 and fixes silverstripe#404
This change abandons validation via EditableFormField::validateField, as it bypassed too many core validation mechanisms (RequiredFields, etc).
In order to enforce consistency of editable field validation, display rules have been hard-disabled when a field is marked as required.
Since this removes functionality, I have incremented the major version number
micmania1 pushed a commit to torque-foxes/silverstripe-userforms that referenced this issue May 25, 2016
Fixes silverstripe#350 and fixes silverstripe#404
This change abandons validation via EditableFormField::validateField, as it bypassed too many core validation mechanisms (RequiredFields, etc).
In order to enforce consistency of editable field validation, display rules have been hard-disabled when a field is marked as required.
Since this removes functionality, I have incremented the major version number
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants