Closed
Bug 124937
Opened 23 years ago
Closed 23 years ago
Templatise show_activity.cgi
Categories
(Bugzilla :: User Interface, defect)
Tracking
()
RESOLVED
FIXED
Bugzilla 2.16
People
(Reporter: gerv, Assigned: gerv)
References
Details
Attachments
(1 file, 4 obsolete files)
14.24 KB,
patch
|
myk
:
review+
bbaetz
:
review+
|
Details | Diff | Splinter Review |
Here's another one - this is reasonably simple. We're knocking them off... Gerv
Assignee | ||
Comment 1•23 years ago
|
||
This isn't quite ready yet - it changes DumpBugActivity significantly (templatisation and cleanup) but doesn't change process_bug.cgi to use the new version, so that will break. Still, a quick glance over it to tell me if I've made egregious errors would be appreciated. Gerv
Assignee | ||
Comment 3•23 years ago
|
||
Ook. No it doesn't. But it could. I'll take it into account while producing version 1.0. Gerv
Assignee | ||
Comment 4•23 years ago
|
||
Now fixes bug 94303, but doesn't change process_bug, as it's being templatised over in bug 125660 , and there are other templatisation patches which touch that exact part of process_bug. Gerv
Attachment #68940 -
Attachment is obsolete: true
Updated•23 years ago
|
Comment 5•23 years ago
|
||
Why does GetBugActivity poke $::vars directly, rather than just return 2 vars?
Assignee | ||
Comment 6•23 years ago
|
||
How do you return two vars? return $foo, $bar; ? Gerv
Comment 7•23 years ago
|
||
Return a two element array or list.
Assignee | ||
Comment 8•23 years ago
|
||
Actually, but 110012 is the real dependency, because it touches process_bug.cgi. Gerv
Comment 9•23 years ago
|
||
+ [% IF change.attachid %] + <a href="attachment.cgi?id=[% change.attachid %]&action=view"> + Attachment #[% change.attachid %]</a> ...should read &action=view.
Assignee | ||
Comment 10•23 years ago
|
||
This should be it, just about. I've changed comments.tmpl to use "comments" instead of "bug.comments", which seems more correct. Gerv
Attachment #71071 -
Attachment is obsolete: true
Comment 11•23 years ago
|
||
Comment on attachment 76307 [details] [diff] [review] Patch v.1 >Index: template/default/show/activity.html.tmpl >=================================================================== >RCS file: template/default/show/activity.html.tmpl >diff -N template/default/show/activity.html.tmpl >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ template/default/show/activity.html.tmpl 26 Mar 2002 23:57:23 -0000 >@@ -0,0 +1,91 @@ >+ # attach_id: integer. If the change was adding an attachment, its id. >+ # incomplete_data: boolean. True if some of the data is incomplete (because >+ # it was affected by an old Bugzilla bug.) >+ #%] >+ Can you mention the bug # here, in the comment? Of course, 'starts with ?' is a really bad heruistic, but you're not changing that. >+ [% FOREACH change = operation.changes %] >+ [% "<tr>" IF loop.index > 0 %] >+ <td> >+ [% IF change.attachid %] >+ <a href="attachment.cgi?id=[% change.attachid %]&action=view"> >+ Attachment #[% change.attachid %]</a> >+ [% END %] >+ [% change.field %] This should be FILTER html, too, except that then you'd lose the attachment links. We don't ahve any fields with objectionable names, so I guess you can leave this for the moment. r=bbaetz
Attachment #76307 -
Flags: review+
Comment 12•23 years ago
|
||
Comment on attachment 76307 [details] [diff] [review] Patch v.1 >Index: CGI.pl >+ my $operation = {}; >+ my $changes = (); "$changes = ()" --> "$changes = []" since you are initializing an array reference (just like you use "{}" when initializing a hash reference). >+ # Check for the results of an old Bugzilla data corruption bug >+ $incomplete_data = 1 if ($added =~ /^\?/ || $removed =~ /^\?/); Nit: unnecessary parentheses. >+ $operation = {}; >+ $changes = (); "$changes = ()" --> "$changes = []" since you are initializing an array reference. Fix these problems and I'll r= it.
Attachment #76307 -
Flags: review-
Assignee | ||
Comment 13•23 years ago
|
||
> >+ # Check for the results of an old Bugzilla data corruption bug > >+ $incomplete_data = 1 if ($added =~ /^\?/ || $removed =~ /^\?/); > > Nit: unnecessary parentheses. Because it's a double-barrelled clause, I think keeping them aids readability. > Can you mention the bug # here, in the comment? If I knew what it was :-| I don't think any of the old comments said. Gerv
Attachment #76307 -
Attachment is obsolete: true
Assignee | ||
Comment 14•23 years ago
|
||
v.2 is the same patch as v.1. Oops. :-) Gerv
Attachment #77222 -
Attachment is obsolete: true
Comment 15•23 years ago
|
||
Comment on attachment 77223 [details] [diff] [review] Patch v.3 Works, looks good. r=myk
Attachment #77223 -
Flags: review+
Comment 16•23 years ago
|
||
>Because it's a double-barrelled clause, I think keeping them aids readability.
My mistake, you are right. Nit rescinded. :-)
Comment 17•23 years ago
|
||
Comment on attachment 77223 [details] [diff] [review] Patch v.3 WFM, too. the corruption bug was just an extra biut on the orignal checkin, so don't bother with it. r=bbaetz
Attachment #77223 -
Flags: review+
Comment 18•23 years ago
|
||
Oh, and you need to change multiple.tmpl, too: [% PROCESS show/comments.tmpl comments=bug.comments %] else comments don't show up on the long list stuff.
Assignee | ||
Comment 19•23 years ago
|
||
Fixed. Checking in show_activity.cgi; /cvsroot/mozilla/webtools/bugzilla/show_activity.cgi,v <-- show_activity.cgi new revision: 1.8; previous revision: 1.7 done Checking in CGI.pl; /cvsroot/mozilla/webtools/bugzilla/CGI.pl,v <-- CGI.pl new revision: 1.140; previous revision: 1.139 done Checking in process_bug.cgi; /cvsroot/mozilla/webtools/bugzilla/process_bug.cgi,v <-- process_bug.cgi new revision: 1.120; previous revision: 1.119 done RCS file: /cvsroot/mozilla/webtools/bugzilla/template/default/show/activity.html.tmpl,v done Checking in template/default/show/activity.html.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/default/show/activity.html.tmpl,v <-- activity.html.tmpl initial revision: 1.1 done RCS file: /cvsroot/mozilla/webtools/bugzilla/template/default/show/bug-activity.html.tmpl,v done Checking in template/default/show/bug-activity.html.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/default/show/bug-activity.html.tmpl,v <-- bug-activity.html.tmpl initial revision: 1.1 done Checking in template/default/show/comments.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/default/show/comments.tmpl,v <-- comments.tmpl new revision: 1.3; previous revision: 1.2 done Checking in template/default/show/show_bug.html.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/default/show/show_bug.html.tmpl,v <-- show_bug.html.tmpl new revision: 1.8; previous revision: 1.7 done Checking in template/default/show/multiple.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/default/show/multiple.tmpl,v <-- multiple.tmpl new revision: 1.2; previous revision: 1.1 done Gerv
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Updated•12 years ago
|
QA Contact: matty_is_a_geek → default-qa
You need to log in
before you can comment on or make changes to this bug.
Description
•