diff --git a/backend/.env.dist b/backend/.env.dist index c0a2a6098..861e5ebb3 100644 --- a/backend/.env.dist +++ b/backend/.env.dist @@ -1,4 +1,4 @@ -CONFIG_VERSION=v12.2022-11-10 +CONFIG_VERSION=v13.2022-12-20 # Server PORT=4000 @@ -30,6 +30,7 @@ COMMUNITY_REGISTER_URL=http://localhost/register COMMUNITY_REDEEM_URL=http://localhost/redeem/{code} COMMUNITY_REDEEM_CONTRIBUTION_URL=http://localhost/redeem/CL-{code} COMMUNITY_DESCRIPTION=Die lokale Entwicklungsumgebung von Gradido. +COMMUNITY_SUPPORT_MAIL=support@supportmail.com # Login Server LOGIN_APP_SECRET=21ffbbc616fe diff --git a/backend/.env.template b/backend/.env.template index 1bb2e4155..9d8696c6a 100644 --- a/backend/.env.template +++ b/backend/.env.template @@ -29,6 +29,7 @@ COMMUNITY_REGISTER_URL=$COMMUNITY_REGISTER_URL COMMUNITY_REDEEM_URL=$COMMUNITY_REDEEM_URL COMMUNITY_REDEEM_CONTRIBUTION_URL=$COMMUNITY_REDEEM_CONTRIBUTION_URL COMMUNITY_DESCRIPTION=$COMMUNITY_DESCRIPTION +COMMUNITY_SUPPORT_MAIL=$COMMUNITY_SUPPORT_MAIL # Login Server LOGIN_APP_SECRET=21ffbbc616fe diff --git a/backend/src/config/index.ts b/backend/src/config/index.ts index 38a4fde05..4d605857f 100644 --- a/backend/src/config/index.ts +++ b/backend/src/config/index.ts @@ -17,7 +17,7 @@ const constants = { LOG_LEVEL: process.env.LOG_LEVEL || 'info', CONFIG_VERSION: { DEFAULT: 'DEFAULT', - EXPECTED: 'v12.2022-11-10', + EXPECTED: 'v13.2022-12-20', CURRENT: '', }, } @@ -58,6 +58,7 @@ const community = { process.env.COMMUNITY_REDEEM_CONTRIBUTION_URL || 'http://localhost/redeem/CL-{code}', COMMUNITY_DESCRIPTION: process.env.COMMUNITY_DESCRIPTION || 'Die lokale Entwicklungsumgebung von Gradido.', + COMMUNITY_SUPPORT_MAIL: process.env.COMMUNITY_SUPPORT_MAIL || 'support@supportmail.com', } const loginServer = { diff --git a/backend/src/emails/sendEmailVariants.test.ts b/backend/src/emails/sendEmailVariants.test.ts index 262b91be2..9396c2b13 100644 --- a/backend/src/emails/sendEmailVariants.test.ts +++ b/backend/src/emails/sendEmailVariants.test.ts @@ -70,6 +70,8 @@ describe('sendEmailVariants', () => { senderLastName: 'Bloxberg', contributionMemo: 'My contribution.', overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -106,10 +108,14 @@ describe('sendEmailVariants', () => { 'To view and reply to the message, go to the “Community” menu in your Gradido account and click on the “My contributions to the common good” tab!', ) expect(result.originalMessage.html).toContain( - `Link to your account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, + `Link to your account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, ) expect(result.originalMessage.html).toContain('Please do not reply to this email!') - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', + ) }) }) }) @@ -140,6 +146,8 @@ describe('sendEmailVariants', () => { activationLink: 'http://localhost/checkEmail/6627633878930542284', timeDurationObject: { hours: 23, minutes: 30 }, resendLink: CONFIG.EMAIL_LINK_FORGOTPASSWORD, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -178,12 +186,16 @@ describe('sendEmailVariants', () => { 'or copy the link above into your browser window.', ) expect(result.originalMessage.html).toContain( - 'The link has a validity of 23 hours and 30 minutes. If the validity of the link has already expired, you can have a new link sent to you here by entering your email address:', + 'The link has a validity of 23 hours and 30 minutes. If the validity of the link has already expired, you can have a new link sent to you here:', ) expect(result.originalMessage.html).toContain( `${CONFIG.EMAIL_LINK_FORGOTPASSWORD}`, ) - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', + ) }) }) }) @@ -210,6 +222,8 @@ describe('sendEmailVariants', () => { lastName: 'Lustig', locale: 'en', resendLink: CONFIG.EMAIL_LINK_FORGOTPASSWORD, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -255,9 +269,13 @@ describe('sendEmailVariants', () => { 'or copy the link above into your browser window.', ) expect(result.originalMessage.html).toContain( - 'If you are not the one who tried to register again, please contact our support:', + 'If you are not the one who tried to register again, please contact our support:
support@supportmail.com', + ) + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', ) - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') }) }) }) @@ -292,6 +310,8 @@ describe('sendEmailVariants', () => { contributionMemo: 'My contribution.', contributionAmount: '23.54', overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -326,10 +346,14 @@ describe('sendEmailVariants', () => { ) expect(result.originalMessage.html).toContain('Amount: 23.54 GDD') expect(result.originalMessage.html).toContain( - `Link to your account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, + `Link to your account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, ) expect(result.originalMessage.html).toContain('Please do not reply to this email!') - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', + ) }) }) }) @@ -362,6 +386,8 @@ describe('sendEmailVariants', () => { senderLastName: 'Bloxberg', contributionMemo: 'My contribution.', overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -398,10 +424,14 @@ describe('sendEmailVariants', () => { 'To see your common good contributions and related messages, go to the “Community” menu in your Gradido account and click on the “My contributions to the common good” tab!', ) expect(result.originalMessage.html).toContain( - `Link to your account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, + `Link to your account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, ) expect(result.originalMessage.html).toContain('Please do not reply to this email!') - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', + ) }) }) }) @@ -432,6 +462,8 @@ describe('sendEmailVariants', () => { resetLink: 'http://localhost/reset-password/3762660021544901417', timeDurationObject: { hours: 23, minutes: 30 }, resendLink: CONFIG.EMAIL_LINK_FORGOTPASSWORD, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -468,12 +500,16 @@ describe('sendEmailVariants', () => { 'or copy the link above into your browser window.', ) expect(result.originalMessage.html).toContain( - 'The link has a validity of 23 hours and 30 minutes. If the validity of the link has already expired, you can have a new link sent to you here by entering your email address:', + 'The link has a validity of 23 hours and 30 minutes. If the validity of the link has already expired, you can have a new link sent to you here:', ) expect(result.originalMessage.html).toContain( `${CONFIG.EMAIL_LINK_FORGOTPASSWORD}`, ) - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', + ) }) }) }) @@ -510,6 +546,8 @@ describe('sendEmailVariants', () => { transactionMemo: 'You deserve it! 🙏🏼', transactionAmount: '17.65', overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -543,12 +581,16 @@ describe('sendEmailVariants', () => { 'Bibi Bloxberg (bibi@bloxberg.de) has just redeemed your link.', ) expect(result.originalMessage.html).toContain('Amount: 17.65 GDD') - expect(result.originalMessage.html).toContain('Memo: You deserve it! 🙏🏼') + expect(result.originalMessage.html).toContain('Message: You deserve it! 🙏🏼') expect(result.originalMessage.html).toContain( - `You can find transaction details in your Gradido account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, + `You can find transaction details in your Gradido account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, ) expect(result.originalMessage.html).toContain('Please do not reply to this email!') - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', + ) }) }) }) @@ -583,6 +625,8 @@ describe('sendEmailVariants', () => { senderEmail: 'bibi@bloxberg.de', transactionAmount: '37.40', overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) }) @@ -598,26 +642,32 @@ describe('sendEmailVariants', () => { to: 'Peter Lustig ', from: 'Gradido (do not answer) ', attachments: [], - subject: 'Gradido: You have received Gradidos', + subject: 'Gradido: Bibi Bloxberg has sent you 37.40 Gradido', html: expect.any(String), - text: expect.stringContaining('GRADIDO: YOU HAVE RECEIVED GRADIDOS'), + text: expect.stringContaining('GRADIDO: BIBI BLOXBERG HAS SENT YOU 37.40 GRADIDO'), }), }) expect(result.originalMessage.html).toContain('') expect(result.originalMessage.html).toContain('') expect(result.originalMessage.html).toContain( - 'Gradido: You have received Gradidos', + 'Gradido: Bibi Bloxberg has sent you 37.40 Gradido', + ) + expect(result.originalMessage.html).toContain( + '>Gradido: Bibi Bloxberg has sent you 37.40 Gradido', ) - expect(result.originalMessage.html).toContain('>Gradido: You have received Gradidos') expect(result.originalMessage.html).toContain('Hello Peter Lustig') expect(result.originalMessage.html).toContain( 'You have just received 37.40 GDD from Bibi Bloxberg (bibi@bloxberg.de).', ) expect(result.originalMessage.html).toContain( - `You can find transaction details in your Gradido account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, + `You can find transaction details in your Gradido account: ${CONFIG.EMAIL_LINK_OVERVIEW}`, ) expect(result.originalMessage.html).toContain('Please do not reply to this email!') - expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('Kind regards,
your Gradido team') + expect(result.originalMessage.html).toContain('—————') + expect(result.originalMessage.html).toContain( + '
Gradido-Akademie Logo

Gradido-Akademie
Institut für Wirtschaftsbionik
Pfarrweg 2
74653 Künzelsau
Deutschland
support@supportmail.com
http://localhost/', + ) }) }) }) diff --git a/backend/src/emails/sendEmailVariants.ts b/backend/src/emails/sendEmailVariants.ts index 356f95e39..cb1376510 100644 --- a/backend/src/emails/sendEmailVariants.ts +++ b/backend/src/emails/sendEmailVariants.ts @@ -25,6 +25,8 @@ export const sendAddedContributionMessageEmail = (data: { senderLastName: data.senderLastName, contributionMemo: data.contributionMemo, overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } @@ -47,6 +49,8 @@ export const sendAccountActivationEmail = (data: { activationLink: data.activationLink, timeDurationObject: data.timeDurationObject, resendLink: CONFIG.EMAIL_LINK_FORGOTPASSWORD, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } @@ -65,6 +69,8 @@ export const sendAccountMultiRegistrationEmail = (data: { lastName: data.lastName, locale: data.language, resendLink: CONFIG.EMAIL_LINK_FORGOTPASSWORD, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } @@ -91,6 +97,8 @@ export const sendContributionConfirmedEmail = (data: { contributionMemo: data.contributionMemo, contributionAmount: decimalSeparatorByLanguage(data.contributionAmount, data.language), overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } @@ -115,6 +123,8 @@ export const sendContributionRejectedEmail = (data: { senderLastName: data.senderLastName, contributionMemo: data.contributionMemo, overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } @@ -137,6 +147,8 @@ export const sendResetPasswordEmail = (data: { resetLink: data.resetLink, timeDurationObject: data.timeDurationObject, resendLink: CONFIG.EMAIL_LINK_FORGOTPASSWORD, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } @@ -165,6 +177,8 @@ export const sendTransactionLinkRedeemedEmail = (data: { transactionMemo: data.transactionMemo, transactionAmount: decimalSeparatorByLanguage(data.transactionAmount, data.language), overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } @@ -191,6 +205,8 @@ export const sendTransactionReceivedEmail = (data: { senderEmail: data.senderEmail, transactionAmount: decimalSeparatorByLanguage(data.transactionAmount, data.language), overviewURL: CONFIG.EMAIL_LINK_OVERVIEW, + supportEmail: CONFIG.COMMUNITY_SUPPORT_MAIL, + communityURL: CONFIG.COMMUNITY_URL, }, }) } diff --git a/backend/src/emails/templates/accountActivation/html.pug b/backend/src/emails/templates/accountActivation/html.pug index f283e941e..6075fa8a8 100644 --- a/backend/src/emails/templates/accountActivation/html.pug +++ b/backend/src/emails/templates/accountActivation/html.pug @@ -5,16 +5,16 @@ html(lang=locale) body h1(style='margin-bottom: 24px;')= t('emails.accountActivation.subject') #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) + include ../hello.pug p= t('emails.accountActivation.emailRegistered') - p= t('emails.accountActivation.pleaseClickLink') + p + = t('emails.accountActivation.pleaseClickLink') br a(href=activationLink) #{activationLink} br - span= t('emails.general.orCopyLink') - p= t('emails.accountActivation.duration', { hours: timeDurationObject.hours, minutes: timeDurationObject.minutes }) + = t('emails.general.orCopyLink') + p + = t('emails.accountActivation.duration', { hours: timeDurationObject.hours, minutes: timeDurationObject.minutes }) br a(href=resendLink) #{resendLink} - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/accountMultiRegistration/html.pug b/backend/src/emails/templates/accountMultiRegistration/html.pug index b3764403b..f8570422c 100644 --- a/backend/src/emails/templates/accountMultiRegistration/html.pug +++ b/backend/src/emails/templates/accountMultiRegistration/html.pug @@ -5,18 +5,19 @@ html(lang=locale) body h1(style='margin-bottom: 24px;')= t('emails.accountMultiRegistration.subject') #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) - p= t('emails.accountMultiRegistration.emailReused') + include ../hello.pug + p + = t('emails.accountMultiRegistration.emailReused') br - span= t('emails.accountMultiRegistration.emailExists') - p= t('emails.accountMultiRegistration.onForgottenPasswordClickLink') + = t('emails.accountMultiRegistration.emailExists') + p + = t('emails.accountMultiRegistration.onForgottenPasswordClickLink') br a(href=resendLink) #{resendLink} br - span= t('emails.accountMultiRegistration.onForgottenPasswordCopyLink') - p= t('emails.accountMultiRegistration.ifYouAreNotTheOne') + = t('emails.accountMultiRegistration.onForgottenPasswordCopyLink') + p + = t('emails.accountMultiRegistration.ifYouAreNotTheOne') br - a(href='https://gradido.net/de/contact/') https://gradido.net/de/contact/ - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + a(href='mailto:' + supportEmail)= supportEmail + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/addedContributionMessage/html.pug b/backend/src/emails/templates/addedContributionMessage/html.pug index 5e5d0975c..e7410c0f0 100644 --- a/backend/src/emails/templates/addedContributionMessage/html.pug +++ b/backend/src/emails/templates/addedContributionMessage/html.pug @@ -5,13 +5,12 @@ html(lang=locale) body h1(style='margin-bottom: 24px;')= t('emails.addedContributionMessage.subject') #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) + include ../hello.pug p= t('emails.addedContributionMessage.commonGoodContributionMessage', { senderFirstName, senderLastName, contributionMemo }) p= t('emails.addedContributionMessage.toSeeAndAnswerMessage') - p= t('emails.general.linkToYourAccount') - span= " " + p + = t('emails.general.linkToYourAccount') + = " " a(href=overviewURL) #{overviewURL} p= t('emails.general.pleaseDoNotReply') - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/contributionConfirmed/html.pug b/backend/src/emails/templates/contributionConfirmed/html.pug index 32626b147..4ff17ffd4 100644 --- a/backend/src/emails/templates/contributionConfirmed/html.pug +++ b/backend/src/emails/templates/contributionConfirmed/html.pug @@ -5,13 +5,12 @@ html(lang=locale) body h1(style='margin-bottom: 24px;')= t('emails.contributionConfirmed.subject') #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) + include ../hello.pug p= t('emails.contributionConfirmed.commonGoodContributionConfirmed', { senderFirstName, senderLastName, contributionMemo }) p= t('emails.general.amountGDD', { amountGDD: contributionAmount }) - p= t('emails.general.linkToYourAccount') - span= " " + p + = t('emails.general.linkToYourAccount') + = " " a(href=overviewURL) #{overviewURL} p= t('emails.general.pleaseDoNotReply') - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/contributionRejected/html.pug b/backend/src/emails/templates/contributionRejected/html.pug index 07c014f92..531f75543 100644 --- a/backend/src/emails/templates/contributionRejected/html.pug +++ b/backend/src/emails/templates/contributionRejected/html.pug @@ -5,13 +5,12 @@ html(lang=locale) body h1(style='margin-bottom: 24px;')= t('emails.contributionRejected.subject') #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) + include ../hello.pug p= t('emails.contributionRejected.commonGoodContributionRejected', { senderFirstName, senderLastName, contributionMemo }) p= t('emails.contributionRejected.toSeeContributionsAndMessages') - p= t('emails.general.linkToYourAccount') - span= " " + p + = t('emails.general.linkToYourAccount') + = " " a(href=overviewURL) #{overviewURL} p= t('emails.general.pleaseDoNotReply') - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/greatingFormularImprint.pug b/backend/src/emails/templates/greatingFormularImprint.pug new file mode 100644 index 000000000..d7d8c3a14 --- /dev/null +++ b/backend/src/emails/templates/greatingFormularImprint.pug @@ -0,0 +1,16 @@ +p(style='margin-top: 24px;') + = t('emails.general.sincerelyYours') + br + = t('emails.general.yourGradidoTeam') +p(style='margin-top: 24px;')= '—————' +p(style='margin-top: 24px;') + if t('general.imprintImageURL').length > 0 + div(style='position: relative; left: -22px;') + img(src=t('general.imprintImageURL'), width='200', alt=t('general.imprintImageAlt')) + br + each line in t('general.imprint').split(/\n/) + = line + br + a(href='mailto:' + supportEmail)= supportEmail + br + a(href=communityURL)= communityURL diff --git a/backend/src/emails/templates/hello.pug b/backend/src/emails/templates/hello.pug new file mode 100644 index 000000000..3e2591951 --- /dev/null +++ b/backend/src/emails/templates/hello.pug @@ -0,0 +1 @@ +p= t('emails.general.helloName', { firstName, lastName }) diff --git a/backend/src/emails/templates/resetPassword/html.pug b/backend/src/emails/templates/resetPassword/html.pug index a3ced9a75..53ffbcd04 100644 --- a/backend/src/emails/templates/resetPassword/html.pug +++ b/backend/src/emails/templates/resetPassword/html.pug @@ -5,16 +5,16 @@ html(lang=locale) body h1(style='margin-bottom: 24px;')= t('emails.resetPassword.subject') #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) + include ../hello.pug p= t('emails.resetPassword.youOrSomeoneResetPassword') - p= t('emails.resetPassword.pleaseClickLink') + p + = t('emails.resetPassword.pleaseClickLink') br a(href=resetLink) #{resetLink} br - span= t('emails.general.orCopyLink') - p= t('emails.resetPassword.duration', { hours: timeDurationObject.hours, minutes: timeDurationObject.minutes }) + = t('emails.general.orCopyLink') + p + = t('emails.resetPassword.duration', { hours: timeDurationObject.hours, minutes: timeDurationObject.minutes }) br a(href=resendLink) #{resendLink} - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/transactionLinkRedeemed/html.pug b/backend/src/emails/templates/transactionLinkRedeemed/html.pug index 321d070b4..fb561f5c5 100644 --- a/backend/src/emails/templates/transactionLinkRedeemed/html.pug +++ b/backend/src/emails/templates/transactionLinkRedeemed/html.pug @@ -5,15 +5,15 @@ html(lang=locale) body h1(style='margin-bottom: 24px;')= t('emails.transactionLinkRedeemed.subject') #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) + include ../hello.pug p= t('emails.transactionLinkRedeemed.hasRedeemedYourLink', { senderFirstName, senderLastName, senderEmail }) - p= t('emails.general.amountGDD', { amountGDD: transactionAmount }) + p + = t('emails.general.amountGDD', { amountGDD: transactionAmount }) br - span= t('emails.transactionLinkRedeemed.memo', { transactionMemo }) - p= t('emails.general.detailsYouFindOnLinkToYourAccount') - span= " " + = t('emails.transactionLinkRedeemed.memo', { transactionMemo }) + p + = t('emails.general.detailsYouFindOnLinkToYourAccount') + = " " a(href=overviewURL) #{overviewURL} p= t('emails.general.pleaseDoNotReply') - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/transactionReceived/html.pug b/backend/src/emails/templates/transactionReceived/html.pug index eaf57f975..e6807f539 100644 --- a/backend/src/emails/templates/transactionReceived/html.pug +++ b/backend/src/emails/templates/transactionReceived/html.pug @@ -1,16 +1,15 @@ doctype html html(lang=locale) head - title= t('emails.transactionReceived.subject') + title= t('emails.transactionReceived.subject', { senderFirstName, senderLastName, transactionAmount }) body - h1(style='margin-bottom: 24px;')= t('emails.transactionReceived.subject') + h1(style='margin-bottom: 24px;')= t('emails.transactionReceived.subject', { senderFirstName, senderLastName, transactionAmount }) #container.col - p(style='margin-bottom: 24px;')= t('emails.general.helloName', { firstName, lastName }) + include ../hello.pug p= t('emails.transactionReceived.haveReceivedAmountGDDFrom', { transactionAmount, senderFirstName, senderLastName, senderEmail }) - p= t('emails.general.detailsYouFindOnLinkToYourAccount') - span= " " + p + = t('emails.general.detailsYouFindOnLinkToYourAccount') + = " " a(href=overviewURL) #{overviewURL} p= t('emails.general.pleaseDoNotReply') - p(style='margin-top: 24px;')= t('emails.general.sincerelyYours') - br - span= t('emails.general.yourGradidoTeam') + include ../greatingFormularImprint.pug diff --git a/backend/src/emails/templates/transactionReceived/subject.pug b/backend/src/emails/templates/transactionReceived/subject.pug index 630752b02..872806ebc 100644 --- a/backend/src/emails/templates/transactionReceived/subject.pug +++ b/backend/src/emails/templates/transactionReceived/subject.pug @@ -1 +1 @@ -= t('emails.transactionReceived.subject') += t('emails.transactionReceived.subject', { senderFirstName, senderLastName, transactionAmount }) diff --git a/backend/src/locales/de.json b/backend/src/locales/de.json index 8aff6caa4..2e6796794 100644 --- a/backend/src/locales/de.json +++ b/backend/src/locales/de.json @@ -6,7 +6,7 @@ "toSeeAndAnswerMessage": "Um die Nachricht zu sehen und darauf zu antworten, gehe in deinem Gradido-Konto ins Menü „Gemeinschaft“ auf den Tab „Meine Beiträge zum Gemeinwohl“!" }, "accountActivation": { - "duration": "Der Link hat eine Gültigkeit von {hours} Stunden und {minutes} Minuten. Sollte die Gültigkeit des Links bereits abgelaufen sein, kannst du dir hier einen neuen Link schicken lassen, in dem du deine E-Mail-Adresse eingibst:", + "duration": "Der Link hat eine Gültigkeit von {hours} Stunden und {minutes} Minuten. Sollte die Gültigkeit des Links bereits abgelaufen sein, kannst du dir hier einen neuen Link schicken lassen:", "emailRegistered": "deine E-Mail-Adresse wurde soeben bei Gradido registriert.", "pleaseClickLink": "Klicke bitte auf diesen Link, um die Registrierung abzuschließen und dein Gradido-Konto zu aktivieren:", "subject": "Gradido: E-Mail Überprüfung" @@ -14,7 +14,7 @@ "accountMultiRegistration": { "emailExists": "Es existiert jedoch zu deiner E-Mail-Adresse schon ein Konto.", "emailReused": "deine E-Mail-Adresse wurde soeben erneut benutzt, um bei Gradido ein Konto zu registrieren.", - "ifYouAreNotTheOne": "Wenn du nicht derjenige bist, der sich versucht hat erneut zu registrieren, wende dich bitte an unseren support:", + "ifYouAreNotTheOne": "Wenn du nicht derjenige bist, der versucht hat sich erneut zu registrieren, wende dich bitte an unseren Support:", "onForgottenPasswordClickLink": "Klicke bitte auf den folgenden Link, falls du dein Passwort vergessen haben solltest:", "onForgottenPasswordCopyLink": "oder kopiere den obigen Link in dein Browserfenster.", "subject": "Gradido: Erneuter Registrierungsversuch mit deiner E-Mail" @@ -40,22 +40,25 @@ "yourGradidoTeam": "dein Gradido-Team" }, "resetPassword": { - "duration": "Der Link hat eine Gültigkeit von {hours} Stunden und {minutes} Minuten. Sollte die Gültigkeit des Links bereits abgelaufen sein, kannst du dir hier einen neuen Link schicken lassen, in dem du deine E-Mail-Adresse eingibst:", + "duration": "Der Link hat eine Gültigkeit von {hours} Stunden und {minutes} Minuten. Sollte die Gültigkeit des Links bereits abgelaufen sein, kannst du dir hier einen neuen Link schicken lassen:", "pleaseClickLink": "Wenn du es warst, klicke bitte auf den Link:", "subject": "Gradido: Passwort zurücksetzen", "youOrSomeoneResetPassword": "du, oder jemand anderes, hast für dieses Konto ein Zurücksetzen des Passworts angefordert." }, "transactionLinkRedeemed": { "hasRedeemedYourLink": "{senderFirstName} {senderLastName} ({senderEmail}) hat soeben deinen Link eingelöst.", - "memo": "Memo: {transactionMemo}", + "memo": "Nachricht: {transactionMemo}", "subject": "Gradido: Dein Gradido-Link wurde eingelöst" }, "transactionReceived": { "haveReceivedAmountGDDFrom": "du hast soeben {transactionAmount} GDD von {senderFirstName} {senderLastName} ({senderEmail}) erhalten.", - "subject": "Gradido: Du hast Gradidos erhalten" + "subject": "Gradido: {senderFirstName} {senderLastName} hat dir {transactionAmount} Gradido gesendet" } }, "general": { - "decimalSeparator": "," + "decimalSeparator": ",", + "imprint": "Gradido-Akademie\nInstitut für Wirtschaftsbionik\nPfarrweg 2\n74653 Künzelsau\nDeutschland", + "imprintImageAlt": "Gradido-Akademie Logo", + "imprintImageURL": "https://gdd.gradido.net/img/brand/green.png" } } diff --git a/backend/src/locales/en.json b/backend/src/locales/en.json index 99217840e..3b25f8ae4 100644 --- a/backend/src/locales/en.json +++ b/backend/src/locales/en.json @@ -6,7 +6,7 @@ "toSeeAndAnswerMessage": "To view and reply to the message, go to the “Community” menu in your Gradido account and click on the “My contributions to the common good” tab!" }, "accountActivation": { - "duration": "The link has a validity of {hours} hours and {minutes} minutes. If the validity of the link has already expired, you can have a new link sent to you here by entering your email address:", + "duration": "The link has a validity of {hours} hours and {minutes} minutes. If the validity of the link has already expired, you can have a new link sent to you here:", "emailRegistered": "Your email address has just been registered with Gradido.", "pleaseClickLink": "Please click on this link to complete the registration and activate your Gradido account:", "subject": "Gradido: Email Verification" @@ -40,22 +40,25 @@ "yourGradidoTeam": "your Gradido team" }, "resetPassword": { - "duration": "The link has a validity of {hours} hours and {minutes} minutes. If the validity of the link has already expired, you can have a new link sent to you here by entering your email address:", + "duration": "The link has a validity of {hours} hours and {minutes} minutes. If the validity of the link has already expired, you can have a new link sent to you here:", "pleaseClickLink": "If it was you, please click on the link:", "subject": "Gradido: Reset password", "youOrSomeoneResetPassword": "You, or someone else, requested a password reset for this account." }, "transactionLinkRedeemed": { "hasRedeemedYourLink": "{senderFirstName} {senderLastName} ({senderEmail}) has just redeemed your link.", - "memo": "Memo: {transactionMemo}", + "memo": "Message: {transactionMemo}", "subject": "Gradido: Your Gradido link has been redeemed" }, "transactionReceived": { "haveReceivedAmountGDDFrom": "You have just received {transactionAmount} GDD from {senderFirstName} {senderLastName} ({senderEmail}).", - "subject": "Gradido: You have received Gradidos" + "subject": "Gradido: {senderFirstName} {senderLastName} has sent you {transactionAmount} Gradido" } }, "general": { - "decimalSeparator": "." + "decimalSeparator": ".", + "imprint": "Gradido-Akademie\nInstitut für Wirtschaftsbionik\nPfarrweg 2\n74653 Künzelsau\nDeutschland", + "imprintImageAlt": "Gradido-Akademie Logo", + "imprintImageURL": "https://gdd.gradido.net/img/brand/green.png" } } diff --git a/deployment/bare_metal/.env.dist b/deployment/bare_metal/.env.dist index 9c6bfd735..a5f6996d7 100644 --- a/deployment/bare_metal/.env.dist +++ b/deployment/bare_metal/.env.dist @@ -24,9 +24,10 @@ COMMUNITY_REGISTER_URL=https://stage1.gradido.net/register COMMUNITY_REDEEM_URL=https://stage1.gradido.net/redeem/{code} COMMUNITY_REDEEM_CONTRIBUTION_URL=https://stage1.gradido.net/redeem/CL-{code} COMMUNITY_DESCRIPTION="Gradido Development Stage1 Test Community" +COMMUNITY_SUPPORT_MAIL=support@supportmail.com # backend -BACKEND_CONFIG_VERSION=v12.2022-11-10 +BACKEND_CONFIG_VERSION=v13.2022-12-20 JWT_EXPIRES_IN=10m GDT_API_URL=https://gdt.gradido.net @@ -69,7 +70,7 @@ EVENT_PROTOCOL_DISABLED=false DATABASE_CONFIG_VERSION=v1.2022-03-18 # frontend -FRONTEND_CONFIG_VERSION=v3.2022-09-16 +FRONTEND_CONFIG_VERSION=v4.2022-12-20 GRAPHQL_URI=https://stage1.gradido.net/graphql ADMIN_AUTH_URL=https://stage1.gradido.net/admin/authenticate?token={token} @@ -85,8 +86,6 @@ META_KEYWORDS_DE="Grundeinkommen, Währung, Dankbarkeit, Schenk-Ökonomie, Natü META_KEYWORDS_EN="Basic Income, Currency, Gratitude, Gift Economy, Natural Economy of Life, Economy, Ecology, Potential Development, Giving and Thanking, Cycle of Life, Monetary System" META_AUTHOR="Bernd Hückstädt - Gradido-Akademie" -SUPPORT_MAIL=support@supportmail.com - # admin ADMIN_CONFIG_VERSION=v1.2022-03-18 diff --git a/frontend/.env.dist b/frontend/.env.dist index 4127f339a..5ce6b430d 100644 --- a/frontend/.env.dist +++ b/frontend/.env.dist @@ -1,4 +1,4 @@ -CONFIG_VERSION=v3.2022-09-16 +CONFIG_VERSION=v4.2022-12-20 # Environment DEFAULT_PUBLISHER_ID=2896 @@ -12,6 +12,7 @@ COMMUNITY_NAME=Gradido Entwicklung COMMUNITY_URL=http://localhost/ COMMUNITY_REGISTER_URL=http://localhost/register COMMUNITY_DESCRIPTION=Die lokale Entwicklungsumgebung von Gradido. +COMMUNITY_SUPPORT_MAIL=support@supportmail.com # Meta META_URL=http://localhost @@ -22,6 +23,3 @@ META_DESCRIPTION_EN="Gratitude is the currency of the new age. More and more peo META_KEYWORDS_DE="Grundeinkommen, Währung, Dankbarkeit, Schenk-Ökonomie, Natürliche Ökonomie des Lebens, Ökonomie, Ökologie, Potenzialentfaltung, Schenken und Danken, Kreislauf des Lebens, Geldsystem" META_KEYWORDS_EN="Basic Income, Currency, Gratitude, Gift Economy, Natural Economy of Life, Economy, Ecology, Potential Development, Giving and Thanking, Cycle of Life, Monetary System" META_AUTHOR="Bernd Hückstädt - Gradido-Akademie" - -# Support Mail -SUPPORT_MAIL=support@supportmail.com \ No newline at end of file diff --git a/frontend/.env.template b/frontend/.env.template index 0b9d34b38..59e34eb80 100644 --- a/frontend/.env.template +++ b/frontend/.env.template @@ -12,6 +12,7 @@ COMMUNITY_NAME=$COMMUNITY_NAME COMMUNITY_URL=$COMMUNITY_URL COMMUNITY_REGISTER_URL=$COMMUNITY_REGISTER_URL COMMUNITY_DESCRIPTION=$COMMUNITY_DESCRIPTION +COMMUNITY_SUPPORT_MAIL=$COMMUNITY_SUPPORT_MAIL # Meta META_URL=$META_URL @@ -22,6 +23,3 @@ META_DESCRIPTION_EN=$META_DESCRIPTION_EN META_KEYWORDS_DE=$META_KEYWORDS_DE META_KEYWORDS_EN=$META_KEYWORDS_EN META_AUTHOR=$META_AUTHOR - -# Support Mail -SUPPORT_MAIL=$SUPPORT_MAIL \ No newline at end of file diff --git a/frontend/src/config/index.js b/frontend/src/config/index.js index 5ab5f2392..b90376672 100644 --- a/frontend/src/config/index.js +++ b/frontend/src/config/index.js @@ -8,7 +8,7 @@ const constants = { DECAY_START_TIME: new Date('2021-05-13 17:46:31-0000'), // GMT+0 CONFIG_VERSION: { DEFAULT: 'DEFAULT', - EXPECTED: 'v3.2022-09-16', + EXPECTED: 'v4.2022-12-20', CURRENT: '', }, } @@ -39,6 +39,7 @@ const community = { COMMUNITY_REGISTER_URL: process.env.COMMUNITY_REGISTER_URL || 'http://localhost/register', COMMUNITY_DESCRIPTION: process.env.COMMUNITY_DESCRIPTION || 'Die lokale Entwicklungsumgebung von Gradido.', + COMMUNITY_SUPPORT_MAIL: process.env.COMMUNITY_SUPPORT_MAIL || 'support@supportmail.com', } const meta = { @@ -60,10 +61,6 @@ const meta = { META_AUTHOR: process.env.META_AUTHOR || 'Bernd Hückstädt - Gradido-Akademie', } -const supportmail = { - SUPPORT_MAIL: process.env.SUPPORT_MAIL || 'support@supportmail.com', -} - // Check config version constants.CONFIG_VERSION.CURRENT = process.env.CONFIG_VERSION || constants.CONFIG_VERSION.DEFAULT if ( @@ -83,7 +80,6 @@ const CONFIG = { ...endpoints, ...community, ...meta, - ...supportmail, } module.exports = CONFIG diff --git a/frontend/src/pages/InfoStatistic.vue b/frontend/src/pages/InfoStatistic.vue index 254a895e0..978c7fde5 100644 --- a/frontend/src/pages/InfoStatistic.vue +++ b/frontend/src/pages/InfoStatistic.vue @@ -89,7 +89,7 @@ export default { countAdminUser: null, itemsContributionLinks: [], itemsAdminUser: [], - supportMail: CONFIG.SUPPORT_MAIL, + supportMail: CONFIG.COMMUNITY_SUPPORT_MAIL, membersCount: '1203', totalUsers: null, totalGradidoCreated: null,