Projekt

Obecné

Profil

Stáhnout (1.82 KB) Statistiky
| Větev: | Tag: | Revize:
1 0d1b0550 Václav Jirák
<div class="day-picker-container">
2
  <div class="row text-center day-picker-month-selection">
3
    <div class="col-4"></div>
4
    <div class="col-1">
5 0e8e77b3 Václav Jirák
      <button
6
        mat-icon-button
7
        mwlCalendarPreviousView
8
        [view]="view"
9
        [(viewDate)]="viewDate"
10
        (click)="setMonth(currentMonth - 1)"
11 0d1b0550 Václav Jirák
      >
12 0e8e77b3 Václav Jirák
        <i class="material-icons change-month">navigate_before</i>
13
      </button>
14 0d1b0550 Václav Jirák
    </div>
15
    <div class="col-2">
16
      <span id="day-picker-date">{{ viewDate | calendarDate:(view + 'ViewTitle'):locale }}</span>
17
    </div>
18
    <div class="col-1">
19 0e8e77b3 Václav Jirák
      <button
20
        mat-icon-button
21
        mwlCalendarNextView
22
        [view]="view"
23
        [(viewDate)]="viewDate"
24
        (click)="setMonth(currentMonth + 1)"
25 0d1b0550 Václav Jirák
      >
26 0e8e77b3 Václav Jirák
        <i class="material-icons change-month">navigate_next</i>
27
      </button>
28 0d1b0550 Václav Jirák
      <div class="col-4"></div>
29
    </div>
30
  </div>
31
32
  <mwl-calendar-month-view
33
    [viewDate]="viewDate"
34
    [locale]="locale"
35 696f3358 Václav Jirák
    [refresh]="refresh"
36 0e8e77b3 Václav Jirák
    [events]="events"
37
    [cellTemplate]="customCellTemplate"
38
    (dayClicked)="dayClicked($event.day)"
39
    weekStartsOn="1"
40 0d1b0550 Václav Jirák
  >
41
  </mwl-calendar-month-view>
42 0e8e77b3 Václav Jirák
43
  <ng-template #customCellTemplate let-day="day" let-locale="locale">
44
    <div class="cal-cell-top">
45
      <span class="cal-day-number">
46
        {{ day.date | calendarDate:'monthViewDayNumber':locale }}
47
      </span>
48
    </div>
49
      <span class="vacation-type" *ngFor="let event of day.events">
50
        <i class="material-icons sickday" *ngIf="event.title == vacationType.SICKDAY">local_hospital</i>
51
        <i class="material-icons vacation" *ngIf="event.title == vacationType.VACATION">beach_access</i>
52
53 696f3358 Václav Jirák
        <span class="time-interval" *ngIf="event.title == vacationType.VACATION">
54
          {{ event.start | date:'HH:mm' }} - {{ event.end | date:'HH:mm' }}
55
        </span>
56 0e8e77b3 Václav Jirák
      </span>
57
  </ng-template>
58 0d1b0550 Václav Jirák
</div>