forked from tykayn/funky-framadate-front
⚡ add email to creation
This commit is contained in:
parent
2720b65962
commit
7c64f1f8f0
@ -47,13 +47,14 @@ export const defaultAnswers = [{
|
|||||||
*/
|
*/
|
||||||
export class PollConfig {
|
export class PollConfig {
|
||||||
expiracyDateDefaultInDays = 60;
|
expiracyDateDefaultInDays = 60;
|
||||||
|
deletionDateAfterLastModification = 180;
|
||||||
step = 0;
|
step = 0;
|
||||||
stepMax = 3;
|
stepMax = 3;
|
||||||
pollType = 'classic';// classic or date
|
pollType = 'classic';// classic or date
|
||||||
title = 'titre';
|
title = 'titre';
|
||||||
description = 'ma description';
|
description = 'ma description';
|
||||||
myName = 'mon pseudo';
|
myName = 'mon pseudo';
|
||||||
|
myEmail: string = "";
|
||||||
// date specific poll, we have the choice to setup different hours (timeList) for all possible dates (dateList), or use the same hours for all dates
|
// date specific poll, we have the choice to setup different hours (timeList) for all possible dates (dateList), or use the same hours for all dates
|
||||||
allowSeveralHours = 'false';
|
allowSeveralHours = 'false';
|
||||||
// access
|
// access
|
||||||
|
@ -7,27 +7,31 @@
|
|||||||
|
|
||||||
Votre sondage «
|
Votre sondage «
|
||||||
<span class="poll-title">
|
<span class="poll-title">
|
||||||
{{config.title}} </span>
|
{{config.title}}
|
||||||
|
</span>
|
||||||
» a bien été créé !
|
» a bien été créé !
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
Voici les liens d’accès au sondage, conservez-les soigneusement !
|
Voici les liens d’accès au sondage, conservez-les soigneusement !
|
||||||
|
(Si vous les perdez vous pourrez toujours les recevoir par email)
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
Pour accéder au sondage et à tous ses paramètres : https://framadate.org/urladmindusondage
|
Pour accéder au sondage et à tous ses paramètres : {{config.urlAdmin}}
|
||||||
</p>
|
</p>
|
||||||
<button
|
<button
|
||||||
class="btn"
|
class="btn"
|
||||||
(click)="copyLink(adminLink)"
|
(click)="copyLink(config.urlAdmin)"
|
||||||
>
|
>
|
||||||
|
<i class="fa fa-copy"></i>
|
||||||
Copier le lien
|
Copier le lien
|
||||||
</button>
|
</button>
|
||||||
<a href="{{adminLink}}">
|
<a href="{{config.urlAdmin}}">
|
||||||
Voir le sondage coté administrateur·ice
|
Voir le sondage coté administrateur·ice
|
||||||
</a>
|
</a>
|
||||||
<p class="note">
|
<p class="note">
|
||||||
Note : Le sondage sera supprimé 180 jours après la date de sa dernière modification.
|
Note : Le sondage sera supprimé {{config.deletionDateAfterLastModification}} jours après la date de sa dernière
|
||||||
|
modification.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
|
||||||
@ -36,15 +40,16 @@
|
|||||||
|
|
||||||
<h2 i18n>{{"resume.users"|translate}}</h2>
|
<h2 i18n>{{"resume.users"|translate}}</h2>
|
||||||
<p>
|
<p>
|
||||||
Pour accéder au sondage : https://framadate.org/urladmindusondage
|
Pour accéder au sondage : {{config.urlPublic}}
|
||||||
</p>
|
</p>
|
||||||
<button
|
<button
|
||||||
class="btn"
|
class="btn"
|
||||||
(click)="copyLink(publicLink)"
|
(click)="copyLink(config.urlPublic)"
|
||||||
>
|
>
|
||||||
|
<i class="fa fa-copy"></i>
|
||||||
Copier le lien
|
Copier le lien
|
||||||
</button>
|
</button>
|
||||||
<a href="{{publicLink}}">
|
<a href="{{config.urlPublic}}">
|
||||||
Voir le sondage
|
Voir le sondage
|
||||||
</a>
|
</a>
|
||||||
</section>
|
</section>
|
||||||
@ -60,15 +65,16 @@
|
|||||||
[(ngModel)]="mailToRecieve"
|
[(ngModel)]="mailToRecieve"
|
||||||
paceholder="email"
|
paceholder="email"
|
||||||
>
|
>
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<button
|
<button
|
||||||
class="btn"
|
class="btn"
|
||||||
(click)="sendToEmail()"
|
(click)="sendToEmail()"
|
||||||
>
|
><i class="fa fa-paper-plane"></i>
|
||||||
Envoyer les liens du sondage
|
Envoyer les liens du sondage
|
||||||
</button>
|
</button>
|
||||||
<a href="{{publicLink}}">
|
<a href="{{config.urlPublic}}">
|
||||||
Voir le sondage
|
Voir le sondage
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
|
@ -9,18 +9,17 @@ import {ConfigService} from "../../services/config.service";
|
|||||||
styleUrls: ['./end-confirmation.component.scss']
|
styleUrls: ['./end-confirmation.component.scss']
|
||||||
})
|
})
|
||||||
export class EndConfirmationComponent extends BaseComponent implements OnInit {
|
export class EndConfirmationComponent extends BaseComponent implements OnInit {
|
||||||
public adminLink = '';
|
|
||||||
public publicLink = '';
|
|
||||||
mailToRecieve = '';
|
mailToRecieve = '';
|
||||||
|
|
||||||
constructor(public config: ConfigService, public http: HttpClient) {
|
constructor(public config: ConfigService, public http: HttpClient) {
|
||||||
super(config);
|
super(config);
|
||||||
|
this.mailToRecieve = this.config.myEmail;
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
}
|
}
|
||||||
|
|
||||||
copyLink(adminLink: any) {
|
copyLink(str: any) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,79 +1,92 @@
|
|||||||
<div class="description">
|
<div class="description">
|
||||||
<router-outlet></router-outlet>
|
<router-outlet></router-outlet>
|
||||||
<h1 i18n>
|
<h1 i18n>
|
||||||
{{"creation.title"|translate}}
|
{{"creation.title"|translate}}
|
||||||
</h1>
|
</h1>
|
||||||
<span
|
<span
|
||||||
class="pre-selector"
|
class="pre-selector"
|
||||||
i18n
|
i18n
|
||||||
>
|
>
|
||||||
{{"creation.want"|translate}}
|
{{"creation.want"|translate}}
|
||||||
</span>
|
</span>
|
||||||
<select
|
<select
|
||||||
id="selector"
|
[(ngModel)]="config.pollType"
|
||||||
name="selector"
|
autofocus="autofocus"
|
||||||
autofocus="autofocus"
|
id="selector"
|
||||||
[(ngModel)]="config.pollType"
|
name="selector"
|
||||||
>
|
>
|
||||||
<option value="dates">
|
<option value="dates">
|
||||||
{{"creation.kind.date"|translate}}
|
{{"creation.kind.date"|translate}}
|
||||||
</option>
|
</option>
|
||||||
<option value="classic">
|
<option value="classic">
|
||||||
{{"creation.kind.classic"|translate}}
|
{{"creation.kind.classic"|translate}}
|
||||||
</option>
|
</option>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<span class="post-selector">
|
<span class="post-selector">
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
|
|
||||||
<label
|
<label
|
||||||
for="poll_title"
|
class="title-label"
|
||||||
class="title-label"
|
for="poll_title"
|
||||||
i18n
|
i18n
|
||||||
>
|
>
|
||||||
{{"creation.choose_title"|translate}}
|
{{"creation.choose_title"|translate}}
|
||||||
</label>
|
</label>
|
||||||
<input
|
<input
|
||||||
type="name"
|
[(ngModel)]="config.title"
|
||||||
id="poll_title"
|
id="poll_title"
|
||||||
name="poll_title"
|
name="poll_title"
|
||||||
placeholder="{{'creation.choose_title_placeholder'|translate}}"
|
placeholder="{{'creation.choose_title_placeholder'|translate}}"
|
||||||
[(ngModel)]="config.title"
|
type="name"
|
||||||
>
|
>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="my_name">
|
<label for="my_name">
|
||||||
{{"creation.name"|translate}} :
|
{{"creation.name"|translate}} :
|
||||||
</label>
|
</label>
|
||||||
<input
|
<input
|
||||||
type="name"
|
[(ngModel)]="config.myName"
|
||||||
name="my_name"
|
id="my_name"
|
||||||
id="my_name"
|
name="my_name"
|
||||||
placeholder="{{'creation.name_placeholder'|translate}}"
|
placeholder="{{'creation.name_placeholder'|translate}}"
|
||||||
[(ngModel)]="config.myName"
|
type="name"
|
||||||
>
|
>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label
|
<label
|
||||||
for="poll_description"
|
class="title-label"
|
||||||
class="title-label"
|
for="poll_description"
|
||||||
i18n
|
i18n
|
||||||
>
|
>
|
||||||
{{"creation.description"|translate}}
|
{{"creation.description"|translate}}
|
||||||
</label>
|
</label>
|
||||||
<textarea
|
<textarea
|
||||||
id="poll_description"
|
[(ngModel)]="config.description"
|
||||||
name="poll_description"
|
cols="50"
|
||||||
[(ngModel)]="config.description"
|
id="poll_description"
|
||||||
placeholder="description"
|
lines="5"
|
||||||
cols="50"
|
name="poll_description"
|
||||||
lines="5"
|
placeholder="description"
|
||||||
></textarea>
|
></textarea>
|
||||||
</div>
|
</div>
|
||||||
|
<div>
|
||||||
|
<label for="email">
|
||||||
|
Mon email pour administrer le sondage est
|
||||||
|
</label>
|
||||||
|
<input
|
||||||
|
[(ngModel)]="config.myEmail"
|
||||||
|
autofocus="autofocus"
|
||||||
|
id="email"
|
||||||
|
name="mail"
|
||||||
|
required="required"
|
||||||
|
type="email"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
|
||||||
<button
|
<button
|
||||||
[routerLink]="'/step/answers'"
|
[routerLink]="'/step/answers'"
|
||||||
@ -88,6 +101,6 @@
|
|||||||
i18n
|
i18n
|
||||||
>
|
>
|
||||||
Retour
|
Retour
|
||||||
</a>
|
</a>
|
||||||
<hr>
|
<hr>
|
||||||
</div>
|
</div>
|
||||||
|
@ -11,7 +11,7 @@ import {MessageService} from 'primeng/api';
|
|||||||
providedIn: 'root'
|
providedIn: 'root'
|
||||||
})
|
})
|
||||||
export class ConfigService extends PollConfig {
|
export class ConfigService extends PollConfig {
|
||||||
myEmail: string;
|
|
||||||
loading: boolean = false;
|
loading: boolean = false;
|
||||||
baseHref: any = environment.baseApiHref;
|
baseHref: any = environment.baseApiHref;
|
||||||
myPolls: any;// list of retrieved polls from the backend api
|
myPolls: any;// list of retrieved polls from the backend api
|
||||||
|
Loading…
Reference in New Issue
Block a user