Closed Bug 138994 Opened 22 years ago Closed 22 years ago

Split duplicates.html.tmpl up

Categories

(Bugzilla :: Reporting/Charting, defect)

2.15
x86
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED
Bugzilla 2.16

People

(Reporter: gerv, Assigned: gerv)

Details

Attachments

(1 file, 1 obsolete file)

We need to make it possible to see only the table of duplicates.html.tmpl by
using "format=simple"; this means the template needs splitting and format
support needs adding.

This is required because the simple duplicates table goes in an IFRAME on the
new simple enter-bug template.

Gerv
Status: NEW → ASSIGNED
Target Milestone: --- → Bugzilla 2.16
I have a patch for this, but it'll be affected by template upheaval.

Gerv
Attached patch Patch v.1 (obsolete) — Splinter Review
OK, this patch does the following:

1) Splits the table out of duplicates.html.tmpl. I don't think I changed any
markup in this process.
2) Allows duplicates.cgi to take a "format" parameter (a few lines at the end.)

3) Provides a new template, duplicates-simple.html.tmpl , to patch the
format=simple parameter. This basically just prints the table.

Gerv
Keywords: patch, review
Comment on attachment 80813 [details] [diff] [review]
Patch v.1

r=bbaetz.

From a SoftEng POV, I don't think I likethe interface comments saying 'also,
see this internal file I use as an implementation detail'. If the main
duplicates template needs to call a function, making sure that certain
preconditions are true, it should directly communicate them to teh caller.

In practice, it probably doens't matter for us, though. You can tell I've been
tutoring 1st year CS about preconditions + design by contract, can't you? ;)
Attachment #80813 - Flags: review+
bbaetz: you could argue that. On the other hand, that info definitely needs to
be in the sub-template; and having it in two places vastly increases the risk
that they get out of sync.

There's no obvious good solution to this.

Gerv
Yeah, true. Which is why I said r=bbaetz...
Comment on attachment 80813 [details] [diff] [review]
Patch v.1

>+my $template_name = "reports/duplicates" . ($format ? "-$format" : "");

Use ValidateOutputFormat instead.
Attachment #80813 - Flags: review-
Attached patch Patch v.2Splinter Review
With markup requested by Myk.

Gerv
Attachment #80813 - Attachment is obsolete: true
Comment on attachment 81196 [details] [diff] [review]
Patch v.2

Works and looks good except for "fulfil" typo.	Change that to "fulfill" and
check it in. 2xr=myk
Attachment #81196 - Flags: review+
Fixed.

Checking in template/en/default/reports/duplicates.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/reports/duplicates.html.tmpl,v
 <--  duplicates.html.tmpl
new revision: 1.4; previous revision: 1.3
done
RCS file:
/cvsroot/mozilla/webtools/bugzilla/template/en/default/reports/duplicates-simple.html.tmpl,v
done
Checking in template/en/default/reports/duplicates-simple.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/reports/duplicates-simple.html.tmpl,v
 <--  duplicates-simple.html.tmpl
initial revision: 1.1
done
RCS file:
/cvsroot/mozilla/webtools/bugzilla/template/en/default/reports/duplicates-table.html.tmpl,v
done
Checking in template/en/default/reports/duplicates-table.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/reports/duplicates-table.html.tmpl,v
 <--  duplicates-table.html.tmpl
initial revision: 1.1
done
Checking in duplicates.cgi;
/cvsroot/mozilla/webtools/bugzilla/duplicates.cgi,v  <--  duplicates.cgi
new revision: 1.19; previous revision: 1.18
done

Gerv
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
QA Contact: matty_is_a_geek → default-qa
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: