Advertisement
TheocraticSoftware

Worksheet-Include-Auxiliary-Classroom-Counsellor.xsl

Feb 27th, 2017
191
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 31.94 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml">
  3.   <xsl:output method="html" indent="yes" version="4.01"
  4.    doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
  5.    doctype-public="//W3C//DTD XHTML 1.0 Transitional//EN"/>
  6.   <xsl:template match="/">
  7.     <html xmlns="http://www.w3.org/1999/xhtml">
  8.       <head>
  9.         <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
  10.         <link rel="stylesheet" type="text/css" href="Worksheet.css"/>
  11.         <title>
  12.           <xsl:value-of select="//Labels/ReportTitleWorksheets"/>
  13.         </title>
  14.       </head>
  15.       <body>
  16.  
  17.         <xsl:for-each select="MeetingWorkBook/Meeting">
  18.  
  19.           <!--We only add the page breaks when we are in "Print Preview" mode-->
  20.           <xsl:if test="InsertPageBreak=1">
  21.             <!--This seems to be the only way to insert a page break-->
  22.             <br style="page-break-before: always;"/>
  23.           </xsl:if>
  24.  
  25.           <!--This the the date, opening song, chairman and prayer-->
  26.           <xsl:call-template name="Display_DateInfo">
  27.             <xsl:with-param name = "Class">M</xsl:with-param>
  28.           </xsl:call-template>
  29.  
  30.           <!--Treasures from God's Word-->
  31.           <xsl:call-template name="Display_TFGW">
  32.             <xsl:with-param name = "Class">M</xsl:with-param>
  33.           </xsl:call-template>
  34.  
  35.           <!--Apply Yourself To The Field Ministry-->
  36.           <xsl:call-template name="Display_AYTFM">
  37.             <xsl:with-param name = "Class">M</xsl:with-param>
  38.           </xsl:call-template>
  39.  
  40.           <!--Living As Christians-->
  41.           <xsl:call-template name="Display_LAC" />
  42.  
  43.           <!--Auxiliary counsellor worksheets-->
  44.           <!--The number of classes is set to 1 when it is the first week of the month-->
  45.           <!--Class 1-->
  46.           <xsl:if test="NumberClasses&gt;=2">
  47.             <br style="page-break-before: always;"/>
  48.  
  49.             <!--This the the date, opening song, chairman and prayer-->
  50.             <xsl:call-template name="Display_DateInfo">
  51.               <xsl:with-param name = "Class">1</xsl:with-param>
  52.             </xsl:call-template>
  53.  
  54.             <!--Treasures from God's Word-->
  55.             <xsl:call-template name="Display_TFGW">
  56.               <xsl:with-param name = "Class">1</xsl:with-param>
  57.             </xsl:call-template>
  58.  
  59.             <!--Apply Yourself To The Field Ministry-->
  60.             <xsl:call-template name="Display_AYTFM">
  61.               <xsl:with-param name = "Class">1</xsl:with-param>
  62.             </xsl:call-template>
  63.           </xsl:if>
  64.  
  65.           <!--Class 2-->
  66.           <xsl:if test="NumberClasses=3">
  67.             <br style="page-break-before: always;"/>
  68.  
  69.             <!--This the the date, opening song, chairman and prayer-->
  70.             <xsl:call-template name="Display_DateInfo">
  71.               <xsl:with-param name = "Class">2</xsl:with-param>
  72.             </xsl:call-template>
  73.  
  74.             <!--Treasures from God's Word-->
  75.             <xsl:call-template name="Display_TFGW">
  76.               <xsl:with-param name = "Class">2</xsl:with-param>
  77.             </xsl:call-template>
  78.  
  79.             <!--Apply Yourself To The Field Ministry-->
  80.             <xsl:call-template name="Display_AYTFM">
  81.               <xsl:with-param name = "Class">2</xsl:with-param>
  82.             </xsl:call-template>
  83.           </xsl:if>
  84.  
  85.         </xsl:for-each>
  86.       </body>
  87.     </html>
  88.   </xsl:template>
  89.  
  90.   <!--This the the date, opening song, chairman and prayer-->
  91.   <xsl:template name = "Display_DateInfo" >
  92.     <xsl:param name = "Class" />
  93.     <div class="containerDate">
  94.       <table cellpadding="2" cellspacing="0" class="tableOuter">
  95.         <tr class="cellDate">
  96.           <td class="textDate">
  97.             <strong>
  98.               <xsl:value-of select="Date"/>
  99.             </strong>
  100.           </td>
  101.           <td class="textChairmanTitle">
  102.             <strong>
  103.               <xsl:choose>
  104.                 <xsl:when test="$Class='M'">
  105.                   <xsl:value-of select="//Labels/ReportTitleChairman"/>
  106.                 </xsl:when>
  107.                 <xsl:otherwise>
  108.                   <xsl:value-of select="//Labels/ReportTitleAuxCounsellor"/>
  109.                 </xsl:otherwise>
  110.               </xsl:choose>
  111.             </strong>
  112.           </td>
  113.           <td class="textChairman">
  114.             <strong>
  115.               <xsl:choose>
  116.                 <xsl:when test="$Class='M'">
  117.                   <xsl:value-of select="Chairman"/>&#160;
  118.                 </xsl:when>
  119.                 <xsl:when test="$Class='1'">
  120.                   <xsl:value-of select="AuxCounsellor1"/>
  121.                 </xsl:when>
  122.                 <xsl:otherwise>
  123.                   <xsl:value-of select="AuxCounsellor2"/>
  124.                 </xsl:otherwise>
  125.               </xsl:choose>
  126.             </strong>
  127.           </td>
  128.         </tr>
  129.       </table>
  130.  
  131.       <xsl:if test="$Class='M'">
  132.         <div class="gap"></div>
  133.  
  134.         <table cellpadding="2" cellspacing="0" class="tableOuter">
  135.           <tr>
  136.             <td class="borderDotTimeDuration" style="border-top-style:solid">
  137.               [<xsl:value-of select="SongOpen/@EndTime24"/>]
  138.             </td>
  139.             <td class="borderDotTime" style="border-top-style:solid">
  140.               <xsl:value-of select="//Labels/SongDuration"/>
  141.             </td>
  142.             <td class="borderDotTheme" style="border-top-style:solid">
  143.               <span class="floatTextLeft">
  144.                 <xsl:value-of select="//Labels/Song"/>&#160;
  145.                 <xsl:value-of select="SongOpen"/>&#160;
  146.                 <span class="textSongTitle">
  147.                   <xsl:value-of select="SongOpen/@Title"/>
  148.                 </span>
  149.               </span>
  150.               <span class="floatTextRight">
  151.                 <xsl:value-of select="//Labels/Prayer"/>
  152.               </span>
  153.             </td>
  154.             <td class="borderDotName" style="border-top-style:solid">
  155.               <xsl:value-of select="Prayer1"/>&#160;
  156.             </td>
  157.           </tr>
  158.           <tr>
  159.             <td class="borderDotTimeDuration">
  160.               [<xsl:value-of select="OpeningComments/Time/@EndTime24"/>]
  161.             </td>
  162.             <td class="borderDotTime">
  163.               <xsl:value-of select="OpeningComments/Time"/>
  164.             </td>
  165.             <td class="borderDotTheme" colspan="2">
  166.               <xsl:value-of select="OpeningComments/Theme"/>
  167.             </td>
  168.           </tr>
  169.           <tr>
  170.             <td class="cellComments" colspan="4">
  171.               <xsl:if test="normalize-space(ReviewQuestion) != ''">
  172.                 <span class="textReviewQuestionLabel">
  173.                   <xsl:value-of select="//Labels/ReviewQuestion"/>&#160;
  174.                 </span>
  175.                 <span class="textReviewQuestion">
  176.                   <xsl:value-of select="ReviewQuestion"/>
  177.                 </span>
  178.                 <br />
  179.               </xsl:if>
  180.               <br />
  181.               <br />
  182.             </td>
  183.           </tr>
  184.         </table>
  185.  
  186.       </xsl:if>
  187.  
  188.     </div>
  189.   </xsl:template>
  190.  
  191.   <!--Treasures from God's Word-->
  192.   <xsl:template name = "Display_TFGW" >
  193.     <xsl:param name = "Class" />
  194.     <div class="containerTFGW">
  195.       <table cellpadding="2" cellspacing="0"  class="tableOuter">
  196.         <tr>
  197.           <td class="textTFGW" colspan="4">
  198.             <xsl:value-of select="//Labels/TreasuresFromGodsWord"/>
  199.           </td>
  200.         </tr>
  201.  
  202.         <xsl:if test="$Class='M'">
  203.           <!--Bible discussion-->
  204.           <tr>
  205.             <td class="borderDotTimeDuration">
  206.               [<xsl:value-of select="Treasures1/Time/@EndTime24"/>]
  207.             </td>
  208.             <td class="borderDotTime">
  209.               <xsl:value-of select="Treasures1/Time"/>
  210.             </td>
  211.             <td class="borderDotTheme">
  212.               <xsl:value-of select="Treasures1/Theme" disable-output-escaping="yes"/>&#160;
  213.               <span class="textMethod">
  214.                 [<xsl:value-of select="Treasures1/Method" disable-output-escaping="yes"/>]
  215.               </span>
  216.             </td>
  217.             <td class="borderDotName">
  218.               <xsl:value-of select="Treasures1/Name"/>&#160;
  219.             </td>
  220.           </tr>
  221.  
  222.           <!--Digging for spiritual gems-->
  223.           <tr>
  224.             <td class="borderDotTimeDuration">
  225.               [<xsl:value-of select="Treasures2/Time/@EndTime24"/>]
  226.             </td>
  227.             <td class="borderDotTime">
  228.               <xsl:value-of select="Treasures2/Time"/>
  229.             </td>
  230.             <td class="borderDotTheme">
  231.               <xsl:value-of select="Treasures2/Theme" disable-output-escaping="yes"/>&#160;
  232.               <span class="textMethod">
  233.                 [<xsl:value-of select="Treasures2/Method" disable-output-escaping="yes"/>]
  234.               </span>
  235.             </td>
  236.             <td class="borderDotName" valign="top">
  237.               <xsl:value-of select="Treasures2/Name"/>&#160;
  238.             </td>
  239.           </tr>
  240.         </xsl:if>
  241.  
  242.         <!--Bible reading-->
  243.         <tr>
  244.           <td class="borderDotTimeDuration">
  245.             [<xsl:value-of select="BibleReadingTime/@EndTime24"/>]
  246.           </td>
  247.           <td class="borderDotTime">
  248.             <xsl:value-of select="BibleReadingTime"/>
  249.           </td>
  250.           <td class="borderDotTheme">
  251.             <xsl:value-of select="//Labels/BibleReading"/>&#160;
  252.             <span class="textMaterial">
  253.               [<xsl:value-of select="StudentSourceMaterial/BibleReadingMaterial"/>]
  254.             </span><br />
  255.             <xsl:value-of select="//Labels/CounselPoint"/>&#160;
  256.             <xsl:choose>
  257.               <xsl:when test="$Class='M'">
  258.                 <xsl:value-of select="BibleReadingM/@StudyPoint"/>&#160;
  259.                 <xsl:value-of select="BibleReadingM/@StudyPointDescription"/>
  260.               </xsl:when>
  261.               <xsl:when test="$Class='1'">
  262.                 <xsl:value-of select="BibleReading1/@StudyPoint"/>&#160;
  263.                 <xsl:value-of select="BibleReading1/@StudyPointDescription"/>
  264.               </xsl:when>
  265.               <xsl:when test="$Class='2'">
  266.                 <xsl:value-of select="BibleReading2/@StudyPoint"/>&#160;
  267.                 <xsl:value-of select="BibleReading2/@StudyPointDescription"/>
  268.               </xsl:when>
  269.             </xsl:choose>
  270.             <br />
  271.           </td>
  272.           <td class="borderDotName" valign="top">
  273.             <xsl:choose>
  274.               <xsl:when test="$Class='M'">
  275.                 <xsl:value-of select="BibleReadingM"/>&#160;
  276.               </xsl:when>
  277.               <xsl:when test="$Class='1'">
  278.                 <xsl:value-of select="BibleReading1"/>&#160;
  279.               </xsl:when>
  280.               <xsl:when test="$Class='2'">
  281.                 <xsl:value-of select="BibleReading2"/>&#160;
  282.               </xsl:when>
  283.             </xsl:choose>
  284.           </td>
  285.         </tr>
  286.         <tr>
  287.           <td class="cellComments" colspan="4">
  288.             <br />
  289.             <br />
  290.             <br />
  291.           </td>
  292.         </tr>
  293.       </table>
  294.     </div>
  295.   </xsl:template>
  296.  
  297.   <!--Apply Yourself To The Field Ministry-->
  298.   <xsl:template name = "Display_AYTFM" >
  299.     <xsl:param name = "Class" />
  300.     <div class="containerAYFM">
  301.       <table cellpadding="2" cellspacing="0"  class="tableOuter">
  302.         <tr>
  303.           <td class="textAYFM" colspan="4">
  304.             <xsl:value-of select="//Labels/ApplyYourselfToTheFieldMinistry"/>
  305.           </td>
  306.         </tr>
  307.  
  308.         <xsl:choose>
  309.           <!--Presentations-->
  310.           <xsl:when test="FirstWeekOfMonth=1">
  311.             <tr>
  312.               <td class="borderDotTimeDuration">
  313.                 [<xsl:value-of select="Presentations/Time/@EndTime24"/>]
  314.               </td>
  315.               <td class="borderDotTime">
  316.                 <xsl:value-of select="Presentations/Time"/>
  317.               </td>
  318.               <td class="borderDotTheme">
  319.                 <xsl:value-of select="Presentations/Theme" disable-output-escaping="yes"/>
  320.                 <br />
  321.                 <span class="textMethod">
  322.                   [<xsl:value-of select="Presentations/Method" disable-output-escaping="yes"/>]
  323.                 </span>
  324.               </td>
  325.               <td class="borderDotName">
  326.                 <xsl:value-of select="Presentations/Name"/>&#160;
  327.               </td>
  328.             </tr>
  329.           </xsl:when>
  330.           <!--Student talks-->
  331.           <xsl:otherwise>
  332.             <tr>
  333.               <td class="borderDotTimeDuration">
  334.                 [<xsl:value-of select="StudentTalk1Time/@EndTime24"/>]
  335.               </td>
  336.               <td class="borderDotTime">
  337.                 <xsl:value-of select="StudentTalk1Time"/>
  338.               </td>
  339.               <td class="borderDotTheme">
  340.                 <xsl:value-of select="StudentSourceMaterial/StudentTalk1Type"/><br />
  341.                 [<xsl:value-of select="StudentSourceMaterial/StudentTalk1Material" disable-output-escaping="yes"/>]<br />
  342.                 <xsl:value-of select="//Labels/CounselPoint"/>&#160;
  343.                 <xsl:choose>
  344.                   <xsl:when test="$Class='M'">
  345.                     <xsl:value-of select="StudentTalk1M/@StudyPoint"/>&#160;
  346.                     <xsl:value-of select="StudentTalk1M/@StudyPointDescription"/>
  347.                   </xsl:when>
  348.                   <xsl:when test="$Class='1'">
  349.                     <xsl:value-of select="StudentTalk11/@StudyPoint"/>&#160;
  350.                     <xsl:value-of select="StudentTalk11/@StudyPointDescription"/>
  351.                   </xsl:when>
  352.                   <xsl:when test="$Class='2'">
  353.                     <xsl:value-of select="StudentTalk12/@StudyPoint"/>&#160;
  354.                     <xsl:value-of select="StudentTalk12/@StudyPointDescription"/>
  355.                   </xsl:when>
  356.                 </xsl:choose>
  357.                 <br />
  358.               </td>
  359.               <td class="borderDotName">
  360.                 <xsl:choose>
  361.                   <xsl:when test="$Class='M'">
  362.                     <xsl:value-of select="StudentTalk1M"/>&#160;
  363.                   </xsl:when>
  364.                   <xsl:when test="$Class='1'">
  365.                     <xsl:value-of select="StudentTalk11"/>&#160;
  366.                   </xsl:when>
  367.                   <xsl:when test="$Class='2'">
  368.                     <xsl:value-of select="StudentTalk12"/>&#160;
  369.                   </xsl:when>
  370.                 </xsl:choose>
  371.                 <br />
  372.                 <br />
  373.                 <xsl:choose>
  374.                   <xsl:when test="$Class='M'">
  375.                     <xsl:value-of select="StudentTalk1MA"/>&#160;
  376.                   </xsl:when>
  377.                   <xsl:when test="$Class='1'">
  378.                     <xsl:value-of select="StudentTalk11A"/>&#160;
  379.                   </xsl:when>
  380.                   <xsl:when test="$Class='2'">
  381.                     <xsl:value-of select="StudentTalk12A"/>&#160;
  382.                   </xsl:when>
  383.                 </xsl:choose>
  384.               </td>
  385.             </tr>
  386.             <tr>
  387.               <td class="cellComments" colspan="4">
  388.                 <br />
  389.                 <br />
  390.                 <br />
  391.               </td>
  392.             </tr>
  393.             <tr>
  394.               <td class="borderDotTimeDuration">
  395.                 [<xsl:value-of select="StudentTalk2Time/@EndTime24"/>]
  396.               </td>
  397.               <td class="borderDotTime">
  398.                 <xsl:value-of select="StudentTalk2Time"/>
  399.               </td>
  400.               <td class="borderDotTheme">
  401.                 <xsl:value-of select="StudentSourceMaterial/StudentTalk2Type"/><br />
  402.                 [<xsl:value-of select="StudentSourceMaterial/StudentTalk2Material" disable-output-escaping="yes"/>]<br />
  403.                 <xsl:value-of select="//Labels/CounselPoint"/>&#160;
  404.                 <xsl:choose>
  405.                   <xsl:when test="$Class='M'">
  406.                     <xsl:value-of select="StudentTalk2M/@StudyPoint"/>&#160;
  407.                     <xsl:value-of select="StudentTalk2M/@StudyPointDescription"/>
  408.                   </xsl:when>
  409.                   <xsl:when test="$Class='1'">
  410.                     <xsl:value-of select="StudentTalk21/@StudyPoint"/>&#160;
  411.                     <xsl:value-of select="StudentTalk21/@StudyPointDescription"/>
  412.                   </xsl:when>
  413.                   <xsl:when test="$Class='2'">
  414.                     <xsl:value-of select="StudentTalk22/@StudyPoint"/>&#160;
  415.                     <xsl:value-of select="StudentTalk22/@StudyPointDescription"/>
  416.                   </xsl:when>
  417.                 </xsl:choose>
  418.                 <br />
  419.               </td>
  420.               <td class="borderDotName">
  421.                 <xsl:choose>
  422.                   <xsl:when test="$Class='M'">
  423.                     <xsl:value-of select="StudentTalk2M"/>&#160;
  424.                   </xsl:when>
  425.                   <xsl:when test="$Class='1'">
  426.                     <xsl:value-of select="StudentTalk21"/>&#160;
  427.                   </xsl:when>
  428.                   <xsl:when test="$Class='2'">
  429.                     <xsl:value-of select="StudentTalk22"/>&#160;
  430.                   </xsl:when>
  431.                 </xsl:choose>
  432.                 <br />
  433.                 <br />
  434.                 <xsl:choose>
  435.                   <xsl:when test="$Class='M'">
  436.                     <xsl:value-of select="StudentTalk2MA"/>&#160;
  437.                   </xsl:when>
  438.                   <xsl:when test="$Class='1'">
  439.                     <xsl:value-of select="StudentTalk21A"/>&#160;
  440.                   </xsl:when>
  441.                   <xsl:when test="$Class='2'">
  442.                     <xsl:value-of select="StudentTalk22A"/>&#160;
  443.                   </xsl:when>
  444.                 </xsl:choose>
  445.               </td>
  446.             </tr>
  447.             <tr>
  448.               <td class="cellComments" colspan="4">
  449.                 <br />
  450.                 <br />
  451.                 <br />
  452.               </td>
  453.             </tr>
  454.             <tr>
  455.               <td class="borderDotTimeDuration">
  456.                 [<xsl:value-of select="StudentTalk3Time/@EndTime24"/>]
  457.               </td>
  458.               <td class="borderDotTime">
  459.                 <xsl:value-of select="StudentTalk3Time"/>
  460.               </td>
  461.               <td class="borderDotTheme">
  462.                 <xsl:value-of select="StudentSourceMaterial/StudentTalk3Type"/><br />
  463.                 [<xsl:value-of select="StudentSourceMaterial/StudentTalk3Material" disable-output-escaping="yes"/>]<br />
  464.                 <xsl:value-of select="//Labels/CounselPoint"/>&#160;
  465.                 <xsl:choose>
  466.                   <xsl:when test="$Class='M'">
  467.                     <xsl:value-of select="StudentTalk3M/@StudyPoint"/>&#160;
  468.                     <xsl:value-of select="StudentTalk3M/@StudyPointDescription"/>
  469.                   </xsl:when>
  470.                   <xsl:when test="$Class='1'">
  471.                     <xsl:value-of select="StudentTalk31/@StudyPoint"/>&#160;
  472.                     <xsl:value-of select="StudentTalk31/@StudyPointDescription"/>
  473.                   </xsl:when>
  474.                   <xsl:when test="$Class='2'">
  475.                     <xsl:value-of select="StudentTalk32/@StudyPoint"/>&#160;
  476.                     <xsl:value-of select="StudentTalk32/@StudyPointDescription"/>
  477.                   </xsl:when>
  478.                 </xsl:choose>
  479.                 <br />
  480.               </td>
  481.               <td class="borderDotName">
  482.                 <xsl:choose>
  483.                   <xsl:when test="$Class='M'">
  484.                     <xsl:value-of select="StudentTalk3M"/>&#160;
  485.                   </xsl:when>
  486.                   <xsl:when test="$Class='1'">
  487.                     <xsl:value-of select="StudentTalk31"/>&#160;
  488.                   </xsl:when>
  489.                   <xsl:when test="$Class='2'">
  490.                     <xsl:value-of select="StudentTalk32"/>&#160;
  491.                   </xsl:when>
  492.                 </xsl:choose>
  493.                 <xsl:if test="StudentSourceMaterial/StudentTalk3Type/@IsTalk=0">
  494.                   <br />
  495.                   <br />
  496.                   <xsl:choose>
  497.                     <xsl:when test="$Class='M'">
  498.                       <xsl:value-of select="StudentTalk3MA"/>&#160;
  499.                     </xsl:when>
  500.                     <xsl:when test="$Class='1'">
  501.                       <xsl:value-of select="StudentTalk31A"/>&#160;
  502.                     </xsl:when>
  503.                     <xsl:when test="$Class='2'">
  504.                       <xsl:value-of select="StudentTalk32A"/>&#160;
  505.                     </xsl:when>
  506.                   </xsl:choose>
  507.                 </xsl:if>
  508.               </td>
  509.             </tr>
  510.             <tr>
  511.               <td class="cellComments" colspan="4">
  512.                 <br />
  513.                 <br />
  514.                 <br />
  515.               </td>
  516.             </tr>
  517.  
  518.           </xsl:otherwise>
  519.         </xsl:choose>
  520.       </table>
  521.     </div>
  522.   </xsl:template>
  523.  
  524.   <!--Apply Yourself To The Field Ministry-->
  525.   <xsl:template name = "Display_LAC" >
  526.     <div class="containerLAC">
  527.       <table cellpadding="2" cellspacing="0"  class="tableOuter">
  528.         <tr>
  529.           <td class="textLAC" colspan="4">
  530.             <xsl:value-of select="//Labels/LivingAsChristians"/>
  531.           </td>
  532.         </tr>
  533.         <tr>
  534.           <td class="borderDotTimeDuration">
  535.             [<xsl:value-of select="SongMiddle/@EndTime24"/>]
  536.           </td>
  537.           <td class="borderDotTime">
  538.             <xsl:value-of select="//Labels/SongDuration"/>
  539.           </td>
  540.           <td class="borderDotTheme" colspan="2">
  541.             <xsl:value-of select="//Labels/Song"/>&#160;
  542.             <xsl:value-of select="SongMiddle"/>&#160;
  543.             <span class="textSongTitle">
  544.               <xsl:value-of select="SongMiddle/@Title"/>
  545.             </span>
  546.           </td>
  547.         </tr>
  548.         <tr>
  549.           <td class="borderDotTimeDuration">
  550.             [<xsl:value-of select="LivingAsChristians/Item1/Time/@EndTime24"/>]
  551.           </td>
  552.           <td class="borderDotTime">
  553.             <xsl:value-of select="LivingAsChristians/Item1/Time"/>
  554.           </td>
  555.           <td class="borderDotTheme">
  556.             <xsl:value-of select="LivingAsChristians/Item1/Theme" disable-output-escaping="yes"/>&#160;
  557.             <span class="textMethod">
  558.               [<xsl:value-of select="LivingAsChristians/Item1/Method" disable-output-escaping="yes"/>]
  559.             </span>
  560.             <xsl:call-template name="Display_DemoInfo">
  561.               <xsl:with-param name="Item" select="LivingAsChristians/Item1"/>
  562.             </xsl:call-template>
  563.           </td>
  564.           <td class="borderDotName">
  565.             <xsl:value-of select="LivingAsChristians/Item1/Name"/>&#160;
  566.           </td>
  567.         </tr>
  568.         <xsl:if test="LivingAsChristians/@ItemCount=2">
  569.           <tr>
  570.             <td class="borderDotTimeDuration">
  571.               [<xsl:value-of select="LivingAsChristians/Item2/Time/@EndTime24"/>]
  572.             </td>
  573.             <td class="borderDotTime">
  574.               <xsl:value-of select="LivingAsChristians/Item2/Time"/>
  575.             </td>
  576.             <td class="borderDotTheme">
  577.               <xsl:value-of select="LivingAsChristians/Item2/Theme" disable-output-escaping="yes"/>&#160;
  578.               <span class="textMethod">
  579.                 [<xsl:value-of select="LivingAsChristians/Item2/Method" disable-output-escaping="yes"/>]
  580.               </span>
  581.               <xsl:call-template name="Display_DemoInfo">
  582.                 <xsl:with-param name="Item" select="LivingAsChristians/Item2"/>
  583.               </xsl:call-template>
  584.             </td>
  585.             <td class="borderDotName">
  586.               <xsl:value-of select="LivingAsChristians/Item2/Name"/>&#160;
  587.             </td>
  588.           </tr>
  589.         </xsl:if>
  590.         <xsl:choose>
  591.           <!--We include the congregation bible study information and the review-->
  592.           <xsl:when test="CircuitVisit=0">
  593.             <tr>
  594.               <td class="borderDotTimeDuration">
  595.                 [<xsl:value-of select="LivingAsChristians/CongregationBibleStudy/Time/@EndTime24"/>]
  596.               </td>
  597.               <td class="borderDotTime">
  598.                 <xsl:value-of select="LivingAsChristians/CongregationBibleStudy/Time"/>
  599.               </td>
  600.               <td class="borderDotTheme">
  601.                 <xsl:value-of select="//Labels/CongregationBibleStudy"/>&#160;
  602.                 <span class="textCongregationBibleStudyMaterial">
  603.                   [<xsl:value-of select="LivingAsChristians/CongregationBibleStudy/SourceMaterial" disable-output-escaping="yes"/>]
  604.                 </span><br />
  605.                 <xsl:value-of select="//Labels/CBSReader"/>:&#160;<xsl:value-of select="LivingAsChristians/CongregationBibleStudy/Reader"/>
  606.               </td>
  607.               <td class="borderDotName">
  608.                 <xsl:value-of select="LivingAsChristians/CongregationBibleStudy/Conductor"/>&#160;
  609.               </td>
  610.             </tr>
  611.             <tr>
  612.               <td class="borderDotTimeDuration">
  613.                 [<xsl:value-of select="ClosingComments/Time/@EndTime24"/>]
  614.               </td>
  615.               <td class="borderDotTime">
  616.                 <xsl:value-of select="ClosingComments/Time"/>
  617.               </td>
  618.               <td class="borderDotTheme" colspan="2">
  619.                 <xsl:value-of select="ClosingComments/Theme"/>
  620.               </td>
  621.             </tr>
  622.             <tr>
  623.               <td class="cellComments" colspan="4">
  624.                 <xsl:variable name="AssignHistory" select="document('AssignHistory.xml')"/>
  625.                 <xsl:variable name="week" select="Date/@NextWeek"/>
  626.                 <xsl:variable name="NextReviewQuestion" select="$AssignHistory/AssignmentHistory/*[name()=$week]/ReviewQuestion"/>
  627.                 <xsl:if test="normalize-space($NextReviewQuestion) != ''">
  628.                   <xsl:if test="normalize-space(ReviewQuestion) != ''">
  629.                     <span class="textReviewQuestionLabel">
  630.                       <xsl:value-of select="//Labels/NextReviewQuestion"/>&#160;
  631.                     </span>
  632.                     <span class="textReviewQuestion">
  633.                       <xsl:value-of select="$NextReviewQuestion"/>
  634.                     </span>
  635.                     <br />
  636.                   </xsl:if>
  637.                 </xsl:if>
  638.                 <br />
  639.                 <br />
  640.                 <br />
  641.               </td>
  642.             </tr>
  643.           </xsl:when>
  644.           <!--We include the review and the circuit overseer talk-->
  645.           <xsl:otherwise>
  646.             <tr>
  647.               <td class="borderDotTimeDuration">
  648.                 [<xsl:value-of select="ClosingComments/Time/@EndTime24"/>]
  649.               </td>
  650.               <td class="borderDotTime">
  651.                 <xsl:value-of select="ClosingComments/Time"/>
  652.               </td>
  653.               <td class="borderDotTheme" colspan="2">
  654.                 <xsl:value-of select="ClosingComments/Theme"/>
  655.               </td>
  656.             </tr>
  657.             <tr>
  658.               <td class="cellComments" colspan="4">
  659.                 <xsl:variable name="AssignHistory" select="document('AssignHistory.xml')"/>
  660.                 <xsl:variable name="week" select="Date/@NextWeek"/>
  661.                 <xsl:variable name="NextReviewQuestion" select="$AssignHistory/AssignmentHistory/*[name()=$week]/ReviewQuestion"/>
  662.                 <xsl:if test="normalize-space($NextReviewQuestion) != ''">
  663.                   <span class="textReviewQuestionLabel">
  664.                     <xsl:value-of select="//Labels/NextReviewQuestion"/>&#160;
  665.                   </span>
  666.                   <span class="textReviewQuestion">
  667.                     <xsl:value-of select="$NextReviewQuestion"/>
  668.                   </span>
  669.                   <br />
  670.                 </xsl:if>
  671.                 <br />
  672.                 <br />
  673.               </td>
  674.             </tr>
  675.             <tr>
  676.               <td class="borderDotTimeDuration">
  677.                 [<xsl:value-of select="LivingAsChristians/ItemCircuitOverseer/Time/@EndTime24"/>]
  678.               </td>
  679.               <td class="borderDotTime">
  680.                 <xsl:value-of select="LivingAsChristians/ItemCircuitOverseer/Time"/>
  681.               </td>
  682.               <td class="borderDotTheme">
  683.                 <xsl:value-of select="LivingAsChristians/ItemCircuitOverseer/Theme" disable-output-escaping="yes"/>&#160;
  684.                 <span class="textMethod">
  685.                   [<xsl:value-of select="LivingAsChristians/ItemCircuitOverseer/Method" disable-output-escaping="yes"/>]
  686.                 </span>
  687.               </td>
  688.               <td class="borderDotName">
  689.                 <xsl:value-of select="LivingAsChristians/ItemCircuitOverseer/Name"/>&#160;
  690.               </td>
  691.             </tr>
  692.           </xsl:otherwise>
  693.         </xsl:choose>
  694.         <tr>
  695.           <td class="borderDotTimeDuration">
  696.             [<xsl:value-of select="SongEnd/@EndTime24"/>]
  697.           </td>
  698.           <td class="borderDotTime">
  699.             <xsl:value-of select="//Labels/SongDuration"/>
  700.           </td>
  701.           <td class="borderDotTheme">
  702.             <span class="floatTextLeft">
  703.               <xsl:value-of select="//Labels/Song"/>&#160;
  704.               <xsl:value-of select="SongEnd"/>&#160;
  705.               <span class="textSongTitle">
  706.                 <xsl:value-of select="SongEnd/@Title"/>
  707.               </span>
  708.             </span>
  709.             <span class="floatTextRight">
  710.               <xsl:value-of select="//Labels/Prayer"/>
  711.             </span>
  712.           </td>
  713.           <td class="borderDotName">
  714.             <xsl:value-of select="Prayer2"/>&#160;
  715.           </td>
  716.         </tr>
  717.       </table>
  718.     </div>
  719.   </xsl:template>
  720.  
  721.   <xsl:template name="Display_DemoInfo">
  722.     <xsl:param name="Item" />
  723.  
  724.     <xsl:if test="$Item/DemoInfo/@ItemCount &gt;= 1">
  725.  
  726.       <xsl:for-each select="$Item/DemoInfo/Demo">
  727.         <xsl:choose>
  728.           <xsl:when test="@InsertNewLine=1">
  729.             <span class="textDemoNewlinePrefix">
  730.               <br />
  731.             </span>
  732.             <span class="textDemoBracket">[</span>
  733.             <span class="textDemoDescription">
  734.               <xsl:value-of select="@Type"/>:&#160;
  735.             </span>
  736.           </xsl:when>
  737.           <xsl:otherwise>
  738.             <span class="textDemoComma">,&#160;</span>
  739.           </xsl:otherwise>
  740.         </xsl:choose>
  741.  
  742.         <xsl:if test="normalize-space(Prefix) != ''">
  743.           <span class="textDemoPrefix">
  744.             <xsl:value-of select="Prefix"/>&#160;
  745.           </span>
  746.         </xsl:if>
  747.  
  748.         <xsl:if test ="@ParticipantCount &gt;= 1">
  749.           <span class="textDemoBrother">
  750.             <xsl:value-of select="Participant1/Name"/>
  751.           </span>
  752.         </xsl:if>
  753.  
  754.         <xsl:if test ="@ParticipantCount &gt;= 2">
  755.           <xsl:choose>
  756.             <xsl:when test="Participant2/Task = Participant1/Task">
  757.               <span class="textDemoSlash">&#160;/&#160;</span>
  758.             </xsl:when>
  759.             <xsl:otherwise>
  760.               <span class="textDemoHyphen">&#160;-&#160;</span>
  761.             </xsl:otherwise>
  762.           </xsl:choose>
  763.  
  764.           <span class="textDemoBrother">
  765.             <xsl:value-of select="Participant2/Name"/>
  766.           </span>
  767.         </xsl:if>
  768.  
  769.         <xsl:if test ="@ParticipantCount &gt;= 3">
  770.           <xsl:choose>
  771.             <xsl:when test="Participant3/Task = Participant2/Task">
  772.               <span class="textDemoSlash">&#160;/&#160;</span>
  773.             </xsl:when>
  774.             <xsl:otherwise>
  775.               <span class="textDemoHyphen">&#160;-&#160;</span>
  776.             </xsl:otherwise>
  777.           </xsl:choose>
  778.  
  779.           <span class="textDemoBrother">
  780.             <xsl:value-of select="Participant3/Name"/>
  781.           </span>
  782.         </xsl:if>
  783.         <xsl:if test ="@ParticipantCount &gt;= 4">
  784.           <xsl:choose>
  785.             <xsl:when test="Participant4/Task = Participant3/Task">
  786.               <span class="textDemoSlash">&#160;/&#160;</span>
  787.             </xsl:when>
  788.             <xsl:otherwise>
  789.               <span class="textDemoHyphen">&#160;-&#160;</span>
  790.             </xsl:otherwise>
  791.           </xsl:choose>
  792.  
  793.           <span class="textDemoBrother">
  794.             <xsl:value-of select="Participant4/Name"/>
  795.           </span>
  796.         </xsl:if>
  797.         <span class="textDemoBracket">]</span>
  798.       </xsl:for-each>
  799.     </xsl:if>
  800.  
  801.   </xsl:template>
  802.  
  803. </xsl:stylesheet>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement