]> SALOME platform Git repositories - tools/sat.git/blob - src/xsl/command.xsl
Salome HOME
Pour résoudre un conflit entre les branches master et Windows.
[tools/sat.git] / src / xsl / command.xsl
1 <?xml version="1.0" encoding="utf-8"?>
2 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
3 <xsl:output method="html" /> <!-- encoding="utf-8" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/>-->
4 <xsl:template match="/">
5
6 <head>  
7       <title>SAlomeTools log</title>
8       <style type="text/css">
9           table       { width : 100%;
10                         margin:1px;
11                         padding:1px;
12                         border-collapse:collapse;
13                         empty-cells : show;
14                       }
15           td          { vertical-align : center; padding: 15px; }
16           h1          { text-align : center; }
17           .legend     { font-weight : bold;
18                         text-align : center;
19                       } 
20           .def        { font-family: Arial, Verdana, "Times New Roman", Times, serif;}
21           hr.note     { color: #BFBFBF; }
22           .note       { text-align : right; font-style: italic; font-size: small; }
23           div.release { -moz-column-count: 2;
24                         overflow: auto;
25                         max-height: 250px;
26                       }
27           .OK2        { color:#00AA00; }
28           .KO2        { color:#FF0000; }
29       </style>
30       <script language="JavaScript"><![CDATA[
31             function Toggle(id) {
32               var element = document.getElementById(id);
33
34               if ( element.style.display == "none" )
35                   element.style.display = "block";
36               else 
37                   element.style.display = "none";
38             }
39           ]]>
40       </script>
41 </head>
42         <body class="def" bgcolor="aliceblue">
43                 <h1><img src="LOGO-SAT.png"/></h1>
44                 <table border="1">
45                         <tr>
46                                 <xsl:for-each select="SATcommand/Site/@*">
47                                         <td bgcolor="LightBlue">
48                                                 <b><xsl:value-of select="name(.)"/></b>
49                                         </td>
50                                 </xsl:for-each>
51                         </tr>
52                         <tr>
53                                 <xsl:for-each select="SATcommand/Site/@*">      
54                                         <td bgcolor="Beige"><xsl:value-of select="."/></td>
55                                 </xsl:for-each>
56                         </tr>
57                 </table>
58                 
59                 <h1>command's internal traces
60                 <a href="#">
61                       <xsl:attribute name="onclick">javascript:Toggle('log')</xsl:attribute>
62                       <xsl:attribute name="title">Click to expand or collapse the command log</xsl:attribute>
63                       expand / collapse
64                 </a>
65                 </h1>
66                 
67                 <div style="display:none"><xsl:attribute name="id">log</xsl:attribute>
68                     <PRE><xsl:value-of select="SATcommand/Log"/></PRE>
69                 </div>
70                 
71                 <h1>Links</h1>
72                 <table border="1">
73                         <xsl:for-each select="SATcommand/Links/link">
74                                 <tr>
75                                         <td bgcolor="Beige">
76                                                 <xsl:if test="@passed='0'">
77                                                         <a>
78                                                                 <xsl:attribute name="title">Click for more information</xsl:attribute>
79                                                                 <xsl:attribute name="class">OK2</xsl:attribute>
80                                                                 <xsl:attribute name="href"><xsl:value-of select="."/></xsl:attribute>
81                                                                 <xsl:value-of select="@command"/>
82                                                         </a>
83                                                 </xsl:if>
84                                                 <xsl:if test="@passed!='0'">
85                                                         <a>
86                                                                 <xsl:attribute name="title">Click for more information</xsl:attribute>
87                                                                 <xsl:attribute name="class">KO2</xsl:attribute>
88                                                                 <xsl:attribute name="href"><xsl:value-of select="."/></xsl:attribute>
89                                                                 <xsl:value-of select="@command"/>
90                                                         </a>
91                                                 </xsl:if>
92                                         </td>
93                                         <td bgcolor="LightBlue">
94                                                 <xsl:value-of select="@launchedCommand"/>
95                                         </td>
96                                 </tr>
97                         </xsl:for-each>
98                         
99                 </table>
100                 
101                 <h1>output 
102                 <a target="_blank">
103                         <xsl:attribute name="title">Click to open in an editor</xsl:attribute>
104                         <xsl:attribute name="href"><xsl:value-of select="SATcommand/OutLog"/></xsl:attribute>
105                         <xsl:attribute name="download"><xsl:value-of select="SATcommand/OutLog"/></xsl:attribute>
106                         log
107                 </a>
108                 </h1>
109                 <xsl:variable name="txtLog">
110                         <xsl:value-of select="SATcommand/OutLog"/>
111                 </xsl:variable>
112                 <iframe src="{$txtLog}" frameborder="0" class="center" width="100%" height="3000" scrolling="yes"></iframe>
113                 <!--<iframe src="{$txtLog}" frameborder="0" class="center" width="100%" height="1500000" scrolling="no"></iframe>-->
114         </body>
115 </xsl:template>
116
117 </xsl:stylesheet>