Closed Bug 365320 Opened 18 years ago Closed 18 years ago

Adding a patch when filing a bug prevents filling in a requestee (e.g. for review?)

Categories

(bugzilla.mozilla.org :: General, defect, P1)

defect

Tracking

()

VERIFIED FIXED

People

(Reporter: bugzilla-mozilla, Assigned: reed)

References

Details

Attachments

(1 file)

To reproduce:
1. Go to https://bugzilla.mozilla.org/enter_bug.cgi?product=Bugzilla
2. Select a component (important!). If a component is already set, select another one.
3. Click add an attachment
4 [review]. Change review to ?
5. Try to fill in a requestee.

Step 5 fails if you've selected a (different) component.
Confirming! Probably it displays the requestee field, but then forgets to remove the "disabled" bit on it.
Need to replace lines 125-127 of template/en/default/bug/create/create.html.tmpl with:
                // Also hide the requestee field, if it exists.
                inputElement = document.getElementById("requestee_type-" + id).style;
                if (inputElement) inputElement.display = "none";
Assignee: justdave → reed
Status: NEW → ASSIGNED
(In reply to comment #2)
> Need to replace lines 125-127 of
> template/en/default/bug/create/create.html.tmpl with:
>                 // Also hide the requestee field, if it exists.
>                 inputElement = document.getElementById("requestee_type-" +
> id).style;
>                 if (inputElement) inputElement.display = "none";
> 

This looks incorrect to me. If the requestee field doesn't exist, then document.getElementById() is undefined and so you cannot consider its 'style' attribute. You probably have to write:

  inputElement = document.getElementById("requestee_type-" + id);
  if (inputElement) inputElement.style.display = "none";
You're correct... I hadn't tested it yet (was in the progress of testing).

Should be:
                // Also hide the requestee field, if it exists.
                inputElement = document.getElementById("requestee_type-" + id);
                if (inputElement) inputElement.style.display = "none";
Attached patch patch - v1Splinter Review
This should fix it.
justdave, could you fix this bug on b.m.o? That's pretty irritating as you have to go back to the attachment page to set the requestee correctly.
Priority: -- → P1
Patch applied in production.
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Doesn't work at all. Now no requestee field is displayed at all.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
OK fixed for real now.  There were some inconsistent uses of requesteeField vs requesteeField.parentNode (to get the <span> with the parens).  Straightened those out so the places that meant to get the <span> got the <span> and the places that meant to get the <input> got the <input>, and everything seems hunkydorey.
Status: REOPENED → RESOLVED
Closed: 18 years ago18 years ago
Resolution: --- → FIXED
Yup! Works fine now. Thanks!
Status: RESOLVED → VERIFIED
Component: Bugzilla: Other b.m.o Issues → General
Product: mozilla.org → bugzilla.mozilla.org
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: