-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update: add the top Head Sender and add ome changes
- Loading branch information
Showing
6 changed files
with
6 additions
and
8 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,7 +23,7 @@ def create_accout(): | |
name = data.get('first_name') | ||
email = data.get('email') | ||
l_name = data.get('last_name') | ||
msg = Message('Time Master', sender='[email protected]', recipients=[email], bcc=['[email protected]']) | ||
msg = Message('Creation of Account', sender="Time Master [email protected]", recipients=[email], bcc=['[email protected]']) | ||
msg.body = "Hello {} {},\nYou have take a new step in the mangement of your \ | ||
life. I cant't wait to see you flourish".format(name, l_name) | ||
try: | ||
|
@@ -56,10 +56,9 @@ def change_password(): | |
user.save() | ||
name = data.get('first_name') | ||
email = data.get('email') | ||
msg = Message('Time Master', sender='[email protected]', recipients=[email], bcc=['[email protected]']) | ||
msg = Message('Changing of Password', sender='Time Master [email protected]', recipients=[email], bcc=['[email protected]']) | ||
msg.body = "Hello {},\nThis is to inform you that your password has been changed sucessfully \ | ||
if you are not the one contact the admin email [email protected]".format(name) | ||
print(msg.body) | ||
try: | ||
mail.send(msg) | ||
return jsonify({'status': 'success', 'user_id': user_id, 'description': 'Email sent'}), 201 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,10 +29,9 @@ def expire_project(): | |
expiry = datetime.strptime(expiry, "%Y-%m-%dT%H:%M:%S.%f") | ||
date = expiry.strftime('%Y-%m-%d') | ||
time = expiry.strftime('%H:%M:%S') | ||
msg = Message('Time Master', sender='[email protected]', recipients=[email]) | ||
msg = Message('Expiration of a project', sender='Time Master [email protected]', recipients=[email]) | ||
msg.body = "Hello {},\nYour project {} will soon expire on {} at {}. \ | ||
It's high time you completed the project".format(name, p_name, date, time) | ||
print(msg.body) | ||
try: | ||
mail.send(msg) | ||
return jsonify({'status': 'success', 'description': 'Email sent'}), 201 | ||
|
@@ -64,7 +63,7 @@ def expire_task(): | |
expiry = datetime.strptime(expiry, "%Y-%m-%dT%H:%M:%S.%f") | ||
date = expiry.strftime('%Y-%m-%d') | ||
time = expiry.strftime('%H:%M:%S') | ||
msg = Message('Time Master', sender='[email protected]', recipients=[email]) | ||
msg = Message('Expiration of a task', sender='Time Master [email protected]', recipients=[email]) | ||
msg.body = "Hello {},\nYour task {} under the project {} will soon expire on {} at {}. \ | ||
It's high time you completed the task so you could complete the project".format(name, task, p_name, date, time) | ||
try: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,7 +25,7 @@ def create_project(): | |
expiry = datetime.strptime(expiry, "%Y-%m-%dT%H:%M:%S.%f") | ||
date = expiry.strftime('%Y-%m-%d') | ||
time = expiry.strftime('%H:%M:%S') | ||
msg = Message('Time Master', sender='[email protected]', recipients=[email]) | ||
msg = Message('Creation of a Project', sender='Time Master [email protected]', recipients=[email]) | ||
msg.body = "Hello Great Time Master,\n You have created a new project \ | ||
with the name {}.The project will expire on {} at {}".format(name, date, time) | ||
try: | ||
|
@@ -56,7 +56,7 @@ def create_task(): | |
expiry = datetime.strptime(expiry, "%Y-%m-%dT%H:%M:%S.%f") | ||
date = expiry.strftime('%Y-%m-%d') | ||
time = expiry.strftime('%H:%M:%S') | ||
msg = Message('Time Master', sender='[email protected]', recipients=[email]) | ||
msg = Message('Creation of a Task', sender='Time Master [email protected]', recipients=[email]) | ||
msg.body = "Hello Great Time Master,\n You have created a new task {}\ | ||
under the project {}.The project will expire on {} at {}".format(name, project, date, time) | ||
try: | ||
|