feat(ActivityCenter): Fix unreadNotificationsCount availability on every section
Close #7674
This commit is contained in:
parent
1784a98df3
commit
9d103e5b07
|
@ -26,6 +26,7 @@ import "stores"
|
||||||
|
|
||||||
StatusSectionLayout {
|
StatusSectionLayout {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
property var globalStore
|
property var globalStore
|
||||||
property var sendTransactionModal
|
property var sendTransactionModal
|
||||||
|
|
||||||
|
@ -34,7 +35,9 @@ StatusSectionLayout {
|
||||||
tab.item.url = _internal.determineRealURL(url)
|
tab.item.url = _internal.determineRealURL(url)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
notificationCount: root.globalStore.unreadNotificationsCount
|
||||||
onNotificationButtonClicked: Global.openActivityCenterPopup()
|
onNotificationButtonClicked: Global.openActivityCenterPopup()
|
||||||
|
|
||||||
QtObject {
|
QtObject {
|
||||||
id: _internal
|
id: _internal
|
||||||
|
|
||||||
|
|
|
@ -21,6 +21,8 @@ QtObject {
|
||||||
property var advancedModule: profileSectionModule.advancedModule
|
property var advancedModule: profileSectionModule.advancedModule
|
||||||
property bool isCommunityHistoryArchiveSupportEnabled: advancedModule? advancedModule.isCommunityHistoryArchiveSupportEnabled : false
|
property bool isCommunityHistoryArchiveSupportEnabled: advancedModule? advancedModule.isCommunityHistoryArchiveSupportEnabled : false
|
||||||
|
|
||||||
|
property var activityCenterModuleInst: activityCenterModule
|
||||||
|
property var activityCenterList: activityCenterModuleInst.activityNotificationsModel
|
||||||
property int unreadNotificationsCount: activityCenterList.unreadCount
|
property int unreadNotificationsCount: activityCenterList.unreadCount
|
||||||
// TODO: Could the backend provide directly 2 filtered models??
|
// TODO: Could the backend provide directly 2 filtered models??
|
||||||
//property var featuredCommunitiesModel: root.communitiesModuleInst.curatedFeaturedCommunities
|
//property var featuredCommunitiesModel: root.communitiesModuleInst.curatedFeaturedCommunities
|
||||||
|
|
|
@ -5,7 +5,10 @@ import utils 1.0
|
||||||
QtObject {
|
QtObject {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
|
property var activityCenterModuleInst: activityCenterModule
|
||||||
|
property var activityCenterList: activityCenterModuleInst.activityNotificationsModel
|
||||||
property int unreadNotificationsCount: activityCenterList.unreadCount
|
property int unreadNotificationsCount: activityCenterList.unreadCount
|
||||||
|
|
||||||
property var nodeModelInst: nodeModel
|
property var nodeModelInst: nodeModel
|
||||||
// property var profileModelInst: profileModel
|
// property var profileModelInst: profileModel
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,11 @@ import AppLayouts.Chat.stores 1.0
|
||||||
|
|
||||||
QtObject {
|
QtObject {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
property string backButtonName
|
property string backButtonName
|
||||||
|
|
||||||
|
property var activityCenterModuleInst: activityCenterModule
|
||||||
|
property var activityCenterList: activityCenterModuleInst.activityNotificationsModel
|
||||||
property int unreadNotificationsCount: activityCenterList.unreadCount
|
property int unreadNotificationsCount: activityCenterList.unreadCount
|
||||||
|
|
||||||
property var aboutModuleInst: aboutModule
|
property var aboutModuleInst: aboutModule
|
||||||
|
|
|
@ -9,7 +9,6 @@ QtObject {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
property string backButtonName: ""
|
property string backButtonName: ""
|
||||||
property int unreadNotificationsCount: activityCenterList.unreadCount
|
|
||||||
property var currentAccount: Constants.isCppApp ? walletSectionAccounts.currentAccount: walletSectionCurrent
|
property var currentAccount: Constants.isCppApp ? walletSectionAccounts.currentAccount: walletSectionCurrent
|
||||||
property var accounts: walletSectionAccounts.model
|
property var accounts: walletSectionAccounts.model
|
||||||
property var generatedAccounts: walletSectionAccounts.generated
|
property var generatedAccounts: walletSectionAccounts.generated
|
||||||
|
@ -24,6 +23,10 @@ QtObject {
|
||||||
property string signingPhrase: walletSection.signingPhrase
|
property string signingPhrase: walletSection.signingPhrase
|
||||||
property string mnemonicBackedUp: walletSection.isMnemonicBackedUp
|
property string mnemonicBackedUp: walletSection.isMnemonicBackedUp
|
||||||
|
|
||||||
|
property var activityCenterModuleInst: activityCenterModule
|
||||||
|
property var activityCenterList: activityCenterModuleInst.activityNotificationsModel
|
||||||
|
property int unreadNotificationsCount: activityCenterList.unreadCount
|
||||||
|
|
||||||
property var walletTokensModule: walletSectionAllTokens
|
property var walletTokensModule: walletSectionAllTokens
|
||||||
property var tokens: walletSectionAllTokens.all
|
property var tokens: walletSectionAllTokens.all
|
||||||
|
|
||||||
|
|
|
@ -14,6 +14,10 @@ QtObject {
|
||||||
property var communitiesModuleInst: communitiesModule
|
property var communitiesModuleInst: communitiesModule
|
||||||
property var observedCommunity: communitiesModuleInst.observedCommunity
|
property var observedCommunity: communitiesModuleInst.observedCommunity
|
||||||
|
|
||||||
|
property var activityCenterModuleInst: activityCenterModule
|
||||||
|
property var activityCenterList: activityCenterModuleInst.activityNotificationsModel
|
||||||
|
property int unreadNotificationsCount: activityCenterList.unreadCount
|
||||||
|
|
||||||
property bool newVersionAvailable: false
|
property bool newVersionAvailable: false
|
||||||
property string latestVersion
|
property string latestVersion
|
||||||
property string downloadURL
|
property string downloadURL
|
||||||
|
|
|
@ -88,7 +88,7 @@ Item {
|
||||||
|
|
||||||
StatusToolTip {
|
StatusToolTip {
|
||||||
visible: hideReadNotificationsBtn.hovered
|
visible: hideReadNotificationsBtn.hovered
|
||||||
offset: hideReadNotificationsBtn.width
|
offset: width / 4
|
||||||
text: root.hideReadNotifications ? qsTr("Show read notifications") : qsTr("Hide read notifications")
|
text: root.hideReadNotifications ? qsTr("Show read notifications") : qsTr("Hide read notifications")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,7 @@ Item {
|
||||||
|
|
||||||
Loader {
|
Loader {
|
||||||
id: badgeLoader
|
id: badgeLoader
|
||||||
anchors.top: bodyLoader.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: 61 // TODO find a way to align with the text of the message
|
anchors.leftMargin: 61 // TODO find a way to align with the text of the message
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue