2022-10-26 16:00:20 +00:00
|
|
|
import QtQuick 2.14
|
|
|
|
|
|
|
|
QtObject {
|
|
|
|
id: root
|
|
|
|
|
|
|
|
property bool hideReadNotifications: false
|
|
|
|
|
2023-01-23 09:00:06 +00:00
|
|
|
readonly property var activityCenterModuleInst: activityCenterModule
|
2023-02-13 08:51:24 +00:00
|
|
|
readonly property var activityCenterNotifications: activityCenterModuleInst.activityNotificationsModel
|
2023-01-23 09:00:06 +00:00
|
|
|
readonly property int unreadNotificationsCount: activityCenterModuleInst.unreadActivityCenterNotificationsCount
|
2023-02-07 15:53:56 +00:00
|
|
|
readonly property bool hasUnseenNotifications: activityCenterModuleInst.hasUnseenActivityCenterNotifications
|
2022-10-26 16:00:20 +00:00
|
|
|
|
|
|
|
function markAllActivityCenterNotificationsRead() {
|
|
|
|
root.activityCenterModuleInst.markAllActivityCenterNotificationsRead()
|
|
|
|
}
|
|
|
|
|
|
|
|
function markActivityCenterNotificationRead(notification) {
|
|
|
|
root.activityCenterModuleInst.markActivityCenterNotificationRead(
|
|
|
|
notification.id, notification.message.communityId,
|
|
|
|
notification.message.chatId, notification.notificationType)
|
|
|
|
}
|
|
|
|
|
|
|
|
function markActivityCenterNotificationUnread(notification) {
|
|
|
|
root.activityCenterModuleInst.markActivityCenterNotificationUnread(
|
|
|
|
notification.id, notification.message.communityId,
|
|
|
|
notification.message.chatId, notification.notificationType)
|
|
|
|
}
|
|
|
|
|
2023-02-07 15:53:56 +00:00
|
|
|
function markAsSeenActivityCenterNotifications() {
|
|
|
|
root.activityCenterModuleInst.markAsSeenActivityCenterNotifications()
|
|
|
|
}
|
|
|
|
|
2022-10-26 16:00:20 +00:00
|
|
|
function switchTo(notification) {
|
|
|
|
root.activityCenterModuleInst.switchTo(notification.sectionId, notification.chatId, notification.id)
|
|
|
|
}
|
|
|
|
}
|