-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add email unsubscribe message #61
feat: add email unsubscribe message #61
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @MaferMazu we need to translate that message. Please replace the English text with a trans ...
edx-platform/nau-basic/lms/templates/ace_common/edx_ace/common/base_body.html
Show resolved
Hide resolved
Replace the portuguese translation:
With:
It is better because of the gender of "Configurações de conta". Meaning it should render like:
|
fix: update translations refactor: improve the email unsubscribe message fix: update translations
This is ready for a re-review @igobranco @BryanttV ✨ |
edx-platform/nau-basic/lms/templates/ace_common/edx_ace/common/base_body.html
Show resolved
Hide resolved
...tform/nau-basic/lms/templates/ace_common/edx_ace/common/nudge_email_unsubscribe_message.html
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MaferMazu, since we only affect specific templates could we update the PR description?
I updated the PR description and applied your feedback @BryanttV; please let me know if you could test it and if it works as expected. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @MaferMazu, thanks for addressing my comments. I tested the changes and it works as expected!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @MaferMazu
I tested the changes in a remote environment and found that the link in the new message is incorrect. The base link should redirect to the lms and not to the homepage.
Thanks for that observation @BryanttV. I fixed it. I would like your re-review of this PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM ✔️
Description
This PR adds a short message in the emails to allow users to unsubscribe to the newsletter in the recurringnudge_day3 and recurringnudge_day10.
Detailed changes:
nudge_email_unsubscribe_message.html
to store the message an reuse it in different templates.base_body.html
, to be able to add elements in the footer of the emails using the email templates (e.g., recurringnudge_day3 and recurringnudge_day10)babel_mako.cfg
to target ace_common Django template for translations.This is related to https://github.com/fccn/nau-technical/issues/279
How to test
Create a new Schedule config for your site in
{lms_domain}/admin/schedules/scheduleconfig/
Create a user and enroll it in a course.
Send a message of recurring nudge using the following command in the LMS container:
python manage.py lms send_recurring_nudge {site} --date {enroll-date + 3 days} # Example python manage.py lms send_recurring_nudge local.edly.io:8000 --date 2024-12-19
You can copy and paste the output into an
email.html
file to open it in your browser.Test it in PT
Add the following configuration (for testing purposes, you can add it to your
env/apps/openedx/config/lms.env.yml
), then follow steps 5 and 6 from the previous instructions.Screenshot
Email en 3
![image](https://private-user-images.githubusercontent.com/35668326/398294217-60ef5482-a8c8-4ed1-ba49-7fe976ceaca9.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyODA3MjIsIm5iZiI6MTczOTI4MDQyMiwicGF0aCI6Ii8zNTY2ODMyNi8zOTgyOTQyMTctNjBlZjU0ODItYThjOC00ZWQxLWJhNDktN2ZlOTc2Y2VhY2E5LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDEzMjcwMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTFiZGEwODEwMDFkNWE2OGNkNzBiMWE1NWRjZTJmOGYwZWQ4OWE2NWViZDgxMDFhZGMyODU0Yzk2MGZmZGNlN2QmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.ruNpxIV1HCGmkUhxdV2eO3KWZnA6nhz8jWT_Sno-Cro)
Email pt 3
![image](https://private-user-images.githubusercontent.com/35668326/398294293-c5796eac-8ca8-4b2a-bbcf-a3c041fb28c4.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyODA3MjIsIm5iZiI6MTczOTI4MDQyMiwicGF0aCI6Ii8zNTY2ODMyNi8zOTgyOTQyOTMtYzU3OTZlYWMtOGNhOC00YjJhLWJiY2YtYTNjMDQxZmIyOGM0LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDEzMjcwMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTZkNTdiYzYwMGFiNmE5YzE3ZjllMjZhODdkYjMzZDFjYzg1OTQzNTNkZmQwYjExZmE2MDE2ZWUwZWVkZjgyNmEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.QdrzJFchs7qsT1B1rxR-jnXZmmKOZSCFcExkY5auDRU)
Email en 10
![image](https://private-user-images.githubusercontent.com/35668326/398294365-b547076b-3c3b-48e4-b8fe-8dc9fde1bac7.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyODA3MjIsIm5iZiI6MTczOTI4MDQyMiwicGF0aCI6Ii8zNTY2ODMyNi8zOTgyOTQzNjUtYjU0NzA3NmItM2MzYi00OGU0LWI4ZmUtOGRjOWZkZTFiYWM3LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDEzMjcwMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTU2NjQxYTU1MzllZjY1MWM4ODVkMzUwNTI2YWQzYzkyYjkyMDJkMzRkMzBlZDM0MmQyZjJhZTQyMWQ2NzNhZTUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.eAb--9Cg94QmBLZlgJO__ksinxI76lHMXu4Aqrk9iwI)
Email pt 10
![image](https://private-user-images.githubusercontent.com/35668326/398294462-d9d32da4-5366-41c3-bb98-939842519265.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyODA3MjIsIm5iZiI6MTczOTI4MDQyMiwicGF0aCI6Ii8zNTY2ODMyNi8zOTgyOTQ0NjItZDlkMzJkYTQtNTM2Ni00MWMzLWJiOTgtOTM5ODQyNTE5MjY1LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDEzMjcwMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTViMjljMTExYzQzZDc0MTU0NjhjZDY2YWRiZWQ4YjBkN2NjZjg3NGIzNjc0YjdhZWM1ODUwZjg0ODFhYmE3ZDYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.q0Er2tdIyaEVnmI7TTwzEvehFnUdtp6MjquigRezdg0)