Chairman's Worksheet
You can change how comments are displayed by adjusting the default templates. For example, you could make each type of comment look different on the worksheet if you wanted to!
Here is summary of how the comments are displayed using the default templates.
Style Sheet
The style sheet uses these classes to format how the comments are displayed:
.cellChairmanNotes {
border-left: 1px solid #d3d3d3;
border-right: 1px solid #d3d3d3;
border-top: 1px none #d3d3d3;
border-bottom: 1px solid #d3d3d3;
}
.textChairmanNotes {
font-size: 10pt;
padding: 2mm;
margin: 0;
min-height: 25mm;
text-align: left;
}
.containerAnnounce {
margin-top: 0.5em;
}
XML Data
The XML data includes the comments using the following syntax:
<ChairmanNotes>
<OpeningComments>
<Comments>Note 1</Comments>
</OpeningComments>
<ClosingComments IncludeNextWeeksStudents="1">
<Comments>Note 2</Comments>
<ClosingAnnouncements>
<Announcement>Announcement 1</Announcement>
<Announcement>Announcement 2</Announcement>
</ClosingAnnouncements>
</ClosingComments>
<Treasures1>Note 3</Treasures1>
<Treasures2>Note 4</Treasures2>
<Living1>Note 5</Living1>
<Living2>Note 6</Living2>
<Living3>Note 7</Living3>
</ChairmanNotes>
XSL Script
The script includes these templates:
<xsl:template match ="OpeningComments | ClosingComments | Treasures1 | Treasures2 | Living1 | Living2 | Living3" mode="ChairmanNotes">
<tr>
<td colspan="4" class="cellChairmanNotes">
<div class="textChairmanNotes">
<xsl:choose>
<xsl:when test="self::OpeningComments">
<xsl:value-of select="Comments" disable-output-escaping="yes"/>
</xsl:when>
<xsl:when test="self::ClosingComments">
<xsl:value-of select="Comments" disable-output-escaping="yes"/>
<xsl:apply-templates select="ClosingAnnouncements"/>
<xsl:if test="@IncludeNextWeeksStudents='1'">
<xsl:variable name="AssignHistoryPath">
<xsl:choose>
<xsl:when test="//Settings/ForeignGroupMode=1">ForeignAssignHistory.xml</xsl:when>
<xsl:otherwise>AssignHistory.xml</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="AssignHistory" select="document($AssignHistoryPath)"/>
<xsl:variable name="week" select="../../Date/@NextWeek"/>
<div class="NextWeeksStudents-Container">
<xsl:apply-templates select="$AssignHistory/AssignmentHistory/*[name()=$week]/StudentItems">
<xsl:with-param name="MainHall" select="//Labels/MainHall"/>
<xsl:with-param name="AuxClass1" select="//Labels/AuxClass1"/>
<xsl:with-param name="AuxClass2" select="//Labels/AuxClass2"/>
</xsl:apply-templates>
</div>
</xsl:if>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="." disable-output-escaping="yes"/>
</xsl:otherwise>
</xsl:choose>
</div>
</td>
</tr>
</xsl:template>
<xsl:template match="OpeningAnnouncements | ClosingAnnouncements">
<div class="containerAnnounce">
<span class="textAnnounceHeading">
<xsl:value-of select="//Labels/Announcements"/>
</span>
<ul>
<xsl:apply-templates select="Announcement"/>
</ul>
</div>
</xsl:template>
<xsl:template match="Announcement">
<li>
<xsl:value-of select="."/>
</li>
</xsl:template>
The main template has been designed to display all of the chairman's comments on the worksheet in the same way. This template is called wherever you want a specific comment to be displayed. For example:
<xsl:apply-templates select="ChairmanNotes/OpeningComments" mode="ChairmanNotes"/>
You will find similar lines of code in the Worksheet script that displays the other comments.