4751: "Reload" button on Admin Dashboard News widget does not function


What version are you running?

Review Board release-4.0.x

What's the URL of the page containing the problem?


What steps will reproduce the problem?

In w-news.html, line 10 contains this code: $('.reload-news').click(function(evt) {
This attaches a click function callback to objects with a class of reload-news, however the reload button has an id of reload-news. The reload code will never be triggered because of this.

To reproduce:
1. Insert console.log("test"); into line 11 in w-news.html, right after $('.reload-news').click(function(evt) {
2. Reload admin page, open up javascript console, and click on the "Reload" button.
3. test will not appear in the javascript console.

What is the expected output? What do you see instead?

The expected output of this is that the news widget should reload. It only reloads on a page refresh, not when the button is clicked.

What operating system are you using? What browser?

Ubuntu 18.04, Firefox 62.0

Please provide any additional information below.

This is an easyfix bug, because it involves 1 character change (change $('.reload-news').click(function(evt) { to $('#reload-news').click(function(evt) {). However, a test should be added to confirm that the "Reload" button does in fact work as expected.

#1 brennie
  • -New
  • +EasyFix
#2 amalik2

Working on it