real example of config

This commit is contained in:
tykayn 2019-08-10 11:06:13 +02:00
parent d5f71504dc
commit c048c35b9d
2 changed files with 98 additions and 88 deletions

View File

@ -4,27 +4,34 @@
titre de question
</h2>
<span class="pre-selector" i18n>
blah blah
Je veux créer un sondage
</span>
<select id="selector" name="selector">
<option value="yes">
oui
<select id="selector" name="selector" [(ngModel)]="pollConfig.poll_type">
<option value="dates">
spécial dates
</option>
<option value="no">
non
<option value="classic">
classique
</option>
</select>
<span class="post-selector">
blah blah blah.
</span>
<hr>
<label for="poll_title" class="title-label" i18n>
Dont le titre sera
</label>
<input type="text" id="poll_title" name="poll_title" [(ngModel)]="pollConfig.title">
<label for="poll_description" class="title-label" i18n>
et la description serait
</label>
<input type="text" id="poll_description" name="poll_description" [(ngModel)]="pollConfig.description" max="1000">
<hr>
<span i18n>
Choix cornélien:
</span>
<!-- todo: factoriser les boutons-->
<!-- todo: factoriser les boutons-->
<button
(click)="selectOption('poll_type' , 'classic')"
[class.active]="pollConfig.type_classic"

View File

@ -14,8 +14,11 @@ import {ProgressionService} from '../progression.service';
*/
export class FormContainerComponent implements OnInit {
// todo make a class in the config folder of this
private pollConfig: any = {
poll_type: 'classic',
title: '',
description: '',
allow_stuff: true,
};
private progressionStep = 0;