Make a bunch of improvements to the FileAttachment admin list.

Review Request #13576 — Created Feb. 27, 2024 and submitted

Information

Review Board
release-7.x

Reviewers

The way attachments were listed in the admin site was very difficult to
use. The file field was linking to the download URL, and the only
other link to the change page was the caption, which could be empty.

This change improves the admin list so that the filename rather than the
path is listed (potentially cropped to preserve the page with), but that
always links to the change page. The "Review Request ID" column now
properly shows the linked review request even when the attachment is
part of a draft or in the inactive list. A new column has been added
with the download link.

Used the admin list and was actually able to get to the change page for
many of my attachments.

Summary ID
Make a bunch of improvements to the FileAttachment admin list.
The way attachments were listed in the admin site was very difficult to use. The `file` field was linking to the download URL, and the only other link to the change page was the caption, which could be empty. This change improves the admin list so that the filename rather than the path is listed (potentially cropped to preserve the page with), but that always links to the change page. The "Review Request ID" column now properly shows the linked review request even when the attachment is part of a draft or in the inactive list. A new column has been added with the download link. Testing Done: Used the admin list and was actually able to get to the change page for many of my attachments.
723e62158186e54d2f2e9cfc94b35d6d00a52e54
Description From Last Updated

We should move to the new form for this: @admin.display( short_description=... )

chipx86chipx86
maubin
  1. Ship It!
  2. 
      
chipx86
  1. 
      
  2. reviewboard/attachments/admin.py (Diff revision 1)
     
     
     
    Show all issues

    We should move to the new form for this:

    @admin.display(
        short_description=...
    )
    
    1. Actually, description=

  3. 
      
david
david
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-5.0.x (7b45df7)
Loading...