blob: 156e7713d48e7a87ee1ba64f00ae6b14c91a0502 (
plain) (
tree)
|
|
import { Component, ViewChild } from '@angular/core'
import { UserNotificationsComponent } from '@app/shared'
@Component({
templateUrl: './my-account-notifications.component.html',
styleUrls: [ './my-account-notifications.component.scss' ]
})
export class MyAccountNotificationsComponent {
@ViewChild('userNotification', { static: true }) userNotification: UserNotificationsComponent
markAllAsRead () {
this.userNotification.markAllAsRead()
}
getUnreadNotifications () {
return this.userNotification.notifications.filter(n => n.read === false).length
}
}
|