53 lines
1.9 KiB
HTML
53 lines
1.9 KiB
HTML
<div class="day-list-container">
|
|
<div
|
|
class="days-list"
|
|
cdkDropList
|
|
[ngClass]="{ 'colored-weekend-days': environment.enable_colored_weekend_days }"
|
|
[cdkDropListData]="dateChoices"
|
|
(cdkDropListDropped)="dropDayItem($event)"
|
|
>
|
|
<div class="date-choice-container" *ngFor="let choice of dateChoices; index as id">
|
|
<div class="date-choice" cdkDrag [ngClass]="{ 'day-weekend': isWeekendDay(choice.date_input) }">
|
|
<div class="top">
|
|
<label class="pull-left" for="dateChoices_{{ id }}">
|
|
{{ 'dates.element' | translate }} {{ id + 1 }}
|
|
</label>
|
|
<span class="format-helper pull-right">{{ 'dates.format_helper' | translate }}</span>
|
|
<input
|
|
[ngModel]="choice.date_object | date: 'yyyy-MM-dd'"
|
|
(ngModelChange)="convertDateInput($event, id)"
|
|
class="date-choice-item"
|
|
name="dateChoices_{{ id }}"
|
|
id="dateChoices_{{ id }}"
|
|
type="date"
|
|
/>
|
|
</div>
|
|
<hr />
|
|
<div class="bottom">
|
|
<div class="button delete-date is-block" (click)="dateChoices.splice(id, 1)">
|
|
<img class="icon" aria-hidden="true" src="assets/icons/trash.svg" />
|
|
{{ 'dates.remove' | translate }}
|
|
</div>
|
|
<div *ngIf="hasSeveralHours" class="several-times">
|
|
<br />
|
|
<app-time-list [timeSlices]="choice.timeSlices" [prefix_choice_id]="id"></app-time-list>
|
|
<!-- <div class="text-right">-->
|
|
<!-- <button (click)="addTimeToDate(choice, id)" class="button is-primary">-->
|
|
<!-- <i class="fa fa-plus"></i>-->
|
|
<!-- {{ 'dates.add_time' | translate }}-->
|
|
<!-- <i class="fa fa-clock-o"></i>-->
|
|
<!-- </button>-->
|
|
<!-- </div>-->
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="add_date">
|
|
<!-- ajouter une date-->
|
|
<button class="button is-primary is-fullwidth" (click)="addChoice()">
|
|
{{ 'dates.add' | translate }}
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|