This commit is contained in:
parent
57d37544f9
commit
2365674a97
@ -63,7 +63,7 @@
|
||||
</thead>
|
||||
<tbody ng-controller="SurveyGradesController">
|
||||
{#each questions as question (question.id)}
|
||||
<tr ng-click="showResponses()" ng-controller="ResponsesController">
|
||||
<tr>
|
||||
<td><a href="surveys/{survey.id}/responses/{question.id}">{question.title}</a></td>
|
||||
{#await question.getResponses()}
|
||||
<td colspan="2" class="text-center">
|
||||
@ -81,7 +81,7 @@
|
||||
</td>
|
||||
<td>
|
||||
{#if responses && responses.filter((r) => r.time_scored).length}
|
||||
{responses.reduce((p, c) => (p + c.score?c.score:0), 0)/responses.filter((r) => r.time_scored).length}
|
||||
{Math.trunc(responses.reduce((p, c) => (p + (c.score?c.score:0)), 0)/responses.filter((r) => r.time_scored).length*10)/10} %
|
||||
{:else}
|
||||
-- %
|
||||
{/if}
|
||||
@ -90,12 +90,6 @@
|
||||
</tr>
|
||||
{/each}
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<th colspan="2">Moyenne</th>
|
||||
<th><!--{mean}--> %</th>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
</div>
|
||||
{/await}
|
||||
|
Reference in New Issue
Block a user