Edgewall Software
Modify

Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#9825 closed enhancement (fixed)

Stabilize report column sizes

Reported by: dirkjan@… Owned by: Remy Blank
Priority: low Milestone: 0.12.2
Component: report system Version: 0.12.1
Severity: minor Keywords:
Cc:
Release Notes:
API Changes:

Description

Report column sizes are not fixed, meaning that column sizes depend on contents of the tables. This results in columns jumping around when browsing from report to report. While it cannot be fixed for all cases (because some reports show different columns than other reports), it would be nice if reports showing the same columns had stable column sizes, so that browsing is less jumpy.

Attachments (5)

9825-stable-columns-r10369.patch (6.7 KB ) - added by Remy Blank 8 years ago.
Align columns across groups in query and report results.
9825-thead-for-query_results.patch (3.3 KB ) - added by Christian Boos 8 years ago.
Add <thead> once for the first group (applies on attachment:9825-stable-columns-r10369.patch)
9825-thead-for-query_results.2.patch (3.6 KB ) - added by Christian Boos 8 years ago.
cleaned up version of the previous patch
9825-thead-for-report_view.patch (3.2 KB ) - added by Christian Boos 8 years ago.
Same trick applied to the report_view.html template
9825-stable-columns-r10378.patch (10.6 KB ) - added by Remy Blank 8 years ago.
Full patch with fix for empty group labels in reports.

Download all attachments as: .zip

Change History (16)

comment:1 Changed 8 years ago by Remy Blank

I'm not sure we can do anything sensible to have fixed column sizes between reports, but we could at least start with having consistent column sizes between groups in a single report.

Changed 8 years ago by Remy Blank

Align columns across groups in query and report results.

comment:2 Changed 8 years ago by Remy Blank

I hate XTHML.

I had a nice, clean patch for this ticket, up until I tried validating the result. That's when I learned that even though XHTML allows multiple <tbody> sections in a table, it only allows a single <thead> section. So I had to replace the <thead> sections with <tbody>, which makes this quite a hack.

The major advantage of 9825-stable-columns-r10369.patch is that the result looks much, much cleaner than before (patch against 0.12-stable, BTW). The layout has been checked on all the major browsers.

The drawback is that the table semantics are messed up. This has one immediate effect: when printing a ticket query, the column headers aren't repeated at the top of each page. I haven't found any other issues so far.

So at this point, I'm unsure whether this should go in or not. I do like the straight layout very much, but it feels wrong to mess up the table semantics. Feedback would be appreciated.

comment:3 Changed 8 years ago by Christian Boos

The result is very nice indeed, so it seems worth making an extra effort/complication to fix the little glitch with <thead>. Doing a proof of concept for query_results.html (as it's late ;-) ).

Changed 8 years ago by Christian Boos

Add <thead> once for the first group (applies on attachment:9825-stable-columns-r10369.patch)

comment:4 Changed 8 years ago by Christian Boos

(would be worth to put the <h2> in another py:def as well)

Changed 8 years ago by Christian Boos

cleaned up version of the previous patch

Changed 8 years ago by Christian Boos

Same trick applied to the report_view.html template

comment:5 Changed 8 years ago by Remy Blank

I also thought about putting the first set of headers into a <thead>, but I didn't want the group header to be repeated at the top of each page. I didn't think of putting the first group header outside of the table, a very nice idea indeed!

The table semantics are still a bit messed up, as intermediate headers appear in <tbody>, but I also feel the improved layout is worth it. Thanks for the feedback!

Changed 8 years ago by Remy Blank

Full patch with fix for empty group labels in reports.

comment:6 Changed 8 years ago by Remy Blank

9825-stable-columns-r10378.patch is the full patch, with an additional fix in the case where a group label in a report is empty. The result looks good on all major browsers, so unless something else pops up, I'm going to commit this shortly.

comment:7 Changed 8 years ago by Christian Boos

Please commit, I'll then add an additional check for empty row_group, which can trigger an "index out of range" error in some circumstances (problem already present in current code).

comment:8 Changed 8 years ago by Remy Blank

Patch committed in [10384]. I'll leave the ticket open for your fix.

comment:9 Changed 8 years ago by Thijs Triemstra

Owner: changed from Remy Blank to Christian Boos

comment:10 in reply to:  7 Changed 8 years ago by Christian Boos

Component: ticket systemreport system
Resolution: fixed
Status: newclosed

Little fix added in r10389. I verified that the custom query view was not subjected to the same problem.

comment:11 Changed 8 years ago by Christian Boos

Owner: changed from Christian Boos to Remy Blank

Ownership back to Remy.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Remy Blank.
The resolution will be deleted.
to The owner will be changed from Remy Blank to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.