Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
355cb972
Commit
355cb972
authored
Apr 18, 2002
by
myk%mozilla.org
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix for bug 126792: Templatizes showdependencytree.cgi.
Patch by Myk Melez <myk@mozilla.org>. r=afranke,gerv
parent
65733e36
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
208 additions
and
0 deletions
+208
-0
showdependencytree.cgi
showdependencytree.cgi
+0
-0
dependency-tree.html.tmpl
template/default/show/dependency-tree.html.tmpl
+208
-0
No files found.
showdependencytree.cgi
View file @
355cb972
This diff is collapsed.
Click to expand it.
template/default/show/dependency-tree.html.tmpl
0 → 100644
View file @
355cb972
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Tobias Burnus <burnus@net-b.de>
# Ville Skytt <ville.skytta@iki.fi>
# Myk Melez <myk@mozilla.org>
#%]
[% PROCESS global/header
title = "Dependency tree for Bug $bugid"
h1 = "Dependency tree for bug <a href=\"show_bug.cgi?id=$bugid\">$bugid</a>"
style = "strike { background-color: #d9d9d9; color: #000000; }"
%]
[% PROCESS depthControlToolbar %]
[%# Display the tree of bugs that this bug depends on. %]
<h3>Bugs that bug <a href="show_bug.cgi?id=[% bugid %]">[% bugid %]</a> depends on
[% IF dependson_ids.size > 0 %]
(<a href="buglist.cgi?bug_id=[% dependson_ids.join(",") %]">view as bug list</a>
[% IF canedit && dependson_ids.size > 1 %]
| <a href="buglist.cgi?bug_id=[% dependson_ids.join(",") %]&tweak=1">change several</a>
[% END %])
[% IF maxdepth || hide_resolved %]
<small><b>
(Only [% "open" IF hide_resolved %] bugs
[% " whose depth is less than $maxdepth" IF maxdepth %]
will be shown)
</b></small>
[% END %]
</h3>
[% INCLUDE display_tree tree=dependson_tree bug_id=bugid %]
[% ELSE %]
</h3>
<p>None</p>
[% END %]
[%# Display the tree of bugs that this bug blocks. %]
<h3>Bugs that bug <a href="show_bug.cgi?id=[% bugid %]">[% bugid %]</a> blocks
[% IF blocked_ids.size > 0 %]
(<a href="buglist.cgi?bug_id=[% blocked_ids.join(",") %]">view as bug list</a>
[% IF canedit && blocked_ids.size > 1 %]
| <a href="buglist.cgi?bug_id=[% blocked_ids.join(",") %]&tweak=1">change several</a>
[% END %])
[% IF maxdepth || hide_resolved %]
<small><b>
(Only [% "open" IF hide_resolved %] bugs
[% " whose depth is less than $maxdepth" IF maxdepth %]
will be shown)
</b></small>
[% END %]
</h3>
[% INCLUDE display_tree tree=blocked_tree bug_id=bugid %]
[% ELSE %]
</h3>
<p>None</p>
[% END %]
[% PROCESS depthControlToolbar %]
[% PROCESS global/footer %]
[%###########################################################################%]
[%# Block to display a tree #%]
[%###########################################################################%]
[% BLOCK display_tree %]
<ul>
[% FOREACH dep_id = tree.$bug_id.dependencies %]
[% dep = tree.$dep_id %]
<li>
[% "<strike>" IF !dep.open %]
<a href="show_bug.cgi?id=[% dep_id %]">[% dep_id %]
[[% IF dep.milestone %][% dep.milestone FILTER html %], [% END %]
[% dep.assignee_email FILTER html %]] -
[% IF dep.seen %]
<i><This bug appears elsewhere in this tree></i></a>
[% ELSE %]
[% dep.summary FILTER html %].</a>
[% END %]
[% "</strike>" IF !dep.open %]
[% INCLUDE display_tree bug_id=dep_id
IF dep.dependencies.size > 0 && !dep.seen %]
</li>
[% dep.seen = 1 %]
[% END %]
</ul>
[% END %]
[%###########################################################################%]
[%# Block for depth control toolbar #%]
[%###########################################################################%]
[% BLOCK depthControlToolbar %]
<table cellpadding="3" border="0" cellspacing="0" bgcolor="#d0d0d0">
<tr>
[%# Hide/show resolved button
Swaps text depending on the state of hide_resolved %]
<td align="center">
<form method="get" action="showdependencytree.cgi"
style="display: inline; margin: 0px;">
<input name="id" type="hidden" value="[% bugid %]">
[% IF maxdepth %]
<input name="maxdepth" type="hidden" value="[% maxdepth %]">
[% END %]
<input type="hidden" name="hide_resolved" value="[% hide_resolved ? 0 : 1 %]">
<input type="submit" value="[% hide_resolved ? "Show" : "Hide" %] Resolved">
</form>
</td>
<td>
Max Depth:
</td>
<td>
</td>
<td>
<form method="get" action="showdependencytree.cgi"
style="display: inline; margin: 0px;">
[%# set to one form %]
<input type="submit" value=" 1 " [%
realdepth < 2 || maxdepth == 1 ? "disabled" : ""
%]>
<input name="id" type="hidden" value="[% bugid %]">
<input name="maxdepth" type="hidden" value="1">
<input name="hide_resolved" type="hidden" value="[% hide_resolved %]">
</form>
</td>
<td>
<form method="get" action="showdependencytree.cgi"
style="display: inline; margin: 0px;">
[%# Minus one form
Allow subtracting only when realdepth and maxdepth > 1 %]
<input name="id" type="hidden" value="[% bugid %]">
<input name="maxdepth" type="hidden" value="[%
maxdepth == 1 ? 1
: ( maxdepth ? maxdepth - 1 : realdepth - 1 )
%]">
<input name="hide_resolved" type="hidden" value="[% hide_resolved %]">
<input type="submit" value=" < " [%
realdepth < 2 || ( maxdepth && maxdepth < 2 ) ? "disabled" : ""
%]>
</form>
</td>
<td>
<form method="get" action="showdependencytree.cgi"
style="display: inline; margin: 0px;">
[%# Limit entry form: the button can not do anything when total depth
is less than two, so disable it %]
<input name="maxdepth" size="4" maxlength="4" value="[%
maxdepth > 0 ? maxdepth : ""
%]">
<input name="id" type="hidden" value="[% bugid %]">
<input name="hide_resolved" type="hidden" value="[% hide_resolved %]">
<noscript>
<input type="submit" value="Change" [% realdepth < 2 ? "disabled" : "" %]>
</noscript>
</form>
</td>
<td>
<form method="get" action="showdependencytree.cgi"
style="display: inline; margin: 0px;">
[%# plus one form
Disable button if total depth < 2, or if depth set to unlimited %]
<input name="id" type="hidden" value="[% bugid %]">
[% IF maxdepth %]
<input name="maxdepth" type="hidden" value="[% maxdepth + 1 %]">
[% END %]
<input name="hide_resolved" type="hidden" value="[% hide_resolved %]">
<input type="submit" value=" > " [%
realdepth < 2 || ! maxdepth || maxdepth >= realdepth ?
"disabled" : ""
%]>
</form>
</td>
<td>
<form method="get" action="showdependencytree.cgi"
style="display: inline; margin: 0px;">
[%# Unlimited button %]
<input name="id" type="hidden" value="[% bugid %]">
<input name="hide_resolved" type="hidden" value="[% hide_resolved %]">
<input type="submit" value=" Unlimited ">
</form>
</td>
</tr>
</table>
[% END %]
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment