Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert applyFiltersFromModel change (#1126)
Reverts changes to original behavior - too many problems. Related: #1222 #927 was originally intended to solve the issue logged in #950 where if you hide a field by default, and then want to unhide it dynamically in filterFields() it does not get saved because disabled and hidden fields are skipped by default in Form->getSaveData(); so the proposed fix was to apply model filtering logic immediately before processing the save data; however that caused issues (#1036) because the model was no longer populated the same way when calling filterFields() at that point in the request and the filterFields() method could be called multiple times. The solution to the original issue would have been to use the client side Trigger API instead; and potentially we could have solved the other issue by looking at how we're populating the model before calling filterFields() but as this functionality isn't well tested we'll just revert for now. The second change being reverted is #1099 which was an attempt to solve an issue encountered by someone that was caused by the method being called multiple times.
- Loading branch information