Serververwaltung > Reports > Creating a Report Recipe > Displaying Relationship Time Entries in a Report Recipe
  
Displaying Relationship Time Entries in a Report Recipe
Users want a report that displays time entry information of related items. They want the ability to choose the same type of time entry information as the previous time entry report, only for related items.
Add relationship time entry tags to a relationship report recipe to display the time entry fields of related items.
For example:
<%version 1%>
<%description <b>Description: </b>This is a report that uses
Windchill RVS relationship time entry report tags.<br><br>%>
<%param name="reporttitle" type="String" prompt="Report Title"
value="" description="Descriptive title for your report."%>
<%param name="reportheader" type="MultiString" prompt="Report
Header" value="" description="Text appearing at the top of
the report page."%>
<%param name="reportfooter" type="MultiString" prompt="Report
Footer" value="Confidential - Internal Use Only"
description="Text appearing at the bottom of the report page."%>
<%param name="itemheading" type="String" prompt="Item Heading"
value="{Type}: {ID} - {Summary}" description="This is displayed
at the top of each item in the report."%>
<%param name="timeentryheading" type="String"
prompt="Relationship Time Entry Heading" value="Time Entries"
description="This is displayed at the top of the relationship
time entry area."%>
<html>
<head>
<title>Relationship Time Entry Report</title>
<%screenStyleSheet%>
<%printerStyleSheet%>
</head>

<%dateformat%>
<%datetimeformat%>
<%sortby &sortby%>
<body>
<span class="logo"><%logoURL%></span>
<p class="title">&reporttitle</p>
<p class="header">&reportheader</p>
<div align="right" class="date"><%currentdate%></div>
<table class="display">
<%begindetail%>
<tr>
<td colspan="&#fields"
class="bold_color_large">&itemheading</td>
</tr>
</table>
<hr class="hr_default">
<table class="display">
<!-- Display item field headings -->
<tr>
<%iteratefields%>
<th class="heading1">&fielddisplayname</th>
<%/iteratefields%>
<!-- Display time entry heading -->
<th class="heading1">&timeentryheading</th>
</tr>
</table>
<hr class="hr_default">
<table class="display">
<!-- Relationships -->
<!-- Level One Relationships -->
<%segment name="Level 1 Relationships" type="relationship"
enabled="true" description="<html>Displays related items
that are one level below the item returned by the report
query.</html>"%>
<%param name="norelationships" type="String" prompt="No
Relationships Message" value="No related items."
description="The message displayed if there are no related
items found."%>
<%param name="notimeentries" type="String" prompt="No Time
Entries Message" value="No time entries." description="The
message displayed if there are no time entries on an item."%>
<%beginrelationshipsdetail &relationshipsdetailfields%>
<%beginrelationshipsection none%>
<tr><td>&norelationships</td></tr>
<%endrelationshipsection%>
<tr class="level1">
<%iteraterelationshipfields%>
<td class="border">&relationshipfieldname</td>
<%/iteraterelationshipfields%>
<td>
<table class="list3">
<%relationshipbegintimeentriesdetail%>
<!-- Display time entry field headings -->
<%begintimeentrysection header%>
<tr>
<%iteratetimeentryfields%>
<th>&timeentryfielddisplayname</th>
<%/iteratetimeentryfields%>
</tr>
<%endtimeentrysection%>
<!-- Display no time entries found -->
<%begintimeentrysection none%>
<tr><td>&notimeentries</td></tr>
<%endtimeentrysection%>
<!-- Display time entry field values -->
<tr>
<%iteratetimeentryfields%>
<td>&timeentryfieldname</td>
<%/iteratetimeentryfields%>
</tr>
<%relationshipendtimeentriesdetail%>
</table>
</td>
</tr>
<%endrelationshipsdetail%>
<%/segment%>
</table>
<hr class="hr_default"><br/>
<%enddetail%>
<span class="footer">&reportfooter</span>
<div align="center">
<a href="<%weburl%>im/runreport?selection=&currentReportName">
<img src="<%weburl%>Report_Recipe/re-run_report.gif"
align="middle" border="0">
</a>
</div>
</body>
</html>