44from ..API .committee import addCommitteeMembers , removeCommitteeMembers , getCommitteeMembers
55from ..API .faculty import getFacultyWithAcceptedProjects
66from ..API .budget import getTotalBudget
7+ from ..API .files import create_message
78
89
910from ..pages import *
@@ -60,7 +61,6 @@ def awardLetters_generate(username,pID):
6061 if not g .user .isCommitteeMember :
6162 abort (403 )
6263 # All of our queries
63- print (pID )
6464 project = Projects .get (Projects .pID == pID )
6565 # we need the current year to get current faculty with projects
6666 template = EmailTemplates .get (EmailTemplates .eID == 1 )
@@ -80,19 +80,8 @@ def awardLetters_generate(username,pID):
8080 body = body .replace ("@@Start Date@@" ,start )
8181 body = body .replace ("@@End Date@@" ,end )
8282 body = body .replace ("@@Stipend@@" ,stipend )
83-
84- mail_to = "mailto:%[email protected] ?subject=%s&body=%s" % (
username ,
subject ,
body )
85-
86- #Replace common html tags to ascii hex values
87- mail_to = mail_to .replace (" " ," " )
88- mail_to = mail_to .replace ("“" ,"%22" )
89- mail_to = mail_to .replace ("”" ,"%22" )
90- mail_to = mail_to .replace ("’" ,"%27" )
91- mail_to = mail_to .replace (" " , "%20" )
92- mail_to = mail_to .replace ("\n " , "%0A" )
93- mail_to = mail_to .replace ("<p>" ,"" )
94- mail_to = mail_to .replace ("</p>" ,"%0A" )
95-
83+ acceptance_email = create_message (
"%[email protected] " % (
username ),
body )
84+ mail .send (acceptance_email )
85+ mail_to = "JESSON IS HERE"
86+
9687 return jsonify ({"mail_to" : mail_to })
97-
98-
0 commit comments