Merge lp:~chris.gagnon/qa-coverage-dashboard/reuse-inline-js-convert-to-static into lp:qa-coverage-dashboard
- reuse-inline-js-convert-to-static
- Merge into trunk
Proposed by
Chris Gagnon
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 761 | ||||
Proposed branch: | lp:~chris.gagnon/qa-coverage-dashboard/reuse-inline-js-convert-to-static | ||||
Merge into: | lp:qa-coverage-dashboard | ||||
Diff against target: |
1960 lines (+893/-895) 26 files modified
gaps/static/gaps/js/gaps_chart.js (+21/-0) gaps/templates/branch_list.html (+0/-70) gaps/templates/build.html (+0/-46) gaps/templates/gaps/branch_list.html (+70/-0) gaps/templates/gaps/build.html (+46/-0) gaps/templates/gaps/gaps_layout.html (+10/-0) gaps/templates/gaps/integration_list.html (+65/-0) gaps/templates/gaps/job.html (+65/-0) gaps/templates/gaps/job_list.html (+96/-0) gaps/templates/gaps/main.html (+34/-0) gaps/templates/gaps/project_detail.html (+83/-0) gaps/templates/gaps/project_list.html (+202/-0) gaps/templates/gaps/stack_detail.html (+100/-0) gaps/templates/gaps/stack_list.html (+93/-0) gaps/templates/gaps_layout.html (+0/-1) gaps/templates/integration_list.html (+0/-65) gaps/templates/job.html (+0/-65) gaps/templates/job_list.html (+0/-96) gaps/templates/main.html (+0/-34) gaps/templates/project_detail.html (+0/-90) gaps/templates/project_list.html (+0/-201) gaps/templates/stack_detail.html (+0/-106) gaps/templates/stack_list.html (+0/-113) gaps/urls.py (+0/-3) gaps/views.py (+4/-4) qa_dashboard/settings.py (+4/-1) |
||||
To merge this branch: | bzr merge lp:~chris.gagnon/qa-coverage-dashboard/reuse-inline-js-convert-to-static | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Allan LeSage (community) | Approve | ||
Review via email: mp+214345@code.launchpad.net |
Commit message
Description of the change
To post a comment you must log in.
- 761. By Chris Gagnon
-
remove extra { in gaps_layout
- 762. By Chris Gagnon
-
update settings.py to use local static js
- 763. By Chris Gagnon
-
resync with trunk
Revision history for this message
Chris Gagnon (chris.gagnon) wrote : | # |
- 764. By Chris Gagnon
-
resync with trunk
Revision history for this message
Allan LeSage (allanlesage) wrote : | # |
Ok this diff is pure murder--next time let's take one step at a time, no? I.e. make the changes and *then* move the files. I promise to be way more responsive to the MPs, sorry for the delay.
Please don't mark the bug *fix committed* until this branch is committed to trunk, IMO--or is this policy different in your ubuntu-history?
review:
Approve
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === added directory 'gaps/static' |
2 | === added directory 'gaps/static/gaps' |
3 | === added directory 'gaps/static/gaps/js' |
4 | === added file 'gaps/static/gaps/js/gaps_chart.js' |
5 | --- gaps/static/gaps/js/gaps_chart.js 1970-01-01 00:00:00 +0000 |
6 | +++ gaps/static/gaps/js/gaps_chart.js 2014-04-07 22:20:52 +0000 |
7 | @@ -0,0 +1,21 @@ |
8 | +function create_gaps_line_chart(data_url) { |
9 | + d3.json(data_url, function(data) { |
10 | + nv.addGraph(function() { |
11 | + var chart = nv.models.lineChart() |
12 | + .width(1100).height(400); |
13 | + chart.forceY([0, 1]); |
14 | + chart.xAxis |
15 | + .axisLabel('Date') |
16 | + .tickFormat(function(d){return d3.time.format('%Y%m%d')(new Date(d * 1000));}) |
17 | + |
18 | + chart.yAxis |
19 | + .axisLabel('%') |
20 | + .tickFormat(d3.format('%')) |
21 | + d3.select('#line-chart svg').datum(data).transition().duration(500).call(chart); |
22 | + |
23 | + nv.utils.windowResize(chart.update); |
24 | + |
25 | + return chart; |
26 | + }); //d3.json |
27 | + }); //addGraph |
28 | +} //create_gaps_chart |
29 | |
30 | === removed file 'gaps/templates/branch_list.html' |
31 | --- gaps/templates/branch_list.html 2014-03-07 16:58:26 +0000 |
32 | +++ gaps/templates/branch_list.html 1970-01-01 00:00:00 +0000 |
33 | @@ -1,70 +0,0 @@ |
34 | -{% extends "layout.html" %} |
35 | -{% load dashboard_extras %} |
36 | - |
37 | -{% block content %} |
38 | -<script type='text/javascript'> |
39 | - //<![CDATA[ |
40 | - $(document).ready(function() { |
41 | - $(".data-table").dataTable({ |
42 | - "bPaginate": false, |
43 | - "aaSorting": [[0, 'desc']] |
44 | - }); |
45 | - }); |
46 | - //]]> |
47 | -</script> |
48 | -<div class='grid_15'> |
49 | - <h2> |
50 | - Branches |
51 | - </h2> |
52 | -</div> |
53 | -<div class='grid_2'> |
54 | - <h3 class='nav-title'> |
55 | - BRANCH FILTER |
56 | - </h3> |
57 | - <ul class='left_nav'> |
58 | - <li> |
59 | - <a href='{% url branches %}'>All</a> |
60 | - </li> |
61 | - </ul> |
62 | -</div> |
63 | -<div class='grid_13'> |
64 | - <table class='data-table basic wide'> |
65 | - <thead> |
66 | - <tr> |
67 | - <th>Branch</th> |
68 | - <th>Revno</th> |
69 | - <th>Date</th> |
70 | - <th>Series</th> |
71 | - <th>Package</th> |
72 | - <th>Upload Date</th> |
73 | - </tr> |
74 | - </thead> |
75 | - <tbody> |
76 | - {% for branch in branch_list %} |
77 | - <tr> |
78 | - <td> |
79 | - <a href='job/{{ job.name }}'> |
80 | - {{ branch.name }} |
81 | - </a> |
82 | - </td> |
83 | - <td class='num'> |
84 | - {{ branch.revno }} |
85 | - </td> |
86 | - <td> |
87 | - {{ branch.rev_date }} |
88 | - </td> |
89 | - <td> |
90 | - {{ branch.series }} |
91 | - </td> |
92 | - <td> |
93 | - {{ branch.package }} |
94 | - </td> |
95 | - <td> |
96 | - {{ branch.package_date }} |
97 | - </td> |
98 | - </tr> |
99 | - {% endfor %} |
100 | - </tbody> |
101 | - </table> |
102 | -</div> |
103 | -{% endblock %} |
104 | |
105 | === removed file 'gaps/templates/build.html' |
106 | --- gaps/templates/build.html 2014-03-07 16:58:26 +0000 |
107 | +++ gaps/templates/build.html 1970-01-01 00:00:00 +0000 |
108 | @@ -1,46 +0,0 @@ |
109 | -{% extends "layout.html" %} |
110 | -{% load dashboard_extras %} |
111 | - |
112 | -{% block page_name %}QA Coverage Dashboard{% endblock %} |
113 | - |
114 | -{% block content %} |
115 | -{{ build.timestamp }} |
116 | -<div class='grid_13'> |
117 | - <table class='data-table basic wide'> |
118 | - <thead> |
119 | - <tr> |
120 | - <th>Number</th> |
121 | - <th>Flavor</th> |
122 | - <th>Series</th> |
123 | - <th>Result</th> |
124 | - <th>Duration</th> |
125 | - <th>Timestamp</th> |
126 | - </tr> |
127 | - </thead> |
128 | - <tbody> |
129 | - {% for run in runs %} |
130 | - <tr> |
131 | - <td> |
132 | - <a href='{{ run.url }}'>{{ run.number }}</a> |
133 | - <td> |
134 | - {{ run.flavor }} |
135 | - </td> |
136 | - <td> |
137 | - {{ run.series }} |
138 | - </td> |
139 | - <td> |
140 | - {{ run.result }} |
141 | - </td> |
142 | - <td> |
143 | - {{ run.duration }} |
144 | - </td> |
145 | - <td> |
146 | - {{ run.timestamp }} |
147 | - </td> |
148 | - </tr> |
149 | - {% endfor %} |
150 | - </tbody> |
151 | - </table> |
152 | -</div> |
153 | - |
154 | -{% endblock %} |
155 | |
156 | === added directory 'gaps/templates/gaps' |
157 | === added file 'gaps/templates/gaps/branch_list.html' |
158 | --- gaps/templates/gaps/branch_list.html 1970-01-01 00:00:00 +0000 |
159 | +++ gaps/templates/gaps/branch_list.html 2014-04-07 22:20:52 +0000 |
160 | @@ -0,0 +1,70 @@ |
161 | +{% extends "gaps/gaps_layout.html" %} |
162 | +{% load dashboard_extras %} |
163 | + |
164 | +{% block content %} |
165 | +<script type='text/javascript'> |
166 | + //<![CDATA[ |
167 | + $(document).ready(function() { |
168 | + $(".data-table").dataTable({ |
169 | + "bPaginate": false, |
170 | + "aaSorting": [[0, 'desc']] |
171 | + }); |
172 | + }); |
173 | + //]]> |
174 | +</script> |
175 | +<div class='grid_15'> |
176 | + <h2> |
177 | + Branches |
178 | + </h2> |
179 | +</div> |
180 | +<div class='grid_2'> |
181 | + <h3 class='nav-title'> |
182 | + BRANCH FILTER |
183 | + </h3> |
184 | + <ul class='left_nav'> |
185 | + <li> |
186 | + <a href='{% url branches %}'>All</a> |
187 | + </li> |
188 | + </ul> |
189 | +</div> |
190 | +<div class='grid_13'> |
191 | + <table class='data-table basic wide'> |
192 | + <thead> |
193 | + <tr> |
194 | + <th>Branch</th> |
195 | + <th>Revno</th> |
196 | + <th>Date</th> |
197 | + <th>Series</th> |
198 | + <th>Package</th> |
199 | + <th>Upload Date</th> |
200 | + </tr> |
201 | + </thead> |
202 | + <tbody> |
203 | + {% for branch in branch_list %} |
204 | + <tr> |
205 | + <td> |
206 | + <a href='job/{{ job.name }}'> |
207 | + {{ branch.name }} |
208 | + </a> |
209 | + </td> |
210 | + <td class='num'> |
211 | + {{ branch.revno }} |
212 | + </td> |
213 | + <td> |
214 | + {{ branch.rev_date }} |
215 | + </td> |
216 | + <td> |
217 | + {{ branch.series }} |
218 | + </td> |
219 | + <td> |
220 | + {{ branch.package }} |
221 | + </td> |
222 | + <td> |
223 | + {{ branch.package_date }} |
224 | + </td> |
225 | + </tr> |
226 | + {% endfor %} |
227 | + </tbody> |
228 | + </table> |
229 | +</div> |
230 | +{% endblock %} |
231 | |
232 | === added file 'gaps/templates/gaps/build.html' |
233 | --- gaps/templates/gaps/build.html 1970-01-01 00:00:00 +0000 |
234 | +++ gaps/templates/gaps/build.html 2014-04-07 22:20:52 +0000 |
235 | @@ -0,0 +1,46 @@ |
236 | +{% extends "gaps/gaps_layout.html" %} |
237 | +{% load dashboard_extras %} |
238 | + |
239 | +{% block page_name %}QA Coverage Dashboard{% endblock %} |
240 | + |
241 | +{% block content %} |
242 | +{{ build.timestamp }} |
243 | +<div class='grid_13'> |
244 | + <table class='data-table basic wide'> |
245 | + <thead> |
246 | + <tr> |
247 | + <th>Number</th> |
248 | + <th>Flavor</th> |
249 | + <th>Series</th> |
250 | + <th>Result</th> |
251 | + <th>Duration</th> |
252 | + <th>Timestamp</th> |
253 | + </tr> |
254 | + </thead> |
255 | + <tbody> |
256 | + {% for run in runs %} |
257 | + <tr> |
258 | + <td> |
259 | + <a href='{{ run.url }}'>{{ run.number }}</a> |
260 | + <td> |
261 | + {{ run.flavor }} |
262 | + </td> |
263 | + <td> |
264 | + {{ run.series }} |
265 | + </td> |
266 | + <td> |
267 | + {{ run.result }} |
268 | + </td> |
269 | + <td> |
270 | + {{ run.duration }} |
271 | + </td> |
272 | + <td> |
273 | + {{ run.timestamp }} |
274 | + </td> |
275 | + </tr> |
276 | + {% endfor %} |
277 | + </tbody> |
278 | + </table> |
279 | +</div> |
280 | + |
281 | +{% endblock %} |
282 | |
283 | === added file 'gaps/templates/gaps/gaps_layout.html' |
284 | --- gaps/templates/gaps/gaps_layout.html 1970-01-01 00:00:00 +0000 |
285 | +++ gaps/templates/gaps/gaps_layout.html 2014-04-07 22:20:52 +0000 |
286 | @@ -0,0 +1,10 @@ |
287 | +{% extends "layout.html" %} |
288 | +{% load staticfiles %} |
289 | +{% block extra_headers %} |
290 | + <link type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.css" rel="stylesheet" /> |
291 | + <script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/d3/3.2.2/d3.min.js"></script> |
292 | + <!-- need to switch back to cdnjs when bugs are fixed |
293 | +<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.js"></script>--> |
294 | + <script type="text/javascript" src="//6df403e3d98e2ac67ac2-180150c581869d2c4c18db9c9e3179c4.r40.cf1.rackcdn.com/nv.d3.js"></script> |
295 | + <script type='text/javascript' src='{% static "gaps/js/gaps_chart.js" %}'></script> |
296 | +{% endblock%} |
297 | |
298 | === added file 'gaps/templates/gaps/integration_list.html' |
299 | --- gaps/templates/gaps/integration_list.html 1970-01-01 00:00:00 +0000 |
300 | +++ gaps/templates/gaps/integration_list.html 2014-04-07 22:20:52 +0000 |
301 | @@ -0,0 +1,65 @@ |
302 | +{% extends "gaps/gaps_layout.html" %} |
303 | +{% load dashboard_extras %} |
304 | + |
305 | +{% block page_name %}QA Coverage Dashboard{% endblock %} |
306 | + |
307 | +{% block content %} |
308 | +<script type='text/javascript'> |
309 | + //<![CDATA[ |
310 | + $(document).ready(function() { |
311 | + $(".data-table").dataTable({ |
312 | + "bPaginate": false, |
313 | + "aaSorting": [[0, 'desc']] |
314 | + }); |
315 | + }); |
316 | + //]]> |
317 | +</script> |
318 | +<div class='grid_15'> |
319 | + <h2> |
320 | + Integration Testing [TBD] |
321 | + </h2> |
322 | +</div> |
323 | +<div class='grid_2'> |
324 | + <h3 class='nav-title'> |
325 | + STACKS |
326 | + </h3> |
327 | + <ul class='left_nav'> |
328 | + <li> |
329 | + <a href='{% url stacks %}'>All</a> |
330 | + </li> |
331 | + </ul> |
332 | +</div> |
333 | +<div class='grid_13'> |
334 | + This page is work in progress.<BR> |
335 | + It will be used to show test results for the daily-release process |
336 | + integration tests. |
337 | + <table class='data-table basic wide'> |
338 | + <thead> |
339 | + <tr> |
340 | + <th>Name</th> |
341 | + <th>Release</th> |
342 | + <th>Series</th> |
343 | + <th>Results</th> |
344 | + </tr> |
345 | + </thead> |
346 | + <tbody> |
347 | + {% for test in test_list %} |
348 | + <tr> |
349 | + <td> |
350 | + <a href='{% url stacks %}/{{ test.stack_name }}'>{{ test.stack_name }}</a> |
351 | + </td> |
352 | + <td> |
353 | + {{ test.release }} |
354 | + </td> |
355 | + <td> |
356 | + {{ test.series }} |
357 | + </td> |
358 | + <td> |
359 | + {{ test.results }} |
360 | + </td> |
361 | + </tr> |
362 | + {% endfor %} |
363 | + </tbody> |
364 | + </table> |
365 | +</div> |
366 | +{% endblock %} |
367 | |
368 | === added file 'gaps/templates/gaps/job.html' |
369 | --- gaps/templates/gaps/job.html 1970-01-01 00:00:00 +0000 |
370 | +++ gaps/templates/gaps/job.html 2014-04-07 22:20:52 +0000 |
371 | @@ -0,0 +1,65 @@ |
372 | +{% extends "gaps/gaps_layout.html" %} |
373 | +{% load dashboard_extras %} |
374 | + |
375 | +{% block page_name %}QA Coverage Dashboard{% endblock %} |
376 | + |
377 | +{% block content %} |
378 | +<script type='text/javascript'> |
379 | + //<![CDATA[ |
380 | + $(document).ready(function() { |
381 | + $(".data-table").dataTable({ |
382 | + "bPaginate": false, |
383 | + "aaSorting": [[0, 'desc']] |
384 | + }); |
385 | + }); |
386 | + //]]> |
387 | +</script> |
388 | +<div class='grid_15'> |
389 | + <h2> |
390 | + Job: {{ job.name }} |
391 | + </h2> |
392 | +</div> |
393 | +<div class='grid_2'> |
394 | + <h3 class='nav-title'> |
395 | + BUILD FILTER |
396 | + </h3> |
397 | + <ul class='left_nav'> |
398 | + <li> |
399 | + <a href='?show=all'>All</a> |
400 | + </li> |
401 | + {% for result in result_list %} |
402 | + <li> |
403 | + <a href='{% url jobs %}{{ job.name }}?show={{ result.name }}'>{{ result.name }}</a> |
404 | + </li> |
405 | + {% endfor %} |
406 | + </ul> |
407 | +</div> |
408 | +<div class='grid_13'> |
409 | +</div> |
410 | +<div class='grid_13'> |
411 | + <table class='data-table basic wide'> |
412 | + <thead> |
413 | + <tr> |
414 | + <th>Number</th> |
415 | + <th>Status</th> |
416 | + <th>Timestamp</th> |
417 | + </tr> |
418 | + </thead> |
419 | + <tbody> |
420 | + {% for build in build_list %} |
421 | + <tr> |
422 | + <td class='num'> |
423 | + <a href="{{ build.url }}">{{ build.number }}</a> |
424 | + </td> |
425 | + <td> |
426 | + {{ build.result }} |
427 | + </td> |
428 | + <td> |
429 | + {{ build.timestamp }} |
430 | + </td> |
431 | + </tr> |
432 | + {% endfor %} |
433 | + </tbody> |
434 | + </table> |
435 | +</div> |
436 | +{% endblock %} |
437 | |
438 | === added file 'gaps/templates/gaps/job_list.html' |
439 | --- gaps/templates/gaps/job_list.html 1970-01-01 00:00:00 +0000 |
440 | +++ gaps/templates/gaps/job_list.html 2014-04-07 22:20:52 +0000 |
441 | @@ -0,0 +1,96 @@ |
442 | +{% extends "gaps/gaps_layout.html" %} |
443 | +{% load dashboard_extras %} |
444 | + |
445 | +{% block page_name %}QA Coverage Dashboard{% endblock %} |
446 | + |
447 | +{% block content %} |
448 | +<script type='text/javascript'> |
449 | + //<![CDATA[ |
450 | + $(document).ready(function() { |
451 | + $(".data-table").dataTable({ |
452 | + "bPaginate": false, |
453 | + "aaSorting": [[0, 'desc']] |
454 | + }); |
455 | + }); |
456 | + //]]> |
457 | +</script> |
458 | +<div class='grid_15'> |
459 | + <h2> |
460 | + Jobs |
461 | + </h2> |
462 | +</div> |
463 | +<div class='grid_2'> |
464 | + <h3 class='nav-title'> |
465 | + JOB FILTER |
466 | + </h3> |
467 | + <ul class='left_nav'> |
468 | + <li> |
469 | + <a href='{% url jobs %}'>All</a> |
470 | + </li> |
471 | + <li> |
472 | + <a href='{% url jobs %}?show=autolanding'>Autolanding</a> |
473 | + </li> |
474 | + <li> |
475 | + <a href='{% url jobs %}?show=ci'>CI</a> |
476 | + </li> |
477 | + <li> |
478 | + <a href='{% url jobs %}?show=daily'>Daily</a> |
479 | + </li> |
480 | + <li> |
481 | + <a href='{% url jobs %}?show=coverity'>Coverity</a> |
482 | + </li> |
483 | + </ul> |
484 | +</div> |
485 | +<div class='grid_13'> |
486 | + <table class='data-table basic wide'> |
487 | + <thead> |
488 | + <tr> |
489 | + <th>Job</th> |
490 | + <th>Release</th> |
491 | + <th>Arch</th> |
492 | + <th>Date</th> |
493 | + <th>Build</th> |
494 | + <th>Duration</th> |
495 | + <th>Tests</th> |
496 | + <th>Coverage</th> |
497 | + <th>Bugs</th> |
498 | + </tr> |
499 | + </thead> |
500 | + <tbody> |
501 | + {% for job in job_list %} |
502 | + <tr> |
503 | + <td> |
504 | + <a href='job/{{ job.name }}'> |
505 | + {{ job.name }} |
506 | + </a> |
507 | + </td> |
508 | + <td> |
509 | + {{ job.series }} |
510 | + </td> |
511 | + <td> |
512 | + {{ job.arch }} |
513 | + </td> |
514 | + <td> |
515 | + {{ job.last_run_date }} |
516 | + </td> |
517 | + <td class='num'> |
518 | + {{ job.build_count }} |
519 | + </td> |
520 | + <td class='num'> |
521 | + {{ job.duration }} |
522 | + </td> |
523 | + <td class='num'> |
524 | + {{ job.test_count }} |
525 | + </td> |
526 | + <td class='num {{job.coverage_rate|pass_rate_color}}'> |
527 | + {{ job.coverage_rate_pct }} |
528 | + </td> |
529 | + <td class='num'> |
530 | + {{ job.bug_count }} |
531 | + </td> |
532 | + </tr> |
533 | + {% endfor %} |
534 | + </tbody> |
535 | + </table> |
536 | +</div> |
537 | +{% endblock %} |
538 | |
539 | === added file 'gaps/templates/gaps/main.html' |
540 | --- gaps/templates/gaps/main.html 1970-01-01 00:00:00 +0000 |
541 | +++ gaps/templates/gaps/main.html 2014-04-07 22:20:52 +0000 |
542 | @@ -0,0 +1,34 @@ |
543 | +{% extends "gaps/gaps_layout.html" %} |
544 | +{% load dashboard_extras %} |
545 | + |
546 | +{% block content %} |
547 | +<script type='text/javascript'> |
548 | + //<![CDATA[ |
549 | + $(document).ready(function() { |
550 | + $(".data-table").dataTable({ |
551 | + "bPaginate": false, |
552 | + "aaSorting": [[0, 'desc']] |
553 | + }); |
554 | + }); |
555 | + //]]> |
556 | +</script> |
557 | +<div class='grid_15'> |
558 | + <ul> |
559 | + <li> |
560 | + <h2> |
561 | + <a href='{% url stacks %}?show=head'>Stacks</a> |
562 | + </h2> |
563 | + </li> |
564 | + <li> |
565 | + <h2> |
566 | + <a href='{% url projects %}'>Projects</a> |
567 | + </h2> |
568 | + </li> |
569 | + <li> |
570 | + <h2> |
571 | + <a href='{% url integration %}'>Daily Integration [TBD]</a> |
572 | + </h2> |
573 | + </li> |
574 | + </ul> |
575 | +</div> |
576 | +{% endblock %} |
577 | |
578 | === added file 'gaps/templates/gaps/project_detail.html' |
579 | --- gaps/templates/gaps/project_detail.html 1970-01-01 00:00:00 +0000 |
580 | +++ gaps/templates/gaps/project_detail.html 2014-04-07 22:20:52 +0000 |
581 | @@ -0,0 +1,83 @@ |
582 | +{% extends "gaps/gaps_layout.html" %} |
583 | +{% load dashboard_extras staticfiles %} |
584 | +{% load percentage %} |
585 | + |
586 | +{% block content %} |
587 | +<style> |
588 | + #line-chart svg { |
589 | + height: 400px; |
590 | + width: 1100px; |
591 | + } |
592 | +</style> |
593 | +<script type='text/javascript'> |
594 | + //<![CDATA[ |
595 | + $(document).ready(function() { |
596 | + $(".data-table").dataTable({ |
597 | + "bPaginate": false, |
598 | + "aaSorting": [[2, 'desc']] |
599 | + }); |
600 | + }); |
601 | + //]]> |
602 | +</script> |
603 | +<script type="text/javascript"> |
604 | + d3.json('{% url "gaps_api_project" project.name %}', function(data) { |
605 | + nv.addGraph(function() { |
606 | + var chart = nv.models.lineChart() |
607 | + .width(1100).height(400); |
608 | + chart.forceY([0, 1]); |
609 | + chart.xAxis |
610 | + .axisLabel('Date') |
611 | + .tickFormat(function(d){return d3.time.format('%Y%m%d')(new Date(d * 1000));}) |
612 | + |
613 | + chart.yAxis |
614 | + .axisLabel('%') |
615 | + .tickFormat(d3.format('%')) |
616 | + d3.select('#line-chart svg').datum(data).transition().duration(500).call(chart); |
617 | + |
618 | + nv.utils.windowResize(chart.update); |
619 | + |
620 | + return chart; |
621 | + }); |
622 | + }); |
623 | +</script> |
624 | +<div class='grid_15'> |
625 | + <h2> |
626 | + Project: {{ project.name }} |
627 | + </h2> |
628 | +</div> |
629 | +<div class='grid_13'> |
630 | + {% if coverage_datas|length > 0 %} |
631 | + <div class="grid_13"> |
632 | + <div id="line-chart"> |
633 | + <svg></svg> |
634 | + </div> |
635 | + </div> |
636 | + <table class='data-table basic wide'> |
637 | + <thead> |
638 | + <tr> |
639 | + <th>Jenkins Build</th> |
640 | + <th>Line Coverage</th> |
641 | + <th>Branch Coverage</th> |
642 | + </tr> |
643 | + </thead> |
644 | + <tbody> |
645 | + {% for coverage_data in coverage_datas %} |
646 | + <tr> |
647 | + <td> |
648 | + <a href='{{ coverage_data.coverage_build.url }}'>{{ coverage_data.coverage_build.ran_at }}</a> |
649 | + </td> |
650 | + <td class='num'> |
651 | + {{ coverage_data.line_coverage|percentage }}% |
652 | + </td> |
653 | + <td class='num'> |
654 | + {{ coverage_data.branch_coverage|percentage }}% |
655 | + </td> |
656 | + </tr> |
657 | + {% endfor %} |
658 | + </tbody> |
659 | + </table> |
660 | + {% else %} |
661 | +No coverage data was found for this project. Please pursue with your QA contact or on freenode in the #ubuntu-quality channel. |
662 | + {% endif %} |
663 | +</div> |
664 | +{% endblock %} |
665 | |
666 | === added file 'gaps/templates/gaps/project_list.html' |
667 | --- gaps/templates/gaps/project_list.html 1970-01-01 00:00:00 +0000 |
668 | +++ gaps/templates/gaps/project_list.html 2014-04-07 22:20:52 +0000 |
669 | @@ -0,0 +1,202 @@ |
670 | +{% extends "gaps/gaps_layout.html" %} |
671 | +{% load staticfiles %} |
672 | +{% load dashboard_extras %} |
673 | +{% load percentage %} |
674 | + |
675 | +{% block content %} |
676 | +<script type='text/javascript'> |
677 | + //<![CDATA[ |
678 | + $(document).ready(function() { |
679 | + $(".data-table").dataTable({ |
680 | + "bPaginate": false, |
681 | + "aaSorting": [[3, 'desc'], [0, 'asc']], |
682 | + "aoColumns": [ |
683 | + null, |
684 | + null, |
685 | + {"aDataSort": [3]}, |
686 | + {"bVisible": false}, |
687 | + {"aDataSort": [5]}, |
688 | + {"bVisible": false}, |
689 | + ] |
690 | + }); |
691 | + }); |
692 | + //]]> |
693 | +</script> |
694 | +<div class='grid_15'> |
695 | + <h2> |
696 | + Projects |
697 | + </h2> |
698 | + {% if project_list %} |
699 | + <div class='grid_13'></div> |
700 | + <div id='avg_chart_text' class='avg_chart_box'> |
701 | + <div class='chart_title'>Code Coverage</div> |
702 | + <div class='avg_chart_box'> |
703 | + <div id='lineGaugeContainer'></div> |
704 | + </div> |
705 | + <div class='avg_chart_box'> |
706 | + <div id='branchGaugeContainer'></div> |
707 | + </div> |
708 | + <div class='avg_chart_box'> |
709 | + <div id='reportingGaugeContainer'></div> |
710 | + </div> |
711 | + </div> |
712 | + {% endif %} |
713 | +</div> |
714 | +<div class='grid_2'> |
715 | + <h3 class='nav-title'> |
716 | + PROJECT FILTER |
717 | + </h3> |
718 | + <ul class='left_nav'> |
719 | + <li> |
720 | + <a href='{% url 'projects' %}'>All</a> |
721 | + </li> |
722 | + {% for release in release_list %} |
723 | + <li> |
724 | + <a href='{% url 'projects' %}?show={{ release }} '>{{ release }}</a> |
725 | + </li> |
726 | + {% endfor %} |
727 | + </ul> |
728 | +</div> |
729 | +<div class='grid_13'> |
730 | + <table class='data-table basic wide'> |
731 | + <thead> |
732 | + <tr> |
733 | + <th>Name</th> |
734 | + <th>Last Build</th> |
735 | + <th>Line Coverage</th> |
736 | + <th>Line Coverage Sorting Criterion</th> |
737 | + <th>Branch Coverage</th> |
738 | + <th>Branch Coverage Sorting Criterion</th> |
739 | + </tr> |
740 | + </thead> |
741 | + <tbody> |
742 | + {% for project in project_list %} |
743 | + <tr> |
744 | + <td> |
745 | + <a href='{% url 'projects' %}{{ project.name }}'>{{ project.name }}</a> |
746 | + </td> |
747 | + <td> |
748 | + {{ project.last_build.ran_at }} |
749 | + </td> |
750 | + <td class='num'> |
751 | + {% if project.last_coverage_data.line_coverage == None %} |
752 | + N/A |
753 | + {% else %} |
754 | + {{ project.last_coverage_data.line_coverage|percentage }}% |
755 | + {% endif %} |
756 | + </td> |
757 | + <td class='num'> |
758 | + {{ project.last_coverage_data.line_coverage|percentage }} |
759 | + </td> |
760 | + <td class='num'> |
761 | + {% if project.last_coverage_data.line_coverage == None %} |
762 | + N/A |
763 | + {% else %} |
764 | + {{ project.last_coverage_data.branch_coverage|percentage }}% |
765 | + {% endif %} |
766 | + </td> |
767 | + <td class='num'> |
768 | + {{ project.last_coverage_data.branch_coverage|percentage }} |
769 | + </td> |
770 | + </tr> |
771 | + {% endfor %} |
772 | + </tbody> |
773 | + </table> |
774 | +</div> |
775 | +{% if project_list %} |
776 | + {% load staticfiles %} |
777 | + <script type="text/javascript" src='{% static "js/d3v3.js" %}'></script> |
778 | + <script type="text/javascript" src='{% static "js/gauge.js" %}'></script> |
779 | + <script type="text/javascript"> |
780 | + |
781 | + function avgLines() { |
782 | + // project reporting list |
783 | + var total_projects = 0; |
784 | + var reporting_project = 0; |
785 | + var line_sum = 0; |
786 | + var hit_sum = 0; |
787 | + var total_sum = 0; |
788 | + var taken_sum = 0; |
789 | + |
790 | + {% for project in project_list %} |
791 | + |
792 | + var line_count = {{ project.ci_project.line_count|default_if_none:"0" }} + 0; |
793 | + |
794 | + total_projects = total_projects + 1; |
795 | + |
796 | + if ( line_count > 0) { |
797 | + reporting_project = reporting_project + 1; |
798 | + } |
799 | + |
800 | + line_sum = line_sum + line_count; |
801 | + hit_sum = hit_sum + {{ project.ci_project.hit_count|default_if_none:"0" }} + 0; |
802 | + total_sum = total_sum + {{ project.ci_project.total_count|default_if_none:"0" }} + 0; |
803 | + taken_sum = taken_sum + {{ project.ci_project.taken_count|default_if_none:"0" }} + 0; |
804 | + |
805 | + {% endfor %} |
806 | + |
807 | + |
808 | + line_percent = (hit_sum / line_sum) |
809 | + branch_percent = (taken_sum / total_sum) |
810 | + proj_report_percent = (reporting_project / total_projects) |
811 | + return [Math.round(line_percent * 100), Math.round(branch_percent * 100), Math.round(proj_report_percent * 100)] |
812 | +} |
813 | + |
814 | + var coverage_data = avgLines() |
815 | + var gauges = []; |
816 | + var gauge_size = 106.5; |
817 | + function create_coverage_gauge(name, label, value) { |
818 | + var config = |
819 | + { |
820 | + size: gauge_size, |
821 | + label: label, |
822 | + minorTicks: 5 |
823 | + } |
824 | + |
825 | + config.redZones = []; |
826 | + config.redZones.push({ from: 0, to: 50 }); |
827 | + |
828 | + config.yellowZones = []; |
829 | + config.yellowZones.push({ from: 50, to: 85 }); |
830 | + |
831 | + config.greenZones = []; |
832 | + config.greenZones.push = ({ from: 85, to: 100 }); |
833 | + |
834 | + gauges[name] = new Gauge(name + "GaugeContainer", config); |
835 | + gauges[name].render(); |
836 | + gauges[name].redraw(value); |
837 | + } |
838 | + |
839 | + function create_proj_report_gauge(name, label, value) { |
840 | + var config = |
841 | + { |
842 | + size: gauge_size, |
843 | + label: label, |
844 | + minorTicks: 5 |
845 | + } |
846 | + |
847 | + config.redZones = []; |
848 | + config.redZones.push({ from: 0, to: 85 }); |
849 | + |
850 | + config.yellowZones = []; |
851 | + config.yellowZones.push({ from: 85, to: 95 }); |
852 | + |
853 | + config.greenZones = []; |
854 | + config.greenZones.push = ({ from: 95, to: 100 }); |
855 | + |
856 | + gauges[name] = new Gauge(name + "GaugeContainer", config); |
857 | + gauges[name].render(); |
858 | + gauges[name].redraw(value); |
859 | + } |
860 | + |
861 | + |
862 | + function init_charts() { |
863 | + create_coverage_gauge("line", "Line", coverage_data[0]) |
864 | + create_coverage_gauge("branch", "Branch", coverage_data[1]) |
865 | + create_proj_report_gauge("reporting", "Reporting", coverage_data[2]) |
866 | + } |
867 | + |
868 | + window.onload = init_charts() |
869 | + </script> |
870 | +{% endif %} |
871 | +{% endblock %} |
872 | |
873 | === added file 'gaps/templates/gaps/stack_detail.html' |
874 | --- gaps/templates/gaps/stack_detail.html 1970-01-01 00:00:00 +0000 |
875 | +++ gaps/templates/gaps/stack_detail.html 2014-04-07 22:20:52 +0000 |
876 | @@ -0,0 +1,100 @@ |
877 | +{% extends "gaps/gaps_layout.html" %} |
878 | +{% load staticfiles %} |
879 | +{% load dashboard_extras %} |
880 | +{% load gaps_extras %} |
881 | +{% load percentage %} |
882 | + |
883 | +{% block content %} |
884 | +<style> |
885 | + #line-chart svg { |
886 | + height: 400px; |
887 | + width: 1100px; |
888 | + } |
889 | +</style> |
890 | +<script type='text/javascript'> |
891 | + //<![CDATA[ |
892 | + $(document).ready(function() { |
893 | + $(".data-table").dataTable({ |
894 | + "bPaginate": false, |
895 | + "aaSorting": [[2, 'desc']] |
896 | + }); |
897 | + }); |
898 | + //]]> |
899 | +</script> |
900 | +<script type="text/javascript"> |
901 | + d3.json('{% url 'gaps_api_stack' stack.name %}', function(data) { |
902 | + nv.addGraph(function() { |
903 | + var chart = nv.models.lineChart() |
904 | + .width(900).height(400); |
905 | + chart.forceY([0, 1]); |
906 | + chart.xAxis |
907 | + .axisLabel('Date') |
908 | + .tickFormat(function(d){return d3.time.format('%Y%m%d')(new Date(d * 1000));}) |
909 | + chart.yAxis |
910 | + .axisLabel('%') |
911 | + .tickFormat(d3.format('%')) |
912 | + d3.select('#line-chart svg').datum(data).transition().duration(500).call(chart); |
913 | + nv.utils.windowResize(chart.update); |
914 | + return chart; |
915 | + }); |
916 | + }); |
917 | +</script> |
918 | +<div class='grid_15'> |
919 | + <h2> |
920 | + Stack: {{ stack.name }} |
921 | + </h2> |
922 | +</div> |
923 | +<div class='grid_2'> |
924 | + <h3 class='nav-title'> |
925 | + STACKS |
926 | + </h3> |
927 | + <ul class='left_nav'> |
928 | + {% for stack in stack_list %} |
929 | + <li> |
930 | + <a href='{% url 'stacks' %}{{ stack }}'>{{ stack }}</a> |
931 | + </li> |
932 | + {% endfor %} |
933 | + </ul> |
934 | +</div> |
935 | + <div class="grid_13"> |
936 | + <div id="line-chart"> |
937 | + <svg></svg> |
938 | + </div> |
939 | + <table class='data-table basic wide'> |
940 | + <thead> |
941 | + <tr> |
942 | + <th>Name</th> |
943 | + <th>Last Build</th> |
944 | + <th>Line Coverage</th> |
945 | + <th>Branch Coverage</th> |
946 | + </tr> |
947 | + </thead> |
948 | + <tbody> |
949 | + {% for project in project_list %} |
950 | + <tr> |
951 | + <td> |
952 | + <a href='{% url 'projects' %}{{ project.name }}/'>{{ project.name }}</a> |
953 | + </td> |
954 | + <td> |
955 | + {{ project.last_build.ran_at }} |
956 | + </td> |
957 | + <td class='num'> |
958 | + {% if project.last_coverage_data.line_coverage == None %} |
959 | + N/A |
960 | + {% else %} |
961 | + {{ project.last_coverage_data.line_coverage|percentage }}% |
962 | + {% endif %} |
963 | + </td> |
964 | + <td class='num'> |
965 | + {% if project.last_coverage_data.branch_coverage == None %} |
966 | + N/A |
967 | + {% else %} |
968 | + {{ project.last_coverage_data.branch_coverage|percentage }}% |
969 | + {% endif %} |
970 | + </td> |
971 | + </tr> |
972 | + {% endfor %} |
973 | + </tbody> |
974 | + </table> |
975 | +</div> |
976 | +{% endblock %} |
977 | |
978 | === added file 'gaps/templates/gaps/stack_list.html' |
979 | --- gaps/templates/gaps/stack_list.html 1970-01-01 00:00:00 +0000 |
980 | +++ gaps/templates/gaps/stack_list.html 2014-04-07 22:20:52 +0000 |
981 | @@ -0,0 +1,93 @@ |
982 | +{% extends "gaps/gaps_layout.html" %} |
983 | +{% load staticfiles %} |
984 | +{% load dashboard_extras %} |
985 | +{% load gaps_extras %} |
986 | +{% load percentage %} |
987 | + |
988 | +{% block content %} |
989 | +<style> |
990 | + #line-chart svg { |
991 | + height: 400px; |
992 | + width: 1100px; |
993 | + } |
994 | +</style> |
995 | +<script type='text/javascript'> |
996 | + //<![CDATA[ |
997 | + $(document).ready(function() { |
998 | + $(".data-table").dataTable({ |
999 | + "bPaginate": false, |
1000 | + "aaSorting": [[0, 'desc']] |
1001 | + }); |
1002 | + }); |
1003 | + //]]> |
1004 | +</script> |
1005 | +<script type="text/javascript"> |
1006 | + var chart_url = '{% url "gaps_api_stack_list" %}' |
1007 | + create_gaps_line_chart(chart_url) |
1008 | +</script> |
1009 | +<div class='grid_15'> |
1010 | + <h2> |
1011 | + {% if show_filter %} |
1012 | + Stack : {{ show_filter }} |
1013 | + {% else %} |
1014 | + All Stacks |
1015 | + {% endif %} |
1016 | + </h2> |
1017 | +</div> |
1018 | +<div class='grid_2'> |
1019 | + <h3 class='nav-title'> |
1020 | + |
1021 | + </h3> |
1022 | + <ul class='left_nav'> |
1023 | + <li> |
1024 | + <a href='{% url 'stacks' %}'>All</a> |
1025 | + </li> |
1026 | + {% for release in release_list %} |
1027 | + <li> |
1028 | + <a href='{% url 'stacks' %}?show={{ release }} '>{{ release }}</a> |
1029 | + </li> |
1030 | + {% endfor %} |
1031 | + </ul> |
1032 | +</div> |
1033 | +<div class="grid_13"> |
1034 | +<div id="line-chart"> |
1035 | + <svg></svg> |
1036 | +</div> |
1037 | + <table class='data-table basic wide'> |
1038 | + <thead> |
1039 | + <tr> |
1040 | + <th>Name</th> |
1041 | + <th>Projects Reporting</th> |
1042 | + <th>Line Coverage</th> |
1043 | + <th>Branch Coverage</th> |
1044 | + </tr> |
1045 | + </thead> |
1046 | + <tbody> |
1047 | + {% for stack in stack_list %} |
1048 | + <tr> |
1049 | + <td> |
1050 | + <a href='{% url 'stacks' %}{{ stack.name }}/'>{{ stack.name }}</a> |
1051 | + </td> |
1052 | + <td class='{{ stack.percent_reporting|percent_reporting_color }}'> |
1053 | + {{ stack.percent_reporting|percentage }} |
1054 | + </td> |
1055 | + <td class='num'> |
1056 | + {% if stack.last_coverage_observation.line_coverage == None %} |
1057 | + N/A |
1058 | + {% else %} |
1059 | + {{ stack.last_coverage_observation.line_coverage|percentage }}% |
1060 | + {% endif %} |
1061 | + </td> |
1062 | + <td class='num'> |
1063 | + {% if stack.last_coverage_observation.branch_coverage == None %} |
1064 | + N/A |
1065 | + {% else %} |
1066 | + {{ stack.last_coverage_observation.branch_coverage|percentage }}% |
1067 | + {% endif %} |
1068 | + </td> |
1069 | + </tr> |
1070 | + {% endfor %} |
1071 | + </tbody> |
1072 | + </table> |
1073 | +</div> |
1074 | +{% endblock %} |
1075 | |
1076 | === removed file 'gaps/templates/gaps_layout.html' |
1077 | --- gaps/templates/gaps_layout.html 2014-03-09 21:55:39 +0000 |
1078 | +++ gaps/templates/gaps_layout.html 1970-01-01 00:00:00 +0000 |
1079 | @@ -1,1 +0,0 @@ |
1080 | -{% extends "layout.html" %} |
1081 | |
1082 | === removed file 'gaps/templates/integration_list.html' |
1083 | --- gaps/templates/integration_list.html 2014-03-07 16:58:26 +0000 |
1084 | +++ gaps/templates/integration_list.html 1970-01-01 00:00:00 +0000 |
1085 | @@ -1,65 +0,0 @@ |
1086 | -{% extends "gaps_layout.html" %} |
1087 | -{% load dashboard_extras %} |
1088 | - |
1089 | -{% block page_name %}QA Coverage Dashboard{% endblock %} |
1090 | - |
1091 | -{% block content %} |
1092 | -<script type='text/javascript'> |
1093 | - //<![CDATA[ |
1094 | - $(document).ready(function() { |
1095 | - $(".data-table").dataTable({ |
1096 | - "bPaginate": false, |
1097 | - "aaSorting": [[0, 'desc']] |
1098 | - }); |
1099 | - }); |
1100 | - //]]> |
1101 | -</script> |
1102 | -<div class='grid_15'> |
1103 | - <h2> |
1104 | - Integration Testing [TBD] |
1105 | - </h2> |
1106 | -</div> |
1107 | -<div class='grid_2'> |
1108 | - <h3 class='nav-title'> |
1109 | - STACKS |
1110 | - </h3> |
1111 | - <ul class='left_nav'> |
1112 | - <li> |
1113 | - <a href='{% url stacks %}'>All</a> |
1114 | - </li> |
1115 | - </ul> |
1116 | -</div> |
1117 | -<div class='grid_13'> |
1118 | - This page is work in progress.<BR> |
1119 | - It will be used to show test results for the daily-release process |
1120 | - integration tests. |
1121 | - <table class='data-table basic wide'> |
1122 | - <thead> |
1123 | - <tr> |
1124 | - <th>Name</th> |
1125 | - <th>Release</th> |
1126 | - <th>Series</th> |
1127 | - <th>Results</th> |
1128 | - </tr> |
1129 | - </thead> |
1130 | - <tbody> |
1131 | - {% for test in test_list %} |
1132 | - <tr> |
1133 | - <td> |
1134 | - <a href='{% url stacks %}/{{ test.stack_name }}'>{{ test.stack_name }}</a> |
1135 | - </td> |
1136 | - <td> |
1137 | - {{ test.release }} |
1138 | - </td> |
1139 | - <td> |
1140 | - {{ test.series }} |
1141 | - </td> |
1142 | - <td> |
1143 | - {{ test.results }} |
1144 | - </td> |
1145 | - </tr> |
1146 | - {% endfor %} |
1147 | - </tbody> |
1148 | - </table> |
1149 | -</div> |
1150 | -{% endblock %} |
1151 | |
1152 | === removed file 'gaps/templates/job.html' |
1153 | --- gaps/templates/job.html 2014-03-07 16:58:26 +0000 |
1154 | +++ gaps/templates/job.html 1970-01-01 00:00:00 +0000 |
1155 | @@ -1,65 +0,0 @@ |
1156 | -{% extends "layout.html" %} |
1157 | -{% load dashboard_extras %} |
1158 | - |
1159 | -{% block page_name %}QA Coverage Dashboard{% endblock %} |
1160 | - |
1161 | -{% block content %} |
1162 | -<script type='text/javascript'> |
1163 | - //<![CDATA[ |
1164 | - $(document).ready(function() { |
1165 | - $(".data-table").dataTable({ |
1166 | - "bPaginate": false, |
1167 | - "aaSorting": [[0, 'desc']] |
1168 | - }); |
1169 | - }); |
1170 | - //]]> |
1171 | -</script> |
1172 | -<div class='grid_15'> |
1173 | - <h2> |
1174 | - Job: {{ job.name }} |
1175 | - </h2> |
1176 | -</div> |
1177 | -<div class='grid_2'> |
1178 | - <h3 class='nav-title'> |
1179 | - BUILD FILTER |
1180 | - </h3> |
1181 | - <ul class='left_nav'> |
1182 | - <li> |
1183 | - <a href='?show=all'>All</a> |
1184 | - </li> |
1185 | - {% for result in result_list %} |
1186 | - <li> |
1187 | - <a href='{% url jobs %}{{ job.name }}?show={{ result.name }}'>{{ result.name }}</a> |
1188 | - </li> |
1189 | - {% endfor %} |
1190 | - </ul> |
1191 | -</div> |
1192 | -<div class='grid_13'> |
1193 | -</div> |
1194 | -<div class='grid_13'> |
1195 | - <table class='data-table basic wide'> |
1196 | - <thead> |
1197 | - <tr> |
1198 | - <th>Number</th> |
1199 | - <th>Status</th> |
1200 | - <th>Timestamp</th> |
1201 | - </tr> |
1202 | - </thead> |
1203 | - <tbody> |
1204 | - {% for build in build_list %} |
1205 | - <tr> |
1206 | - <td class='num'> |
1207 | - <a href="{{ build.url }}">{{ build.number }}</a> |
1208 | - </td> |
1209 | - <td> |
1210 | - {{ build.result }} |
1211 | - </td> |
1212 | - <td> |
1213 | - {{ build.timestamp }} |
1214 | - </td> |
1215 | - </tr> |
1216 | - {% endfor %} |
1217 | - </tbody> |
1218 | - </table> |
1219 | -</div> |
1220 | -{% endblock %} |
1221 | |
1222 | === removed file 'gaps/templates/job_list.html' |
1223 | --- gaps/templates/job_list.html 2014-03-07 16:58:26 +0000 |
1224 | +++ gaps/templates/job_list.html 1970-01-01 00:00:00 +0000 |
1225 | @@ -1,96 +0,0 @@ |
1226 | -{% extends "layout.html" %} |
1227 | -{% load dashboard_extras %} |
1228 | - |
1229 | -{% block page_name %}QA Coverage Dashboard{% endblock %} |
1230 | - |
1231 | -{% block content %} |
1232 | -<script type='text/javascript'> |
1233 | - //<![CDATA[ |
1234 | - $(document).ready(function() { |
1235 | - $(".data-table").dataTable({ |
1236 | - "bPaginate": false, |
1237 | - "aaSorting": [[0, 'desc']] |
1238 | - }); |
1239 | - }); |
1240 | - //]]> |
1241 | -</script> |
1242 | -<div class='grid_15'> |
1243 | - <h2> |
1244 | - Jobs |
1245 | - </h2> |
1246 | -</div> |
1247 | -<div class='grid_2'> |
1248 | - <h3 class='nav-title'> |
1249 | - JOB FILTER |
1250 | - </h3> |
1251 | - <ul class='left_nav'> |
1252 | - <li> |
1253 | - <a href='{% url jobs %}'>All</a> |
1254 | - </li> |
1255 | - <li> |
1256 | - <a href='{% url jobs %}?show=autolanding'>Autolanding</a> |
1257 | - </li> |
1258 | - <li> |
1259 | - <a href='{% url jobs %}?show=ci'>CI</a> |
1260 | - </li> |
1261 | - <li> |
1262 | - <a href='{% url jobs %}?show=daily'>Daily</a> |
1263 | - </li> |
1264 | - <li> |
1265 | - <a href='{% url jobs %}?show=coverity'>Coverity</a> |
1266 | - </li> |
1267 | - </ul> |
1268 | -</div> |
1269 | -<div class='grid_13'> |
1270 | - <table class='data-table basic wide'> |
1271 | - <thead> |
1272 | - <tr> |
1273 | - <th>Job</th> |
1274 | - <th>Release</th> |
1275 | - <th>Arch</th> |
1276 | - <th>Date</th> |
1277 | - <th>Build</th> |
1278 | - <th>Duration</th> |
1279 | - <th>Tests</th> |
1280 | - <th>Coverage</th> |
1281 | - <th>Bugs</th> |
1282 | - </tr> |
1283 | - </thead> |
1284 | - <tbody> |
1285 | - {% for job in job_list %} |
1286 | - <tr> |
1287 | - <td> |
1288 | - <a href='job/{{ job.name }}'> |
1289 | - {{ job.name }} |
1290 | - </a> |
1291 | - </td> |
1292 | - <td> |
1293 | - {{ job.series }} |
1294 | - </td> |
1295 | - <td> |
1296 | - {{ job.arch }} |
1297 | - </td> |
1298 | - <td> |
1299 | - {{ job.last_run_date }} |
1300 | - </td> |
1301 | - <td class='num'> |
1302 | - {{ job.build_count }} |
1303 | - </td> |
1304 | - <td class='num'> |
1305 | - {{ job.duration }} |
1306 | - </td> |
1307 | - <td class='num'> |
1308 | - {{ job.test_count }} |
1309 | - </td> |
1310 | - <td class='num {{job.coverage_rate|pass_rate_color}}'> |
1311 | - {{ job.coverage_rate_pct }} |
1312 | - </td> |
1313 | - <td class='num'> |
1314 | - {{ job.bug_count }} |
1315 | - </td> |
1316 | - </tr> |
1317 | - {% endfor %} |
1318 | - </tbody> |
1319 | - </table> |
1320 | -</div> |
1321 | -{% endblock %} |
1322 | |
1323 | === removed file 'gaps/templates/main.html' |
1324 | --- gaps/templates/main.html 2014-03-07 16:58:26 +0000 |
1325 | +++ gaps/templates/main.html 1970-01-01 00:00:00 +0000 |
1326 | @@ -1,34 +0,0 @@ |
1327 | -{% extends "layout.html" %} |
1328 | -{% load dashboard_extras %} |
1329 | - |
1330 | -{% block content %} |
1331 | -<script type='text/javascript'> |
1332 | - //<![CDATA[ |
1333 | - $(document).ready(function() { |
1334 | - $(".data-table").dataTable({ |
1335 | - "bPaginate": false, |
1336 | - "aaSorting": [[0, 'desc']] |
1337 | - }); |
1338 | - }); |
1339 | - //]]> |
1340 | -</script> |
1341 | -<div class='grid_15'> |
1342 | - <ul> |
1343 | - <li> |
1344 | - <h2> |
1345 | - <a href='{% url stacks %}?show=head'>Stacks</a> |
1346 | - </h2> |
1347 | - </li> |
1348 | - <li> |
1349 | - <h2> |
1350 | - <a href='{% url projects %}'>Projects</a> |
1351 | - </h2> |
1352 | - </li> |
1353 | - <li> |
1354 | - <h2> |
1355 | - <a href='{% url integration %}'>Daily Integration [TBD]</a> |
1356 | - </h2> |
1357 | - </li> |
1358 | - </ul> |
1359 | -</div> |
1360 | -{% endblock %} |
1361 | |
1362 | === removed file 'gaps/templates/project_detail.html' |
1363 | --- gaps/templates/project_detail.html 2014-03-14 19:54:57 +0000 |
1364 | +++ gaps/templates/project_detail.html 1970-01-01 00:00:00 +0000 |
1365 | @@ -1,90 +0,0 @@ |
1366 | -{% extends "layout.html" %} |
1367 | -{% load dashboard_extras %} |
1368 | -{% load percentage %} |
1369 | -{% block extra_headers %} |
1370 | -<link type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.css" rel="stylesheet" /> |
1371 | -<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/d3/3.2.2/d3.min.js"></script> |
1372 | -<!-- need to switch back to cdnjs when bugs are fixed |
1373 | -<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.js"></script>--> |
1374 | -<script type="text/javascript" src="//6df403e3d98e2ac67ac2-180150c581869d2c4c18db9c9e3179c4.r40.cf1.rackcdn.com/nv.d3.js"></script> |
1375 | -{% endblock extra_headers %} |
1376 | - |
1377 | -{% block content %} |
1378 | -<style> |
1379 | - #line-chart svg { |
1380 | - height: 400px; |
1381 | - width: 1100px; |
1382 | - } |
1383 | -</style> |
1384 | -<script type='text/javascript'> |
1385 | - //<![CDATA[ |
1386 | - $(document).ready(function() { |
1387 | - $(".data-table").dataTable({ |
1388 | - "bPaginate": false, |
1389 | - "aaSorting": [[2, 'desc']] |
1390 | - }); |
1391 | - }); |
1392 | - //]]> |
1393 | -</script> |
1394 | -<script type="text/javascript"> |
1395 | - d3.json('{% url "gaps_api_project" project.name %}', function(data) { |
1396 | - nv.addGraph(function() { |
1397 | - var chart = nv.models.lineChart() |
1398 | - .width(1100).height(400); |
1399 | - chart.forceY([0, 1]); |
1400 | - chart.xAxis |
1401 | - .axisLabel('Date') |
1402 | - .tickFormat(function(d){return d3.time.format('%Y%m%d')(new Date(d * 1000));}) |
1403 | - |
1404 | - chart.yAxis |
1405 | - .axisLabel('%') |
1406 | - .tickFormat(d3.format('%')) |
1407 | - d3.select('#line-chart svg').datum(data).transition().duration(500).call(chart); |
1408 | - |
1409 | - nv.utils.windowResize(chart.update); |
1410 | - |
1411 | - return chart; |
1412 | - }); |
1413 | - }); |
1414 | -</script> |
1415 | -<div class='grid_15'> |
1416 | - <h2> |
1417 | - Project: {{ project.name }} |
1418 | - </h2> |
1419 | -</div> |
1420 | -<div class='grid_13'> |
1421 | - {% if coverage_datas|length > 0 %} |
1422 | - <div class="grid_13"> |
1423 | - <div id="line-chart"> |
1424 | - <svg></svg> |
1425 | - </div> |
1426 | - </div> |
1427 | - <table class='data-table basic wide'> |
1428 | - <thead> |
1429 | - <tr> |
1430 | - <th>Jenkins Build</th> |
1431 | - <th>Line Coverage</th> |
1432 | - <th>Branch Coverage</th> |
1433 | - </tr> |
1434 | - </thead> |
1435 | - <tbody> |
1436 | - {% for coverage_data in coverage_datas %} |
1437 | - <tr> |
1438 | - <td> |
1439 | - <a href='{{ coverage_data.coverage_build.url }}'>{{ coverage_data.coverage_build.ran_at }}</a> |
1440 | - </td> |
1441 | - <td class='num'> |
1442 | - {{ coverage_data.line_coverage|percentage }}% |
1443 | - </td> |
1444 | - <td class='num'> |
1445 | - {{ coverage_data.branch_coverage|percentage }}% |
1446 | - </td> |
1447 | - </tr> |
1448 | - {% endfor %} |
1449 | - </tbody> |
1450 | - </table> |
1451 | - {% else %} |
1452 | -No coverage data was found for this project. Please pursue with your QA contact or on freenode in the #ubuntu-quality channel. |
1453 | - {% endif %} |
1454 | -</div> |
1455 | -{% endblock %} |
1456 | |
1457 | === removed file 'gaps/templates/project_list.html' |
1458 | --- gaps/templates/project_list.html 2014-03-14 16:52:09 +0000 |
1459 | +++ gaps/templates/project_list.html 1970-01-01 00:00:00 +0000 |
1460 | @@ -1,201 +0,0 @@ |
1461 | -{% extends "gaps_layout.html" %} |
1462 | -{% load dashboard_extras %} |
1463 | -{% load percentage %} |
1464 | - |
1465 | -{% block content %} |
1466 | -<script type='text/javascript'> |
1467 | - //<![CDATA[ |
1468 | - $(document).ready(function() { |
1469 | - $(".data-table").dataTable({ |
1470 | - "bPaginate": false, |
1471 | - "aaSorting": [[3, 'desc'], [0, 'asc']], |
1472 | - "aoColumns": [ |
1473 | - null, |
1474 | - null, |
1475 | - {"aDataSort": [3]}, |
1476 | - {"bVisible": false}, |
1477 | - {"aDataSort": [5]}, |
1478 | - {"bVisible": false}, |
1479 | - ] |
1480 | - }); |
1481 | - }); |
1482 | - //]]> |
1483 | -</script> |
1484 | -<div class='grid_15'> |
1485 | - <h2> |
1486 | - Projects |
1487 | - </h2> |
1488 | - {% if project_list %} |
1489 | - <div class='grid_13'></div> |
1490 | - <div id='avg_chart_text' class='avg_chart_box'> |
1491 | - <div class='chart_title'>Code Coverage</div> |
1492 | - <div class='avg_chart_box'> |
1493 | - <div id='lineGaugeContainer'></div> |
1494 | - </div> |
1495 | - <div class='avg_chart_box'> |
1496 | - <div id='branchGaugeContainer'></div> |
1497 | - </div> |
1498 | - <div class='avg_chart_box'> |
1499 | - <div id='reportingGaugeContainer'></div> |
1500 | - </div> |
1501 | - </div> |
1502 | - {% endif %} |
1503 | -</div> |
1504 | -<div class='grid_2'> |
1505 | - <h3 class='nav-title'> |
1506 | - PROJECT FILTER |
1507 | - </h3> |
1508 | - <ul class='left_nav'> |
1509 | - <li> |
1510 | - <a href='{% url 'projects' %}'>All</a> |
1511 | - </li> |
1512 | - {% for release in release_list %} |
1513 | - <li> |
1514 | - <a href='{% url 'projects' %}?show={{ release }} '>{{ release }}</a> |
1515 | - </li> |
1516 | - {% endfor %} |
1517 | - </ul> |
1518 | -</div> |
1519 | -<div class='grid_13'> |
1520 | - <table class='data-table basic wide'> |
1521 | - <thead> |
1522 | - <tr> |
1523 | - <th>Name</th> |
1524 | - <th>Last Build</th> |
1525 | - <th>Line Coverage</th> |
1526 | - <th>Line Coverage Sorting Criterion</th> |
1527 | - <th>Branch Coverage</th> |
1528 | - <th>Branch Coverage Sorting Criterion</th> |
1529 | - </tr> |
1530 | - </thead> |
1531 | - <tbody> |
1532 | - {% for project in project_list %} |
1533 | - <tr> |
1534 | - <td> |
1535 | - <a href='{% url 'projects' %}{{ project.name }}'>{{ project.name }}</a> |
1536 | - </td> |
1537 | - <td> |
1538 | - {{ project.last_build.ran_at }} |
1539 | - </td> |
1540 | - <td class='num'> |
1541 | - {% if project.last_coverage_data.line_coverage == None %} |
1542 | - N/A |
1543 | - {% else %} |
1544 | - {{ project.last_coverage_data.line_coverage|percentage }}% |
1545 | - {% endif %} |
1546 | - </td> |
1547 | - <td class='num'> |
1548 | - {{ project.last_coverage_data.line_coverage|percentage }} |
1549 | - </td> |
1550 | - <td class='num'> |
1551 | - {% if project.last_coverage_data.line_coverage == None %} |
1552 | - N/A |
1553 | - {% else %} |
1554 | - {{ project.last_coverage_data.branch_coverage|percentage }}% |
1555 | - {% endif %} |
1556 | - </td> |
1557 | - <td class='num'> |
1558 | - {{ project.last_coverage_data.branch_coverage|percentage }} |
1559 | - </td> |
1560 | - </tr> |
1561 | - {% endfor %} |
1562 | - </tbody> |
1563 | - </table> |
1564 | -</div> |
1565 | -{% if project_list %} |
1566 | - {% load staticfiles %} |
1567 | - <script type="text/javascript" src='{% static "js/d3v3.js" %}'></script> |
1568 | - <script type="text/javascript" src='{% static "js/gauge.js" %}'></script> |
1569 | - <script type="text/javascript"> |
1570 | - |
1571 | - function avgLines() { |
1572 | - // project reporting list |
1573 | - var total_projects = 0; |
1574 | - var reporting_project = 0; |
1575 | - var line_sum = 0; |
1576 | - var hit_sum = 0; |
1577 | - var total_sum = 0; |
1578 | - var taken_sum = 0; |
1579 | - |
1580 | - {% for project in project_list %} |
1581 | - |
1582 | - var line_count = {{ project.ci_project.line_count|default_if_none:"0" }} + 0; |
1583 | - |
1584 | - total_projects = total_projects + 1; |
1585 | - |
1586 | - if ( line_count > 0) { |
1587 | - reporting_project = reporting_project + 1; |
1588 | - } |
1589 | - |
1590 | - line_sum = line_sum + line_count; |
1591 | - hit_sum = hit_sum + {{ project.ci_project.hit_count|default_if_none:"0" }} + 0; |
1592 | - total_sum = total_sum + {{ project.ci_project.total_count|default_if_none:"0" }} + 0; |
1593 | - taken_sum = taken_sum + {{ project.ci_project.taken_count|default_if_none:"0" }} + 0; |
1594 | - |
1595 | - {% endfor %} |
1596 | - |
1597 | - |
1598 | - line_percent = (hit_sum / line_sum) |
1599 | - branch_percent = (taken_sum / total_sum) |
1600 | - proj_report_percent = (reporting_project / total_projects) |
1601 | - return [Math.round(line_percent * 100), Math.round(branch_percent * 100), Math.round(proj_report_percent * 100)] |
1602 | -} |
1603 | - |
1604 | - var coverage_data = avgLines() |
1605 | - var gauges = []; |
1606 | - var gauge_size = 106.5; |
1607 | - function create_coverage_gauge(name, label, value) { |
1608 | - var config = |
1609 | - { |
1610 | - size: gauge_size, |
1611 | - label: label, |
1612 | - minorTicks: 5 |
1613 | - } |
1614 | - |
1615 | - config.redZones = []; |
1616 | - config.redZones.push({ from: 0, to: 50 }); |
1617 | - |
1618 | - config.yellowZones = []; |
1619 | - config.yellowZones.push({ from: 50, to: 85 }); |
1620 | - |
1621 | - config.greenZones = []; |
1622 | - config.greenZones.push = ({ from: 85, to: 100 }); |
1623 | - |
1624 | - gauges[name] = new Gauge(name + "GaugeContainer", config); |
1625 | - gauges[name].render(); |
1626 | - gauges[name].redraw(value); |
1627 | - } |
1628 | - |
1629 | - function create_proj_report_gauge(name, label, value) { |
1630 | - var config = |
1631 | - { |
1632 | - size: gauge_size, |
1633 | - label: label, |
1634 | - minorTicks: 5 |
1635 | - } |
1636 | - |
1637 | - config.redZones = []; |
1638 | - config.redZones.push({ from: 0, to: 85 }); |
1639 | - |
1640 | - config.yellowZones = []; |
1641 | - config.yellowZones.push({ from: 85, to: 95 }); |
1642 | - |
1643 | - config.greenZones = []; |
1644 | - config.greenZones.push = ({ from: 95, to: 100 }); |
1645 | - |
1646 | - gauges[name] = new Gauge(name + "GaugeContainer", config); |
1647 | - gauges[name].render(); |
1648 | - gauges[name].redraw(value); |
1649 | - } |
1650 | - |
1651 | - |
1652 | - function init_charts() { |
1653 | - create_coverage_gauge("line", "Line", coverage_data[0]) |
1654 | - create_coverage_gauge("branch", "Branch", coverage_data[1]) |
1655 | - create_proj_report_gauge("reporting", "Reporting", coverage_data[2]) |
1656 | - } |
1657 | - |
1658 | - window.onload = init_charts() |
1659 | - </script> |
1660 | -{% endif %} |
1661 | -{% endblock %} |
1662 | |
1663 | === removed file 'gaps/templates/stack_detail.html' |
1664 | --- gaps/templates/stack_detail.html 2014-03-14 16:52:09 +0000 |
1665 | +++ gaps/templates/stack_detail.html 1970-01-01 00:00:00 +0000 |
1666 | @@ -1,106 +0,0 @@ |
1667 | -{% extends "gaps_layout.html" %} |
1668 | -{% load dashboard_extras %} |
1669 | -{% load gaps_extras %} |
1670 | -{% load percentage %} |
1671 | -{% block extra_headers %} |
1672 | -<link type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.css" rel="stylesheet" /> |
1673 | -<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/d3/3.2.2/d3.min.js"></script> |
1674 | -<!-- need to switch back to cdnjs when bugs are fixed |
1675 | -<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.js"></script>--> |
1676 | -<script type="text/javascript" src="//6df403e3d98e2ac67ac2-180150c581869d2c4c18db9c9e3179c4.r40.cf1.rackcdn.com/nv.d3.js"></script> |
1677 | -{% endblock extra_headers %} |
1678 | - |
1679 | -{% block content %} |
1680 | -<style> |
1681 | - #line-chart svg { |
1682 | - height: 400px; |
1683 | - width: 1100px; |
1684 | - } |
1685 | -</style> |
1686 | -<script type='text/javascript'> |
1687 | - //<![CDATA[ |
1688 | - $(document).ready(function() { |
1689 | - $(".data-table").dataTable({ |
1690 | - "bPaginate": false, |
1691 | - "aaSorting": [[2, 'desc']] |
1692 | - }); |
1693 | - }); |
1694 | - //]]> |
1695 | -</script> |
1696 | -<script type="text/javascript"> |
1697 | - d3.json('{% url 'gaps_api_stack' stack.name %}', function(data) { |
1698 | - nv.addGraph(function() { |
1699 | - var chart = nv.models.lineChart() |
1700 | - .width(900).height(400); |
1701 | - chart.forceY([0, 1]); |
1702 | - chart.xAxis |
1703 | - .axisLabel('Date') |
1704 | - .tickFormat(function(d){return d3.time.format('%Y%m%d')(new Date(d * 1000));}) |
1705 | - chart.yAxis |
1706 | - .axisLabel('%') |
1707 | - .tickFormat(d3.format('%')) |
1708 | - d3.select('#line-chart svg').datum(data).transition().duration(500).call(chart); |
1709 | - nv.utils.windowResize(chart.update); |
1710 | - return chart; |
1711 | - }); |
1712 | - }); |
1713 | -</script> |
1714 | -<div class='grid_15'> |
1715 | - <h2> |
1716 | - Stack: {{ stack.name }} |
1717 | - </h2> |
1718 | -</div> |
1719 | -<div class='grid_2'> |
1720 | - <h3 class='nav-title'> |
1721 | - STACKS |
1722 | - </h3> |
1723 | - <ul class='left_nav'> |
1724 | - {% for stack in stack_list %} |
1725 | - <li> |
1726 | - <a href='{% url 'stacks' %}{{ stack }}'>{{ stack }}</a> |
1727 | - </li> |
1728 | - {% endfor %} |
1729 | - </ul> |
1730 | -</div> |
1731 | - <div class="grid_13"> |
1732 | - <div id="line-chart"> |
1733 | - <svg></svg> |
1734 | - </div> |
1735 | - <table class='data-table basic wide'> |
1736 | - <thead> |
1737 | - <tr> |
1738 | - <th>Name</th> |
1739 | - <th>Last Build</th> |
1740 | - <th>Line Coverage</th> |
1741 | - <th>Branch Coverage</th> |
1742 | - </tr> |
1743 | - </thead> |
1744 | - <tbody> |
1745 | - {% for project in project_list %} |
1746 | - <tr> |
1747 | - <td> |
1748 | - <a href='{% url 'projects' %}{{ project.name }}/'>{{ project.name }}</a> |
1749 | - </td> |
1750 | - <td> |
1751 | - {{ project.last_build.ran_at }} |
1752 | - </td> |
1753 | - <td class='num'> |
1754 | - {% if project.last_coverage_data.line_coverage == None %} |
1755 | - N/A |
1756 | - {% else %} |
1757 | - {{ project.last_coverage_data.line_coverage|percentage }}% |
1758 | - {% endif %} |
1759 | - </td> |
1760 | - <td class='num'> |
1761 | - {% if project.last_coverage_data.branch_coverage == None %} |
1762 | - N/A |
1763 | - {% else %} |
1764 | - {{ project.last_coverage_data.branch_coverage|percentage }}% |
1765 | - {% endif %} |
1766 | - </td> |
1767 | - </tr> |
1768 | - {% endfor %} |
1769 | - </tbody> |
1770 | - </table> |
1771 | -</div> |
1772 | -{% endblock %} |
1773 | |
1774 | === removed file 'gaps/templates/stack_list.html' |
1775 | --- gaps/templates/stack_list.html 2014-03-14 16:52:09 +0000 |
1776 | +++ gaps/templates/stack_list.html 1970-01-01 00:00:00 +0000 |
1777 | @@ -1,113 +0,0 @@ |
1778 | -{% extends "gaps_layout.html" %} |
1779 | -{% load dashboard_extras %} |
1780 | -{% load gaps_extras %} |
1781 | -{% load percentage %} |
1782 | -{% block extra_headers %} |
1783 | -<link type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.css" rel="stylesheet" /> |
1784 | -<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/d3/3.2.2/d3.min.js"></script> |
1785 | -<!-- need to switch back to cdnjs when bugs are fixed |
1786 | -<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/nvd3/0.9/nv.d3.js"></script>--> |
1787 | -<script type="text/javascript" src="//6df403e3d98e2ac67ac2-180150c581869d2c4c18db9c9e3179c4.r40.cf1.rackcdn.com/nv.d3.js"></script> |
1788 | -{% endblock extra_headers %} |
1789 | - |
1790 | -{% block content %} |
1791 | -<style> |
1792 | - #line-chart svg { |
1793 | - height: 400px; |
1794 | - width: 1100px; |
1795 | - } |
1796 | -</style> |
1797 | -<script type='text/javascript'> |
1798 | - //<![CDATA[ |
1799 | - $(document).ready(function() { |
1800 | - $(".data-table").dataTable({ |
1801 | - "bPaginate": false, |
1802 | - "aaSorting": [[0, 'desc']] |
1803 | - }); |
1804 | - }); |
1805 | - //]]> |
1806 | -</script> |
1807 | -<script type="text/javascript"> |
1808 | - d3.json('{% url 'gaps_api_stack_list' %}', function(data) { |
1809 | - nv.addGraph(function() { |
1810 | - var chart = nv.models.lineChart() |
1811 | - .width(900).height(400); |
1812 | - chart.forceY([0, 1]); |
1813 | - chart.xAxis |
1814 | - .axisLabel('Date') |
1815 | - .tickFormat(function(d){return d3.time.format('%Y%m%d')(new Date(d * 1000));}) |
1816 | - chart.yAxis |
1817 | - .axisLabel('%') |
1818 | - .tickFormat(d3.format('%')) |
1819 | - d3.select('#line-chart svg').datum(data).transition().duration(500).call(chart); |
1820 | - nv.utils.windowResize(chart.update); |
1821 | - return chart; |
1822 | - }); |
1823 | - }); |
1824 | -</script> |
1825 | -<div class='grid_15'> |
1826 | - <h2> |
1827 | - {% if show_filter %} |
1828 | - Stack : {{ show_filter }} |
1829 | - {% else %} |
1830 | - All Stacks |
1831 | - {% endif %} |
1832 | - </h2> |
1833 | -</div> |
1834 | -<div class='grid_2'> |
1835 | - <h3 class='nav-title'> |
1836 | - |
1837 | - </h3> |
1838 | - <ul class='left_nav'> |
1839 | - <li> |
1840 | - <a href='{% url 'stacks' %}'>All</a> |
1841 | - </li> |
1842 | - {% for release in release_list %} |
1843 | - <li> |
1844 | - <a href='{% url 'stacks' %}?show={{ release }} '>{{ release }}</a> |
1845 | - </li> |
1846 | - {% endfor %} |
1847 | - </ul> |
1848 | -</div> |
1849 | -<div class="grid_13"> |
1850 | -<div id="line-chart"> |
1851 | - <svg></svg> |
1852 | -</div> |
1853 | - <table class='data-table basic wide'> |
1854 | - <thead> |
1855 | - <tr> |
1856 | - <th>Name</th> |
1857 | - <th>Projects Reporting</th> |
1858 | - <th>Line Coverage</th> |
1859 | - <th>Branch Coverage</th> |
1860 | - </tr> |
1861 | - </thead> |
1862 | - <tbody> |
1863 | - {% for stack in stack_list %} |
1864 | - <tr> |
1865 | - <td> |
1866 | - <a href='{% url 'stacks' %}{{ stack.name }}/'>{{ stack.name }}</a> |
1867 | - </td> |
1868 | - <td class='{{ stack.percent_reporting|percent_reporting_color }}'> |
1869 | - {{ stack.percent_reporting|percentage }} |
1870 | - </td> |
1871 | - <td class='num'> |
1872 | - {% if stack.last_coverage_observation.line_coverage == None %} |
1873 | - N/A |
1874 | - {% else %} |
1875 | - {{ stack.last_coverage_observation.line_coverage|percentage }}% |
1876 | - {% endif %} |
1877 | - </td> |
1878 | - <td class='num'> |
1879 | - {% if stack.last_coverage_observation.branch_coverage == None %} |
1880 | - N/A |
1881 | - {% else %} |
1882 | - {{ stack.last_coverage_observation.branch_coverage|percentage }}% |
1883 | - {% endif %} |
1884 | - </td> |
1885 | - </tr> |
1886 | - {% endfor %} |
1887 | - </tbody> |
1888 | - </table> |
1889 | -</div> |
1890 | -{% endblock %} |
1891 | |
1892 | === modified file 'gaps/urls.py' |
1893 | --- gaps/urls.py 2014-03-07 21:20:19 +0000 |
1894 | +++ gaps/urls.py 2014-04-07 22:20:52 +0000 |
1895 | @@ -12,9 +12,6 @@ |
1896 | |
1897 | # You should have received a copy of the GNU Affero General Public License |
1898 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
1899 | - |
1900 | -from django.conf.urls import patterns, url |
1901 | - |
1902 | from django.conf.urls import ( |
1903 | patterns, |
1904 | url, |
1905 | |
1906 | === modified file 'gaps/views.py' |
1907 | --- gaps/views.py 2014-03-14 16:52:09 +0000 |
1908 | +++ gaps/views.py 2014-04-07 22:20:52 +0000 |
1909 | @@ -19,7 +19,7 @@ |
1910 | @BreadCrumb("Stacks") |
1911 | def stack_list(request): |
1912 | stack_list_ = CoverageStack.objects.all() |
1913 | - t = loader.get_template('stack_list.html') |
1914 | + t = loader.get_template('gaps/stack_list.html') |
1915 | c = Context({'stack_list': stack_list_, |
1916 | 'bread_crumb_trail': BreadCrumbTrail.leading_to( |
1917 | stack_list)}) |
1918 | @@ -31,7 +31,7 @@ |
1919 | stack_list = CoverageStack.objects.all() |
1920 | project_list = CoverageProject.objects.filter( |
1921 | stack__name=name) |
1922 | - t = loader.get_template('stack_detail.html') |
1923 | + t = loader.get_template('gaps/stack_detail.html') |
1924 | c = Context({'stack': stack_, |
1925 | 'stack_list': stack_list, |
1926 | 'project_list': project_list, |
1927 | @@ -42,7 +42,7 @@ |
1928 | @BreadCrumb("Projects") |
1929 | def project_list(request): |
1930 | project_list_ = CoverageProject.objects.all() |
1931 | - t = loader.get_template('project_list.html') |
1932 | + t = loader.get_template('gaps/project_list.html') |
1933 | c = Context({'project_list': project_list_, |
1934 | 'bread_crumb_trail': BreadCrumbTrail.leading_to( |
1935 | project_list)}) |
1936 | @@ -56,7 +56,7 @@ |
1937 | coverage_datas = CoverageData.objects.filter( |
1938 | coverage_build__project=project_).order_by( |
1939 | '-coverage_build__ran_at')[:10] |
1940 | - t = loader.get_template('project_detail.html') |
1941 | + t = loader.get_template('gaps/project_detail.html') |
1942 | c = Context({'project': project_, |
1943 | 'coverage_datas': coverage_datas, |
1944 | 'bread_crumb_trail': BreadCrumbTrail.leading_to( |
1945 | |
1946 | === modified file 'qa_dashboard/settings.py' |
1947 | --- qa_dashboard/settings.py 2014-03-07 00:07:26 +0000 |
1948 | +++ qa_dashboard/settings.py 2014-04-07 22:20:52 +0000 |
1949 | @@ -102,7 +102,10 @@ |
1950 | |
1951 | # URL prefix for static files. |
1952 | # Example: "http://media.lawrence.com/static/" |
1953 | -STATIC_URL = STATIC_URL_BASE + assets_revision + '/' |
1954 | + |
1955 | +#TODO CHANGE THIS BACK!!! WHEN WE MERGE BACK IN |
1956 | +#STATIC_URL = STATIC_URL_BASE + assets_revision + '/' |
1957 | +STATIC_URL = '/static/' |
1958 | |
1959 | # URL prefix for admin static files -- CSS, JavaScript and images. |
1960 | # Make sure to use a trailing slash. |
make sure to use ./manage collectstatic to make the static js files usable.