Update an infobox and datagrid column for issue verification.

Review Request #9254 — Created Oct. 9, 2017 and submitted

Information

Review Board
release-3.0.x
a5fb23f...

Reviewers

This enhances two parts of the UI for the new issue verification
feature: The review request infobox and the issues/Ship It dashboard
column.

The review request infobox's status pane now includes the number of
issues pending verification. This is only shown if there are issues
pending verification.

The issues column in the dashboard was previously updated to include the
count in parenthesis, but it wasn't immediately clear what this count
was for. The column has been updated to show the issue verifications
icon alongside the count when there's at least one issue pending
verification. Under the hood, that code has also been updated to be more
centralized and to more easily support additional counters in the
future.

Tested the infobox with review requests with and without issues pending
verification. Saw the icon and count when there were such issues.

Tested all states of the dashboard column.


Description From Last Updated

instead of mark_safe(''.join(format_html(...))) you could just use format_html_join

daviddavid
david
  1. 
      
  2. reviewboard/datagrids/columns.py (Diff revision 1)
     
     
     
    Show all issues

    instead of mark_safe(''.join(format_html(...))) you could just use format_html_join

    1. I can't. See the comment above.

    2. You could build a tuple inside your generator expression. I think it's a lot uglier to do it this way just to use keyword-based formatting.

    3. It's roughly equivalent to what format_html_join does (minus the conditional escaping, since we know what we're passing this into). The complex bit isn't the string joining, but rather the template itself. I'd prefer to keep that more manageable by allowing use of keyword arguments rather than avoiding a string join.

      I imagine this is going to come up from time to time, though. I could write a format_html_join_dict or something for Djblets that consolidates this logic?

  3. 
      
david
  1. Ship It!
  2. 
      
chipx86
Review request changed
Status:
Completed
Change Summary:
Pushed to release-3.0.x (260637d)