home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.tcs3.com
/
ftp.tcs3.com.tar
/
ftp.tcs3.com
/
DRIVERS
/
Audio
/
Office2010
/
ProPlus.WW
/
ProPsWW2.cab
/
HIERARCHY.XSL
< prev
next >
Wrap
Extensible Markup Language
|
2007-02-04
|
6KB
|
182 lines
<?xml version="1.0" encoding="iso-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/TR/WD-xsl">
<!-- MAIN -->
<xsl:template match="/">
<html>
<head>
<title>Tree Menu</title>
<style type="text/css">
BODY, TABLE, TR, TD, DIV
{
font-family: tahoma, arial, sans-serif;
font-size: 11px;
}
.header TD
{
background-color: navy;
color: white;
font-weight: bold;
}
.previewHeader
{
background-color: navy;
}
.previewBody
{
background-color: lightgrey;
}
.recordRow
{
cursor: default;
}
#previewParentSubject
{
font-size: 13px;
color: white;
}
#previewSubject
{
font-size: 17px;
font-weight: bold;
color: white;
}
</style>
<script language="javascript" src="Hierarchy.js"></script>
</head>
<body onload="highlightProjectTask()">
<table cellpadding="3" cellspacing="0" border="1" width="100%">
<tr class="header">
<td>Task</td>
<td width="100">Start</td>
<td width="100">Finish</td>
<td width="100">Assigned To</td>
<td width="100">Priority</td>
<td width="100">Status</td>
<td width="100">Description</td>
</tr>
<xsl:apply-templates select="ProjectToolReport/Task"/>
</table>
<br/>
<table cellpadding="2" cellspacing="0" border="0" width="100%">
<tr>
<td class="previewHeader">
<table cellpadding="2" cellspacing="0" border="0">
<tr>
<td width="30" rowspan="2"></td>
<td id="previewParentSubject"></td>
</tr>
<tr>
<td id="previewSubject"></td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="previewBody">
<table cellpadding="2" cellspacing="0" border="0">
<tr>
<td width="30" rowspan="6"></td>
<td id="previewAssignedToLabel">Assigned To:</td>
<td width="15" rowspan="6"></td>
<td id="previewAssignedTo"></td>
</tr>
<tr>
<td>Start Date:</td>
<td id="previewStartDate"></td>
</tr>
<tr>
<td>Finish Date:</td>
<td id="previewDueDate"></td>
</tr>
<tr>
<td>Status:</td>
<td id="previewStatus"></td>
</tr>
<tr>
<td>Priority:</td>
<td id="previewPriority"></td>
</tr>
<tr>
<td>Description:</td>
<td id="previewDescription"></td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
</xsl:template>
<xsl:template match="Task">
<tr onclick="highlightRow(this)" class="recordRow" childstatus="visible">
<xsl:attribute name="id"><xsl:value-of select="ID"/></xsl:attribute>
<xsl:attribute name="parentid"><xsl:value-of select="ParentID"/></xsl:attribute>
<xsl:attribute name="depth"><xsl:eval>depth(this) - 2</xsl:eval></xsl:attribute>
<xsl:attribute name="ProjectTaskId"><xsl:value-of select="ProjectTaskId"/></xsl:attribute>
<xsl:attribute name="ProjectTaskLeader"><xsl:value-of select="ProjectTaskLeader"/></xsl:attribute>
<!-- <xsl:attribute name="description"><xsl:value-of select="Description"/></xsl:attribute> -->
<td valign="top">
<xsl:attribute name="id"><xsl:eval>getTaskId(this) + "_Subject"</xsl:eval></xsl:attribute>
<img src="spacer.gif" height="9" align="absmiddle"><xsl:attribute name="width"><xsl:eval>(depth(this) - 2) * 9</xsl:eval></xsl:attribute></img>
<xsl:choose>
<xsl:when test="./Task">
<a><xsl:attribute name="href"><xsl:eval>"javascript:collapseExpandRow('" + getTaskId(this) + "')"</xsl:eval></xsl:attribute><img src="minus.gif" width="9" height="9" hspace="3" border="0" align="absmiddle"><xsl:attribute name="id"><xsl:eval>getTaskId(this) + "Image"</xsl:eval></xsl:attribute></img></a>
</xsl:when>
<xsl:otherwise>
<img src="spacer.gif" width="9" height="9" hspace="3" border="0" align="absmiddle"/>
</xsl:otherwise>
</xsl:choose>
<xsl:value-of select="TaskName"/>
</td>
<td nowrap="true" valign="top">
<xsl:attribute name="id"><xsl:eval>getTaskId(this) + "_StartDate"</xsl:eval></xsl:attribute>
<xsl:value-of select="StartDate"/>
</td>
<td width="100" nowrap="true" valign="top">
<xsl:attribute name="id"><xsl:eval>getTaskId(this) + "_DueDate"</xsl:eval></xsl:attribute>
<xsl:value-of select="FinishDate"/>
</td>
<td width="100" nowrap="true" valign="top">
<xsl:attribute name="id"><xsl:eval>getTaskId(this) + "_AssignedTo"</xsl:eval></xsl:attribute>
<xsl:value-of select="AssignedTo"/>
</td>
<td width="60" nowrap="true" valign="top">
<xsl:attribute name="id"><xsl:eval>getTaskId(this) + "_Priority"</xsl:eval></xsl:attribute>
<xsl:value-of select="Priority"/>
</td>
<td width="60" nowrap="true" valign="top">
<xsl:attribute name="id"><xsl:eval>getTaskId(this) + "_Status"</xsl:eval></xsl:attribute>
<xsl:value-of select="Status"/>
</td>
<td width="150" wrap="true" valign="top">
<xsl:attribute name="id"><xsl:eval>getTaskId(this) + "_Description"</xsl:eval></xsl:attribute>
<xsl:value-of select="Description"/>
</td>
</tr>
<xsl:apply-templates select="Task"/>
</xsl:template>
<xsl:script>
<![CDATA[
function getTaskId(i_objNode)
{
return i_objNode.selectSingleNode("ID").text;
}
]]>
</xsl:script>
</xsl:stylesheet>