mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-17 22:57:21 +01:00
fix #10756: do not show push notification settings for email only notifications
This commit is contained in:
@@ -32,7 +32,7 @@
|
|||||||
td
|
td
|
||||||
input(type='checkbox', v-model='user.preferences.emailNotifications[notification]',
|
input(type='checkbox', v-model='user.preferences.emailNotifications[notification]',
|
||||||
@change='set("emailNotifications", notification)')
|
@change='set("emailNotifications", notification)')
|
||||||
td
|
td(v-if="onlyEmailsIds.indexOf(notification) === -1")
|
||||||
input(type='checkbox', v-model='user.preferences.pushNotifications[notification]',
|
input(type='checkbox', v-model='user.preferences.pushNotifications[notification]',
|
||||||
@change='set("pushNotifications", notification)')
|
@change='set("pushNotifications", notification)')
|
||||||
hr
|
hr
|
||||||
@@ -46,7 +46,7 @@ export default {
|
|||||||
mixins: [notificationsMixin],
|
mixins: [notificationsMixin],
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
notificationsIds: [
|
notificationsIds: Object.freeze([
|
||||||
'newPM',
|
'newPM',
|
||||||
'wonChallenge',
|
'wonChallenge',
|
||||||
'giftedGems',
|
'giftedGems',
|
||||||
@@ -59,7 +59,13 @@ export default {
|
|||||||
'importantAnnouncements',
|
'importantAnnouncements',
|
||||||
'weeklyRecaps',
|
'weeklyRecaps',
|
||||||
'onboarding',
|
'onboarding',
|
||||||
],
|
]),
|
||||||
|
// list of email-only notifications
|
||||||
|
onlyEmailsIds: Object.freeze([
|
||||||
|
'importantAnnouncements',
|
||||||
|
'weeklyRecaps',
|
||||||
|
'onboarding',
|
||||||
|
]),
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
|||||||
Reference in New Issue
Block a user