Modified some views, routes and models to work with the new many-to-many for tests and benchmarks
This commit is contained in:
@ -23,8 +23,8 @@
|
||||
|
||||
<div class="four columns">
|
||||
<label>
|
||||
Benchmark:
|
||||
<select class="u-full-width" name="test_benchmark">
|
||||
Benchmarks:
|
||||
<select class="u-full-width" name="test_benchmarks" multiple>
|
||||
{% for b in benchmarks %}
|
||||
<option value="{{ b.id }}">{{ b.name }}</option>
|
||||
{% endfor %}
|
||||
|
@ -10,9 +10,8 @@
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Test title</th>
|
||||
<th>Benchmark</th>
|
||||
<th>Hardware</th>
|
||||
<th># of Results</th>
|
||||
<th># of benchmarks</th>
|
||||
<th>Last updated</th>
|
||||
</tr>
|
||||
</thead>
|
||||
@ -20,9 +19,8 @@
|
||||
{% for t in tests %}
|
||||
<tr>
|
||||
<td><a href="{{ url_for('test.view', { test_id: t.id }) }}">{{ t.title }}</a></td>
|
||||
<td>{{ t.benchmark.name }}</td>
|
||||
<td>{{ t.component.name }}</td>
|
||||
<td>{{ t.results | length }}</td>
|
||||
<td>{{ t.benchmarks() | length }}</td>
|
||||
<td>{{ t.updated_at | date("F jS \\a\\t g:ia") }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
|
@ -7,6 +7,11 @@
|
||||
<div class="twelve columns">
|
||||
<h1>{{ test.title }}</h1>
|
||||
<p>{{ test.description }}</p>
|
||||
<ul>
|
||||
{% for b in test.benchmarks %}
|
||||
<li>{{ b.name }}</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -33,8 +38,8 @@
|
||||
{% for r in test.results %}
|
||||
<tr>
|
||||
<td>{{ test.component().name }}</td>
|
||||
<td>{{ test.benchmark().name }}</td>
|
||||
<td>{{ test.scoring | capitalize }}</td>
|
||||
<td>{{ r.benchmark().name }}</td>
|
||||
<td>{{ r.benchmark().scoring | capitalize }}</td>
|
||||
<td>{{ r.average }}</td>
|
||||
<td>{{ r.minimum ? r.minimum : 'N/a' }}</td>
|
||||
<td>{{ r.maximum ? r.maximum : 'N/a' }}</td>
|
||||
@ -43,7 +48,7 @@
|
||||
</tbody>
|
||||
</table>
|
||||
{% else %}
|
||||
<p>There are no results associated with this.</p>
|
||||
<p>There are no results associated with this test.</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user