Bug 1037909

Summary: Components list should dynamically update when changing the product on the "show_bug.cgi" page
Product: [Community] Bugzilla Reporter: Jason McDonald <jmcdonal>
Component: Creating/Changing BugsAssignee: Matt Tyson 🤬 <mtyson>
Status: CLOSED CURRENTRELEASE QA Contact: Simon Green <sgreen>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.4CC: ebaak, jmcdonal, rjoost
Target Milestone: 4.4   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 4.4.2014 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-03-03 01:00:40 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Jason McDonald 2013-12-04 03:31:23 UTC
Description of problem:
When a user changes the Product of a bug, they don't get to select a new Component right away, but rather have to click "Save Changes" and select the new Component on the next page.

This seems to confuse some users and results in occasional bug reports, tickets and emails from users who think it's impossible to change the Component when changing the Product.

This confusion could be avoided if changing the Product caused Bugzilla to display a hint next to the component field stating that a component (and a sub-component, if applicable) can be selected after clicking "Save Changes".

Version-Release number of selected component (if applicable):
4.4.1011

How reproducible:
Always

Steps to Reproduce:
1. Change the Product field when viewing any bug.

Actual results:
It is not obvious how to select one of the new product's components.

Expected results:
It is obvious how to select one of the new product's components.

Additional info:
none.

Comment 5 Simon Green 2014-01-21 23:59:29 UTC
Okay. I need help with this, because I'm missing something very obvious, and I've spent two days trying to fix it without success.

Taking the upstream patch, I apply it to our trunk. The AJAX call in js/fields-ajax.js is returning a 403 error with 8 bytes "No data." according to Firebug. If I change it to a GET call, it works fine. The code in the 'My Requests' page (js/component.js, which is almost identical) works without problem. If I take the upstream code and apply it to upstream 4.4 code, it works without a problem.

So I'm assuming there is something in our customisation that is causing it. I've tried replacing every bit of code that I thought could be causing the problem, but can't find it.

I think this needs a fresh pair of eyes on it.

  -- simon

Comment 7 Matt Tyson 🤬 2014-01-24 06:43:53 UTC
The problem was caused by the Content-Type not being set correctly in the HTTP header and the Json object not including the JSON-RPC protocol version string.

With these issues fixed it works properly.

Comment 10 Matt Tyson 🤬 2014-03-03 01:00:40 UTC
This change is now live. If there are any issues, do not reopen this bug.
Instead, you should create a new bug and reference this bug.