aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+my-account/my-account-settings/my-account-notification-preferences/my-account-notification-preferences.component.html
blob: 46f5e5d6b1273f97001930aba2247471ebbd65e1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<div *ngIf="webNotifications">
  <ng-container *ngFor="let group of notificationSettingGroups">
    <div class="header notification-row">
      <div i18n>{{ group.label }}</div>
      <div i18n>Web</div>
      <div i18n *ngIf="emailEnabled">Email</div>
    </div>

    <ng-container *ngFor="let notificationType of group.keys">
      <div class="small notification-row" *ngIf="hasUserRight(notificationType)">
        <div>{{ labelNotifications[notificationType] }}</div>

        <div>
          <my-input-switch
            [(ngModel)]="webNotifications[notificationType]"
            (ngModelChange)="updateWebSetting(notificationType, webNotifications[notificationType])"
          ></my-input-switch>
        </div>

        <div *ngIf="emailEnabled">
          <my-input-switch
            [(ngModel)]="emailNotifications[notificationType]"
            (ngModelChange)="updateEmailSetting(notificationType, emailNotifications[notificationType])"
          ></my-input-switch>
        </div>
      </div>
    </ng-container>
  </ng-container>
</div>