funky-framadate-front/src/app/pages/voting/voting-summary/voting-summary.component.html

65 lines
2.0 KiB
HTML
Raw Normal View History

<h2 >Résumé</h2 >
<div class="preferred" >
<i class='fa fa-star' ></i >
Pour l'instant, le choix ayant reçu le plus grand nombre de votes est :
<span class='preferred-result' >
{{preferred}}
</span >
</div >
2020-01-29 17:30:39 +01:00
<table >
<thead >
<tr >
<td >
Pseudo
</td >
<td *ngFor='let choice of config.currentPoll.choices' >
{{choice.text}}
</td >
</tr >
<!-- somme des points, dont un demi point pour les "peut être" -->
2020-01-29 17:30:39 +01:00
</thead >
<tbody >
<tr
title='somme des points, dont un demi point pour les "peut être"' >
<td >
<i class='fa fa-plus-circle' ></i > points
</td >
<td *ngFor='let k of getKeys(config.currentPoll.choices_count.counts )' >
{{ 1 * (config.currentPoll.choices_count.counts[k].yes.count) + (config.currentPoll.choices_count.counts[k].yes.count ? config.currentPoll.choices_count.counts[k].maybe.count * 0.5 : 0)}}
</td >
</tr >
2020-01-29 17:30:39 +01:00
<tr
class='votes-of-the-person'
*ngFor='let voteStack of pollconfig.stacks'
>
<td >
{{voteStack.pseudo}}
2020-01-29 17:30:39 +01:00
</td >
<td *ngFor='let v of getKeys(voteStack.votes)' >
<!-- {{voteStack.votes[v].choice_id}}-->
<span *ngIf='voteStack.votes[v].value' >
{{voteStack.votes[v].value}}
</span >
</td >
</tr >
<tr class='details' >
<td >
<i class='fa fa-eye' ></i >
</td >
<td *ngFor='let k of getKeys(config.currentPoll.choices_count.counts )' >
yes {{config.currentPoll.choices_count.counts[k].yes.count}}
<br >
maybe
{{(config.currentPoll.choices_count.counts[k].yes.maybe ? config.currentPoll.choices_count.counts[k].yes.count * 0.5 : 0)}}
<br >
no {{(config.currentPoll.choices_count.counts[k].yes.maybe ? config.currentPoll.choices_count.counts[k].maybe.count * 0.5 : 0)}}
</td >
</tr >
2020-01-29 17:30:39 +01:00
</tbody >
</table >