Needs work
Project:
References
Version:
7.x-2.x-dev
Component:
Code: user_reference
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
24 Jan 2011 at 13:12 UTC
Updated:
21 Apr 2014 at 14:04 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
andypostConfirm this. as I remember there was 2-3 issues with '0' values of radios checkboxes but all been fixed in core...
suppose issue related to current implementation...
Comment #2
fgmReplaced the use of 0 and 1 by string values to avoid falling in this type of bug.
Comment #3
fgmAs possibly faster solution was suggested by dereine, using a '-0' option instead of '0' and fixing up the value in submit. Then there is no need for the conversion loop in the suggested patch.
And, of course, we need a test to validate the changes.
Comment #4
yched commentedAgreed, I'd favor a workaround strictly contained within FAPI processing, without changing the semantics of the stored values.
Also (minor) : if both checkboxes are checked, no need to add anything to the query.
Comment #5
rt_davies commentedsubscribe
Comment #6
bocaj commentedChanging line 91 in user_reference.module from:
to:
worked for me. Not sure that it's the best way to handle it, but now it functions like I expected!
Comment #7
dtarc commentedThe suggestion in #6 worked for me, here's a patch.
Comment #8
andypostI think using '-0' should have
(int)inComment #9
alanburke commentedI don't think this matters anymore - I don't seem to have the issue in any case
Comment #10
presleyd commentedProblem still exists in 2.1 perhaps it was fixed in dev? Patch in 7 still works in 2.1 though.
Comment #11
MantasK commentedas it is not fixed, one more patch :)
Comment #13
fullerja commentedPatch in #7 worked well for me