comparison contrib/sawmill/web/templates/details.html @ 482:a89f73f7c965

sawmill: Rearranged the postion of some python code in the details template to make it more readable.
author Sascha Teichmann <teichmann@intevation.de>
date Sat, 18 Sep 2010 08:01:18 +0000
parents 9c7e1d957d6b
children 28aa6ac933fb
comparison
equal deleted inserted replaced
481:9c7e1d957d6b 482:a89f73f7c965
3 <% 3 <%
4 from cgi import escape 4 from cgi import escape
5 from xml.sax.saxutils import quoteattr 5 from xml.sax.saxutils import quoteattr
6 6
7 from datetime import date, datetime 7 from datetime import date, datetime
8 %>
9 <html>
10 <head>
11 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
12 <link rel="icon" href="img/favicon.ico" type="image/x-icon" />
13 <link rel="stylesheet" href="styles/style.css" type="text/css" media="screen" />
14 <title>S&auml;gewerk - <%= escape(description) %></title>
15 </head>
16
17 <body>
18 <table border="0" width="100%" cellspacing="0" cellpadding="0">
19 <tr>
20 <td>
21 <a href="index.py"><img src="img/logo.jpg" border="0" alt="" width="533" height="94" /></a>
22 </td>
23 </tr>
24 </table>
25 <table border="0" width="100%" cellspacing="0" cellpadding="0">
26
27 <tr>
28 <td align="left" bgcolor="#E0E0E0" width="9">
29 <img src="img/topleft.png" height="9" width="9" alt="" />
30 </td>
31 <td bgcolor="#E0E0E0" width="30">
32 <img src="img/clear.png" width="30" height="1" alt="" />
33 </td>
34 <td bgcolor="#E0E0E0">
35 <img src="img/clear.png" width="1" height="1" alt="" />
36
37 </td>
38 <td bgcolor="#E0E0E0" width="30">
39 <img src="img/clear.png" width="30" height="1" alt="" />
40 </td>
41 <td align="right" bgcolor="#E0E0E0" width="9">
42 <img src="img/topright.png" height="9" width="9" alt="" />
43 </td>
44 </tr>
45
46 <tr>
47 <!-- Outer body row -->
48 <td bgcolor="#E0E0E0">
49 <img src="img/clear.png" width="10" height="1" alt="" />
50 </td>
51 <td valign="top" width="99%" bgcolor="#E0E0E0" colspan="3">
52 <!-- Inner Tabs / Shell -->
53 <table border="0" width="100%" cellspacing="0" cellpadding="0">
54 <tr>
55
56 <td align="left" bgcolor="#ffffff" width="9">
57 <img src="img/topleft-inner.png" height="9" width="9" alt="" />
58 </td>
59 <td bgcolor="#ffffff">
60 <img src="img/clear.png" width="1" height="1" alt="" />
61 </td>
62 <td align="right" bgcolor="#ffffff" width="9">
63 <img src="img/topright-inner.png" height="9" width="9" alt="" />
64 </td>
65
66 </tr>
67 <tr>
68 <td bgcolor="#ffffff">
69 <img src="img/clear.png" width="10" height="1" alt="" />
70 </td>
71 <td valign="top" width="99%" bgcolor="white" class="css_prison">
72 <!-- end main body row -->
73 <h1><%= escape(description) %></h1>
74 <%= header %>
75 <table class="statustable">
76 <tr>
77 <th class="statustablehead">Status</th>
78 <th class="statustablehead">Package</th>
79 <th class="statustablehead">Revision</th>
80 <th class="statustablehead">Start</th>
81 <th class="statustablehead">Stop</th>
82 <th class="statustablehead">Duration</th>
83 <th class="statustablehead">Notes</th>
84 </tr>
85 <%
86 8
87 def nn(s, d=""): 9 def nn(s, d=""):
88 if not s: return d 10 if not s: return d
89 return escape(s) 11 return escape(s)
90 12
141 'creating_binary_package': 'building binary packages', 63 'creating_binary_package': 'building binary packages',
142 'creating_source_package': 'building source package', 64 'creating_source_package': 'building source package',
143 'source_package_created': 'preparing build envrionment', 65 'source_package_created': 'preparing build envrionment',
144 'binary_package_created': 'success' 66 'binary_package_created': 'success'
145 } 67 }
146 68 %>
69 <html>
70 <head>
71 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
72 <link rel="icon" href="img/favicon.ico" type="image/x-icon" />
73 <link rel="stylesheet" href="styles/style.css" type="text/css" media="screen" />
74 <title>S&auml;gewerk - <%= escape(description) %></title>
75 </head>
76
77 <body>
78 <table border="0" width="100%" cellspacing="0" cellpadding="0">
79 <tr>
80 <td>
81 <a href="index.py"><img src="img/logo.jpg" border="0" alt="" width="533" height="94" /></a>
82 </td>
83 </tr>
84 </table>
85 <table border="0" width="100%" cellspacing="0" cellpadding="0">
86
87 <tr>
88 <td align="left" bgcolor="#E0E0E0" width="9">
89 <img src="img/topleft.png" height="9" width="9" alt="" />
90 </td>
91 <td bgcolor="#E0E0E0" width="30">
92 <img src="img/clear.png" width="30" height="1" alt="" />
93 </td>
94 <td bgcolor="#E0E0E0">
95 <img src="img/clear.png" width="1" height="1" alt="" />
96
97 </td>
98 <td bgcolor="#E0E0E0" width="30">
99 <img src="img/clear.png" width="30" height="1" alt="" />
100 </td>
101 <td align="right" bgcolor="#E0E0E0" width="9">
102 <img src="img/topright.png" height="9" width="9" alt="" />
103 </td>
104 </tr>
105
106 <tr>
107 <!-- Outer body row -->
108 <td bgcolor="#E0E0E0">
109 <img src="img/clear.png" width="10" height="1" alt="" />
110 </td>
111 <td valign="top" width="99%" bgcolor="#E0E0E0" colspan="3">
112 <!-- Inner Tabs / Shell -->
113 <table border="0" width="100%" cellspacing="0" cellpadding="0">
114 <tr>
115
116 <td align="left" bgcolor="#ffffff" width="9">
117 <img src="img/topleft-inner.png" height="9" width="9" alt="" />
118 </td>
119 <td bgcolor="#ffffff">
120 <img src="img/clear.png" width="1" height="1" alt="" />
121 </td>
122 <td align="right" bgcolor="#ffffff" width="9">
123 <img src="img/topright-inner.png" height="9" width="9" alt="" />
124 </td>
125
126 </tr>
127 <tr>
128 <td bgcolor="#ffffff">
129 <img src="img/clear.png" width="10" height="1" alt="" />
130 </td>
131 <td valign="top" width="99%" bgcolor="white" class="css_prison">
132 <!-- end main body row -->
133 <h1><%= escape(description) %></h1>
134 <%= header %>
135 <table class="statustable">
136 <tr>
137 <th class="statustablehead">Status</th>
138 <th class="statustablehead">Package</th>
139 <th class="statustablehead">Revision</th>
140 <th class="statustablehead">Start</th>
141 <th class="statustablehead">Stop</th>
142 <th class="statustablehead">Duration</th>
143 <th class="statustablehead">Notes</th>
144 </tr>
145 <%
147 for track_item in track_items: 146 for track_item in track_items:
148 # for all track items 147 # for all track items
149 curr_date = date_from_datetime(track_item.build_start) 148 curr_date = date_from_datetime(track_item.build_start)
150 if curr_date != last_date: 149 if curr_date != last_date:
151 last_date = curr_date 150 last_date = curr_date
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)