|
|
|
@ -2,72 +2,75 @@
|
|
|
|
|
<section class="poll_loaded padded" *ngIf="!fetching && poll">
|
|
|
|
|
<!-- messages-->
|
|
|
|
|
|
|
|
|
|
<article class="message is-warning" *ngIf="isArchived">
|
|
|
|
|
<div class="message is-warning" *ngIf="isArchived">
|
|
|
|
|
<div class="message-body">
|
|
|
|
|
⚰️ Ce sondage a expiré, il n'est plus possible d'y ajouter de votes ou de commentaires
|
|
|
|
|
</div>
|
|
|
|
|
</article>
|
|
|
|
|
<article class="message is-info" *ngIf="poll.stacks.length == 0">
|
|
|
|
|
<div class="message-body">
|
|
|
|
|
aucun vote pour le moment
|
|
|
|
|
</div>
|
|
|
|
|
</article>
|
|
|
|
|
<article class="message is-info" *ngIf="poll.modification_policy == 'self'">
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="message is-info" *ngIf="poll.modification_policy == 'self'">
|
|
|
|
|
<div class="message-body">
|
|
|
|
|
Vous ne pouvez modifier que votre propre vote à ce sondage
|
|
|
|
|
</div>
|
|
|
|
|
</article>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<!-- actions-->
|
|
|
|
|
|
|
|
|
|
<div id="export_and_share">
|
|
|
|
|
<div class="sharing" *ngIf="poll">
|
|
|
|
|
<div class="margin-top-x8">
|
|
|
|
|
Partager le sondage
|
|
|
|
|
|
|
|
|
|
<i class="fa fa-share" aria-hidden="true"></i>
|
|
|
|
|
</div>
|
|
|
|
|
<p class="nobold text-14" for="copyLink">
|
|
|
|
|
<a href="{{ pollService.getParticipationUrl() }}">
|
|
|
|
|
{{ pollService.getParticipationUrl() }}
|
|
|
|
|
</a>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<app-copy-text [textToCopy]="pollService.getParticipationUrl()"></app-copy-text>
|
|
|
|
|
<div class="ui-card-subtitle">
|
|
|
|
|
Exporter/Imprimer
|
|
|
|
|
</div>
|
|
|
|
|
<button class="replicate duplicate btn" (click)="duplicate()">
|
|
|
|
|
<i class="fa fa-copy" aria-hidden="true"></i>
|
|
|
|
|
Dupliquer
|
|
|
|
|
</button>
|
|
|
|
|
<button class="export export-csv btn" (click)="exportCSV()">
|
|
|
|
|
<i class="fa fa-file-calc-o" aria-hidden="true"></i>
|
|
|
|
|
Exporter en .csv
|
|
|
|
|
</button>
|
|
|
|
|
<button class="export export-json btn" (click)="exportJson()">
|
|
|
|
|
<i class="fa fa-file-archive-o" aria-hidden="true"></i>
|
|
|
|
|
export json
|
|
|
|
|
</button>
|
|
|
|
|
<button class="export export-print btn" (click)="print()">
|
|
|
|
|
<i class="fa fa-print"></i>
|
|
|
|
|
Imprimer le sondage
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<!-- affichage des possibilités de réponse -->
|
|
|
|
|
<div class="columns">
|
|
|
|
|
<div class="column">
|
|
|
|
|
<div class="card">
|
|
|
|
|
<header class="card-header">
|
|
|
|
|
<p class="card-header-title is-1 title">{{ poll.title }}</p>
|
|
|
|
|
<div class="voters-count padded"><i class="fa fa-users"></i> {{ poll.stacks.length }} votants</div>
|
|
|
|
|
<!-- <p class="card-header-icon">author : {{ poll.owner?.pseudo }}</p>-->
|
|
|
|
|
<header class="card-header padded">
|
|
|
|
|
<div class="columns">
|
|
|
|
|
<div class="column">
|
|
|
|
|
<p class="card-header-title is-1 title">{{ poll.title }}</p>
|
|
|
|
|
<p class="descr">{{ poll.description }}</p>
|
|
|
|
|
<div class="voters-count padded">
|
|
|
|
|
<i class="fa fa-users"></i> {{ poll.stacks.length }} votants
|
|
|
|
|
</div>
|
|
|
|
|
<p class="card-header-icon" *ngIf="poll.owner">author : {{ poll.owner?.pseudo }}</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="column">
|
|
|
|
|
<button class="export export-print btn" (click)="print()">
|
|
|
|
|
<i class="fa fa-print"></i>
|
|
|
|
|
Imprimer le sondage
|
|
|
|
|
</button>
|
|
|
|
|
<button class="export export-csv btn" (click)="exportCSV()">
|
|
|
|
|
<i class="fa fa-file-calc-o" aria-hidden="true"></i>
|
|
|
|
|
Exporter en .csv
|
|
|
|
|
</button>
|
|
|
|
|
<button class="export export-json btn" (click)="exportJson()">
|
|
|
|
|
<i class="fa fa-file-archive-o" aria-hidden="true"></i>
|
|
|
|
|
export json
|
|
|
|
|
</button>
|
|
|
|
|
|
|
|
|
|
<button class="replicate duplicate btn" (click)="duplicate()">
|
|
|
|
|
<i class="fa fa-copy" aria-hidden="true"></i>
|
|
|
|
|
Dupliquer
|
|
|
|
|
</button>
|
|
|
|
|
|
|
|
|
|
<div id="export_and_share">
|
|
|
|
|
<div class="sharing" *ngIf="poll">
|
|
|
|
|
<div class="margin-top-x8">
|
|
|
|
|
Partager le sondage
|
|
|
|
|
|
|
|
|
|
<i class="fa fa-share" aria-hidden="true"></i>
|
|
|
|
|
</div>
|
|
|
|
|
<p class="nobold text-14" for="copyLink">
|
|
|
|
|
<a href="{{ pollService.getParticipationUrl() }}">
|
|
|
|
|
{{ pollService.getParticipationUrl() }} </a
|
|
|
|
|
><app-copy-text
|
|
|
|
|
[textToCopy]="pollService.getParticipationUrl()"
|
|
|
|
|
></app-copy-text>
|
|
|
|
|
</p>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</header>
|
|
|
|
|
|
|
|
|
|
<div class="card-content">
|
|
|
|
|
<div class="content">
|
|
|
|
|
<p class="descr">{{ poll.description }}</p>
|
|
|
|
|
<button
|
|
|
|
|
class="btn is-info"
|
|
|
|
|
(click)="isCompactMode = !isCompactMode"
|
|
|
|
@ -87,12 +90,41 @@
|
|
|
|
|
<app-poll-results-detailed *ngIf="!isCompactMode" [poll]="poll"></app-poll-results-detailed>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<!-- static buttons-->
|
|
|
|
|
<div class="padded">
|
|
|
|
|
<div class="message is-info" *ngIf="poll.stacks.length == 0">
|
|
|
|
|
<div class="message-body">
|
|
|
|
|
aucun vote pour le moment
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<button
|
|
|
|
|
class="btn btn-block submit-votestack"
|
|
|
|
|
(click)="addVoteStack()"
|
|
|
|
|
[disabled]="!myTempVoteStack"
|
|
|
|
|
[ngClass]="{ 'btn--primary': myTempVoteStack }"
|
|
|
|
|
*ngIf="!storageService.vote_stack || !storageService.vote_stack.id"
|
|
|
|
|
>
|
|
|
|
|
<i class="fa fa-paper-plane" aria-hidden="true"></i> Envoyer
|
|
|
|
|
|
|
|
|
|
<!-- {{ storageService.vote_stack.votes.length }} réponses-->
|
|
|
|
|
</button>
|
|
|
|
|
<button
|
|
|
|
|
class="btn btn--primary btn-block submit-votestack update"
|
|
|
|
|
(click)="updateVoteStack()"
|
|
|
|
|
*ngIf="storageService.vote_stack && storageService.vote_stack.id"
|
|
|
|
|
>
|
|
|
|
|
<i class="fa fa-edit" aria-hidden="true"></i> Mettre à jour
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="columns">
|
|
|
|
|
<div class="column">
|
|
|
|
|
<app-comments [poll]="poll" [vote_stack]="storageService.vote_stack"></app-comments>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<!-- fixed bottom buttons-->
|
|
|
|
|
<div class="bar-votestack" *ngIf="!isArchived">
|
|
|
|
|
<button
|
|
|
|
|
class="btn btn-block submit-votestack"
|
|
|
|
@ -103,7 +135,7 @@
|
|
|
|
|
>
|
|
|
|
|
<i class="fa fa-paper-plane" aria-hidden="true"></i> Envoyer
|
|
|
|
|
|
|
|
|
|
{{ storageService.vote_stack.votes.length }} réponses
|
|
|
|
|
<!-- {{ storageService.vote_stack.votes.length }} réponses-->
|
|
|
|
|
</button>
|
|
|
|
|
<button
|
|
|
|
|
class="btn btn--primary btn-block submit-votestack update"
|
|
|
|
|