diff --git a/common/locales/en/settings.json b/common/locales/en/settings.json index 9c51e71194..6aa4d0293d 100644 --- a/common/locales/en/settings.json +++ b/common/locales/en/settings.json @@ -97,6 +97,7 @@ "invitedParty": "Invited To Party", "invitedGuild": "Invited To Guild", "inactivityEmails": "Your account is inactive", + "weeklyRecaps": "Summaries of your acccount activity in the past week", "questStarted": "Your Quest has Begun", "invitedQuest": "Invited to Quest", "kickedGroup": "Kicked from group", diff --git a/website/src/models/user.js b/website/src/models/user.js index 32e7bfd60d..61f44e1724 100644 --- a/website/src/models/user.js +++ b/website/src/models/user.js @@ -146,6 +146,8 @@ var UserSchema = new Schema({ // Used to track the status of recapture emails sent to each user, // can be 0 - no email sent - 1, 2, 3 or 4 - 4 means no more email will be sent to the user recaptureEmailsPhase: {type: Number, 'default': 0}, + // Needed to track the tip to send inside the email + weeklyRecapEmailsPhase: {type: Number, 'default': 0}, communityGuidelinesAccepted: {type: Boolean, 'default': false}, cronCount: {type:Number, 'default':0} }, @@ -328,7 +330,8 @@ var UserSchema = new Schema({ invitedQuest: {type: Boolean, 'default': true}, //remindersToLogin: {type: Boolean, 'default': true}, // Those importantAnnouncements are in fact the recapture emails - importantAnnouncements: {type: Boolean, 'default': true} + importantAnnouncements: {type: Boolean, 'default': true}, + weeklyRecaps: {type: Boolean, 'default': true} } }, profile: { diff --git a/website/views/options/settings.jade b/website/views/options/settings.jade index dc8d25983a..7c9c92c6b9 100644 --- a/website/views/options/settings.jade +++ b/website/views/options/settings.jade @@ -325,6 +325,11 @@ script(id='partials/options.settings.notifications.html', type="text/ng-template input(type='checkbox', ng-disabled='user.preferences.emailNotifications.unsubscribeFromAll === true', ng-model='user.preferences.emailNotifications.importantAnnouncements', ng-change='set({"preferences.emailNotifications.importantAnnouncements": user.preferences.emailNotifications.importantAnnouncements ? true: false})') span=env.t('inactivityEmails') + .checkbox + label + input(type='checkbox', ng-disabled='user.preferences.emailNotifications.unsubscribeFromAll === true', ng-model='user.preferences.emailNotifications.weeklyRecaps', ng-change='set({"preferences.emailNotifications.weeklyRecaps": user.preferences.emailNotifications.weeklyRecaps ? true: false})') + span=env.t('weeklyRecaps') + hr .checkbox