Closed Bug 577054 Opened 11 years ago Closed 11 years ago
Cannot delete any field value if that value's field controls any values
Situation: Field A is a value controller. Field A has Value 1 that doesn't control any values. You try to delete Value 1, and Bugzilla will throw an error that you can't delete it, because it controls (empty list of values).
This proves that either people don't use value controllers much, or that they don't delete field values very often. (More likely the latter.) The reason I say this is that this bug has been around for pretty much as long as we've had value controllers, and nobody's reported it.
Okay, this applies to HEAD at least. I'm not sure if it will also apply to 3.6--I forget when I split things out into ChoiceInterface.
Assignee: administration → mkanat
Status: NEW → ASSIGNED
Attachment #456138 - Flags: review?(bugzilla)
Attachment #456138 - Flags: review?(bugzilla) → review?(LpSolit)
Comment on attachment 456138 [details] [diff] [review] v1 r=LpSolit
Attachment #456138 - Flags: review?(LpSolit) → review+
Bugzilla/Field/ChoiceInterface.pm doesn't exist in 3.6.1.
Okay, I haven't tested this (I have to go to sleep right now, and setting up a testing environment was taking too long) but it compiles and it's basically just a straightforward backport. All I did was copy identical code into the right place.
Attachment #459398 - Flags: review?(LpSolit)
Comment on attachment 459398 [details] [diff] [review] v1 (3.6) Works fine. r=LpSolit
Attachment #459398 - Flags: review?(LpSolit) → review+
Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/trunk/ modified Bugzilla/Field/ChoiceInterface.pm modified template/en/default/admin/fieldvalues/confirm-delete.html.tmpl Committed revision 7396. Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/4.0/ modified Bugzilla/Field/ChoiceInterface.pm modified template/en/default/admin/fieldvalues/confirm-delete.html.tmpl Committed revision 7340. Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/3.6/ modified Bugzilla/Field/Choice.pm modified template/en/default/admin/fieldvalues/confirm-delete.html.tmpl Committed revision 7143.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.