SC.FieldView does not update fieldValue correctly when used with certain Validators #624

Open
hungle opened this Issue Nov 9, 2011 · 0 comments

Projects

None yet

2 participants

@hungle
Contributor
hungle commented Nov 9, 2011

When the value of the input field is changed, the 'setFieldValue' function is never called if the validator's 'objectForFieldValue' returns a value that is the same as the current value set on the view. This could happen, for example, in a scenario where the validator performs transformation that involves stripping a string to convert to a number. So let's say the input field's value is 'a123', the call to 'objectForFieldValue' would return '123' and the value on SC.FieldView would be set, and thus updating the 'fieldValue'. But if the user then changes the input field's value to 'a123b', the call to 'objectForFieldValue' would still return '123' but the value on SC.FieldView would not be set this time around and the 'fieldValue' would never get updated.

@publickeating publickeating modified the milestone: 1.12.0, 1.11.0 Apr 30, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment