<?xml version="1.0" encoding="ISO-8859-1"?> 
  <!-- Changed by: D.K.S., 05-Jun-1999
  - Only print results, a quick hack from project.xsl
 -->

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">

 <xsl:output method="html" indent="no"/>


 <!--- doesn't work here
  <xsl:stylesheet 
  xmlns:xsl="http://www.w3.org/TR/WD-xsl"
  xmlns="http://www.w3.org/TR/REC-html40"
  result-ns=""
  -->

  <!-- Root xsl:template - start processing here -->
  <xsl:template match="/">
    <HTML>
      <HEAD>
        <TITLE>
	  <xsl:value-of select="//project/title"/>
	</TITLE>

<STYLE TYPE="text/css"> 

BODY {
     background-color:white;
     	}
	

H1, H2, H3, H4, H5 {
	color: rgb(0,33,99);
	font-family:helvetica,arial,sans-serif;}

H1 {
	font-size:24pt;
	border-style:double;
	border-width:thin;
	border-color:rgb(0,33,99);
	font-weight:bold;
	padding:3;
	margin-right:0pt;
	}
H2 {
	font-size:20pt;}
H3 {
	font-size:18pt;
	}
</STYLE>

      </HEAD>


<BODY>
     <xsl:apply-templates/>
</BODY>

</HTML>

</xsl:template>

  
   <xsl:template match="project">
      
  <xsl:apply-templates select="title"/>
  <xsl:apply-templates select="planning"/>
  <xsl:apply-templates select="group"/>
  <xsl:apply-templates select="results"/>
  <xsl:apply-templates select="teacher-comments"/>

     
  </xsl:template>

   <xsl:template match="project/title">
     <h1>
          [ <xsl:value-of select="//project/@id"/> ]
          <xsl:value-of select="."/>
   </h1>
    <p> Un project <A HREF="http://tecfa.unige.ch/tecfa/teaching/staf18/staf18-overview.html">Staf-18</A> (promotion EVA 1998/2000).	  </p>
  </xsl:template>


   <xsl:template match="planning">
     <table border="1">
       <tr>
	 <th align="right">Début du projet:</th>
	 <td><xsl:value-of select="@start-day"/>/
	       <xsl:value-of select="@start-month"/>/
		 <xsl:value-of select="@start-year"/>. 
	 </td>
       </tr>
       <tr>
	 <th align="right">Fin du projet:</th>
	 <td>
	 <xsl:value-of select="@end-day"/>/
	   <xsl:value-of select="@end-month"/>/
	     <xsl:value-of select="@end-year"/>.
       	 </td>
       </tr>
       <tr>
	 <th align="right">Estimation du travail:</th>
	 <td><xsl:value-of select="@man-days"/> jours </td>
       </tr>
       <tr>
	 <th align="right">Avancement:</th>
         <td><xsl:value-of select="@completion"/>%.</td>
       </tr>
     </table>
  </xsl:template>


   <!-- ****************************** Participants ******************** -->

   <xsl:template match="group">
     <h1><a name="parti_{//project/@id}">1. Participants</a> </h1>
     <xsl:apply-templates/> 
  </xsl:template>


   <xsl:template match="person">
     <h2>Participant </h2>
     <xsl:apply-templates/> 
  </xsl:template>


   <xsl:template match="contact-info">
     <table border="1">
       <tr>
	 <th align="right">Prénom et Nom:</th>
	 <td><xsl:value-of select="./@first-name"/> - 
	       <xsl:value-of select="@family-name"/>
	 </td>
       </tr>
       <tr>
	 <th align="right">LDAP:</th>
	 <td>
         <!-- Alternative ?
         ldap://tecfa2.unige.ch/o=tecfa.unige.ch?cn,labeledUri,mail?sub?(&(uid=delhom)(ou=staf))
         -->
	 <a href="ldap://{../ldap-id/@host}/{../ldap-id/@dn}"><xsl:value-of select="../ldap-id/@dn"/></a>
       	 </td>
       </tr>
       <tr>
	 <th align="right">Email:</th>
	 <td>
	 <a href="mailto:{@email}"><xsl:value-of select="@email"/></a>
       	 </td>
       </tr>
       <tr>
	 <th align="right">URLs:</th>
         <td>
	 <a href="{@home-url}">home</a> -
	 <a href="{@work-url}">work</a>
         </td>
       </tr>
     </table>


  </xsl:template>



   <!-- ****************************** Specifications ******************** -->


   <xsl:template match="specification">
     <h1><a name="specs_{//project/@id}">2. Specification  <xsl:value-of select="@version"/></a> </h1>
     <xsl:apply-templates/> 

  </xsl:template>


   <xsl:template match="main-goal">
     <xsl:apply-templates/> 
  </xsl:template>

   <xsl:template match="main-goal/title">
     <h3>But principal: <xsl:apply-templates/></h3>
  </xsl:template>

  <xsl:template match="main-goal/teacher-comments">
    <H4>Commentaires de l'enseignant sur le but principal</H4>

    <table width="100%" border="1">
      <xsl:apply-templates/>
    </table>
  </xsl:template>


<!-- **** Objectives **** -->

   <xsl:template match="objectives">
     <h3>Objectifs et/ou questions de recherche (objectives)</h3>
     <xsl:apply-templates/> 
  </xsl:template>

   <xsl:template match="goal">
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>

   <xsl:template match="goal/title">
     <tr><th>But</th> <th><xsl:apply-templates/></th></tr>
  </xsl:template>

   <xsl:template match="goal/content">
     <tr><td align="right">détails:</td> <td> <xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="goal/after-thoughts">
     <tr><td>Auto Critique:</td> <td> <xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="objectives/teacher-comments">
     <H4>Commentaire de l'enseignant sur les objectifs</H4>
     <table width="100%" border="1">     
     <xsl:apply-templates/>
    </table>
  </xsl:template>


<!-- **** context **** -->


   <xsl:template match="context">
     <h3>Contexte</h3>
     <xsl:apply-templates/> 
  </xsl:template>


<!-- **** Workpackages **** -->


 <xsl:template match="workpackages">
   <h3>Workpackages</h3>
   <xsl:apply-templates/> 


  </xsl:template>

   <xsl:template match="workpackage">
   <!--
     <a name="{@id}"><xsl:value-of select="@id"/></a>
     -->
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>

   <xsl:template match="workpackage/title">
      <tr>
      <th bgcolor="#66FFFF">WP     
         <!--
         REPARER ce truc !
         <xsl:number level="any" from="workpackages" format="(1) "/>
         -->
      </th>
      <th bgcolor="#66FFFF">
	  <xsl:apply-templates/>
         [ <a name="{../@id}"><xsl:value-of select="../@id"/></a> ]
     </th>
      </tr>		
  </xsl:template>

   <xsl:template match="workpackage/planning">
     <tr><td bgcolor="#66FFFF">Planning:</td>
     <td bgcolor="#66FFFF">
     Start: <xsl:value-of select="@start-day"/>/
     <xsl:value-of select="@start-month"/>/
     <xsl:value-of select="@start-year"/>. 
     End: <xsl:value-of select="@end-day"/>/
     <xsl:value-of select="@end-month"/>/
     <xsl:value-of select="@end-year"/>.
     Estimation du travail: <xsl:value-of select="@man-days"/> jours.
     Avancement:  <xsl:value-of select="@completion"/>%.
     </td>
     </tr>
  </xsl:template>


   <xsl:template match="workpackage/content">
     <tr><td bgcolor="#66FFFF">A faire:</td> <td bgcolor="#66FFFF">
     <xsl:apply-templates/></td></tr>
  </xsl:template>


   <xsl:template match="workpackage/misc-info">
     <tr><td bgcolor="#66FFFF">Infos diverses:</td> <td bgcolor="#66FFFF"> <xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="workpackage/after-thoughts">
     <tr><td bgcolor="#66FFFF">Auto Critique:</td> <td bgcolor="#66FFFF"> <xsl:apply-templates/></td></tr>
  </xsl:template>


 <xsl:template match="workpackage/teacher-comments">
   <tr><th colspan="2" bgcolor="#FFFFCC">Commentaires de l'enseignant et répliques</th></tr>
     <xsl:apply-templates/> 
  </xsl:template>


   <xsl:template match="workpackages/teacher-comments">
     <H4>Commentaires de l'enseignant sur l'ensemble des workpackages</H4>

    <table width="100%" border="1">
      <xsl:apply-templates/>
    </table>
  </xsl:template>

<!-- audits -->

   <xsl:template match="workpackages/audits">
     <H4>Audits de l'ensemble des workpackages</H4>

    <table width="100%" border="1">
      <xsl:apply-templates/>
    </table>
  </xsl:template>


   <xsl:template match="audit/title">
     <tr><td bgcolor="#3366FF">
     <strong>Audit:</strong>
      <xsl:value-of select="../@eval"/>
</td>
         <td bgcolor="#3366FF"><xsl:apply-templates/></td></tr>
  </xsl:template>


   <xsl:template match="audit/content">
     <tr><td bgcolor="#3366FF"> 
      <xsl:value-of select="../@mod-day"/>/
	 <xsl:value-of select="../@mod-month"/>/
	 <xsl:value-of select="../@mod-year"/>
 </td> <td bgcolor="#3366FF">
     <xsl:apply-templates/></td></tr>
  </xsl:template>



<!-- **** stories **** -->

 <xsl:template match="stories">
     <h3>Récits (stories)</h3>

     <xsl:apply-templates/> 

  </xsl:template>

   <xsl:template match="story/teacher-comments">
     <table width="100%" border="1">
     <xsl:apply-templates/>
    </table>
  </xsl:template>


   <xsl:template match="stories/teacher-comments">
     <H4>Commentaire de l'enseignant sur l'ensemble des récits</H4>
     <table width="100%" border="1">
     <xsl:apply-templates/>
    </table>
  </xsl:template>



<!-- **** Deliverables **** -->

 <xsl:template match="deliverables">
     <h3>Choses promises (deliverables)</h3>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>


   <xsl:template match="deliverable/title">
     <tr><th>Item</th> <th><xsl:apply-templates/></th></tr>
  </xsl:template>


   <xsl:template match="deliverable/content">
     <tr><td>Précisions:</td> <td> <xsl:apply-templates/></td></tr>
  </xsl:template>


   <xsl:template match="deliverable/misc-info">
     <tr><td>Infos diverses:</td> <td> <xsl:apply-templates/></td></tr>
  </xsl:template>


   <xsl:template match="deliverable/after-thoughts">
     <tr><td>Auto Critique:</td> <td> <xsl:apply-templates/></td></tr>
  </xsl:template>


<!-- ***************** Problems ************* -->


<!-- at Specification Level **** -->

 <xsl:template match="specification/problems">
     <h3>Problèmes avec la spécification</h3>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>


 <xsl:template match="project/problems">
     <h3>Problèmes avec le projet (niveau très général)</h3>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>

 <xsl:template match="workpackage/problems">
   <tr><th colspan="2" bgcolor="#FF3300">Problèmes</th></tr>
     <xsl:apply-templates/> 
  </xsl:template>


<!--- for all problems -->

   <xsl:template match="problem/title">
     <tr><th bgcolor="#FF3300"><br>Problème:
        <xsl:value-of select="../@problem-status"/>
     </br>Mod:
        <xsl:value-of select="../@mod-day"/>/
	 <xsl:value-of select="../@mod-month"/>/
	 <xsl:value-of select="../@mod-year"/>
    </th> 
    <th bgcolor="#FF3300"><xsl:apply-templates/></th></tr>
  </xsl:template>


   <xsl:template match="problem/content">
     <tr><td bgcolor="#FF3300">Précisions:</td> <td bgcolor="#FF3300"> <xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="problem/solution">
     <tr><td bgcolor="#FF3300">Solution:</td> <td bgcolor="#FF3300"> <xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="problem/misc-info">
     <tr><td bgcolor="#FF3300">Infos diverses:</td> <td bgcolor="#FF3300"> <xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="problem/after-thoughts">
     <tr><td bgcolor="#FF3300">Auto Critique:</td> <td bgcolor="#FF3300"> <xsl:apply-templates/></td></tr>
  </xsl:template>


<!-- ***************** Resources ************* -->


 <xsl:template match="resources">
     <h2>Ressources générales</h2>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>


<!-- at Specification Level **** -->

 <xsl:template match="specification/resources">
     <h3>Ressources niveau spécifications</h3>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>


   <xsl:template match="resource/title">
     <tr><th>Item</th> <th><xsl:apply-templates/></th></tr>
  </xsl:template>


   <xsl:template match="resource/content">
     <tr><td>Précisions:</td> <td> <xsl:apply-templates/></td></tr>
  </xsl:template>


   <xsl:template match="resource/after-thoughts">
     <tr><td>Auto Critique:</td> <td> <xsl:apply-templates/></td></tr>
  </xsl:template>



<!-- ******** Teacher comments  pour les spec********* -->


   <xsl:template match="specification/teacher-comments">
     <h3>Les commentaires de l'enseignant sur la spécification</h3>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>


<!-- ****************************** Results ******************** -->


 <xsl:template match="results">
     <h1><a name="resul_{//project/@id}">3. Résultats</a></h1>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>


   <xsl:template match="result/title">
     <tr><th bgcolor="#99CC33">Résultat</th> <th bgcolor="#99CC33"><xsl:apply-templates/></th></tr>
  </xsl:template>


   <xsl:template match="result/content">
     <tr><td bgcolor="#99CC33">Précisions:</td> <td bgcolor="#99CC33"> <xsl:apply-templates/></td></tr>
  </xsl:template>


   <xsl:template match="result/after-thoughts">
     <tr><td bgcolor="#99CC33">Auto Critique:</td> <td bgcolor="#99CC33"> <xsl:apply-templates/></td></tr>
  </xsl:template>


 <xsl:template match="outlook">
     <h1>3. Outlook (perspectives)</h1>
     <xsl:apply-templates/> 
  </xsl:template>


<!-- ******** Teacher comments pour l'ensemble ********* -->

   <xsl:template match="project/teacher-comments">
     <h1>4. Les commentaires de l'enseignant sur l'ensemble</h1>
     <table width="100%" border="1">
     <xsl:apply-templates/> 
     </table>
  </xsl:template>


<!-- ****************************** Common Items ******************** -->


  <xsl:template match="teacher-comment">
     <tr><td bgcolor="#FFFFCC"><br>Enseignant:</br>
         <xsl:value-of select="@mod-day"/>/
	 <xsl:value-of select="@mod-month"/>/
	 <xsl:value-of select="@mod-year"/> </td>
     <td bgcolor="#FFFFCC"><xsl:apply-templates/></td></tr>
  </xsl:template>

  <xsl:template match="student-answer">
     <tr><td bgcolor="#FFFFEE"><br>Etudiant:</br>
         <xsl:value-of select="@mod-day"/>/
	 <xsl:value-of select="@mod-month"/>/
	 <xsl:value-of select="@mod-year"/> </td>
     <td bgcolor="#FFFFEE"><xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="evaluation">
     <tr><td bgcolor="#996699">Evaluation:</td> <td bgcolor="#996699"> <xsl:apply-templates/></td></tr>
  </xsl:template>

   <xsl:template match="mark">
   <p>
     Note = <xsl:apply-templates/>
   </p>
  </xsl:template>

   <xsl:template match="a[@href]">
     <a href="{@href}"><xsl:value-of select="."/></a>
  </xsl:template>

   <xsl:template match="a[@idref]">
     <a href="#{@idref}"><xsl:value-of select="."/></a>
  </xsl:template>

<!--

   <xsl:template match="*/[@id]">
     <a name="BLABLA{@id}"><xsl:value-of select="@id"/></a>
  </xsl:template>

   <xsl:template match="*/[@id]">
     <a name="BLABLA{./[@id]}"><xsl:value-of select="./@id"/></a>
  </xsl:template>


   <xsl:template match="@id">
     <a name="{./@id}"><xsl:value-of select="./@id"/></a>
  </xsl:template>
-->

   <xsl:template match="content">
     <xsl:apply-templates/>
  </xsl:template>

   <xsl:template match="title">
     <p><strong><xsl:apply-templates/></strong></p>
  </xsl:template>

   <xsl:template match="para">
     <p><xsl:apply-templates/></p>
  </xsl:template>

   <xsl:template match="item">
     <ul><li><xsl:apply-templates/></li></ul>
  </xsl:template>

   <xsl:template match="list[@type='ol']">
     <ol><xsl:apply-templates/></ol>
  </xsl:template>

   <xsl:template match="list[@type='ul']">
     <ul><xsl:apply-templates/></ul>
  </xsl:template>

   <xsl:template match="list/item">
     <li><xsl:apply-templates/></li>
  </xsl:template>

</xsl:stylesheet> 

