summaryrefslogtreecommitdiff
path: root/website
diff options
context:
space:
mode:
authorkomalsheth2862016-10-03 14:00:26 +0530
committerkomalsheth2862016-10-03 14:00:26 +0530
commitcfd8fc0ecfaf6d28cc23ac977e7acc1764ffe2b6 (patch)
treeadeaff03bbd1b6218bcee4729a13d98aab30dc08 /website
parenta78f7e60e1f6eca111fe36d6a2fb26231bbc0634 (diff)
downloadSciPy2016-cfd8fc0ecfaf6d28cc23ac977e7acc1764ffe2b6.tar.gz
SciPy2016-cfd8fc0ecfaf6d28cc23ac977e7acc1764ffe2b6.tar.bz2
SciPy2016-cfd8fc0ecfaf6d28cc23ac977e7acc1764ffe2b6.zip
Email template
Diffstat (limited to 'website')
-rwxr-xr-xwebsite/views.py24
1 files changed, 12 insertions, 12 deletions
diff --git a/website/views.py b/website/views.py
index e889798..089b49c 100755
--- a/website/views.py
+++ b/website/views.py
@@ -153,21 +153,17 @@ def submitcfp(request):
sender_email = "scipy@fossee.in"
subject = "SciPy India 2016 – Talk Proposal Submission Acknowledgment"
to = (social_user.email, "scipy@fossee.in")
- message = """
- Dear {0}, <br><br>
- Thank you for showing interest & submitting a talk proposal at SciPy India 2016 conference for the talk titled “{1}”. Reviewal of the proposals will start once the CFP closes.
- <br><br>You will be notified regarding comments/selection/rejection of your talk via email.
- Visit this <html><body><a herf = 'http://scipy.in/2016/view-abstracts/'> link </a></html></body> to view status of your submission.
- Thank You ! <br><br>Regards,<br>SciPy India 2016,<br>FOSSEE - IIT Bombay.
- """.format(
- social_user.first_name,
- request.POST['title'], )
+ text_content = """Dear """+proposal.user.first_name+""",
+ Thank you for showing interest & submitting a talk proposal at SciPy India 2016 conference for the talk titled '"""+ request.POST['title']+ """'.
+ Reviewal of the proposals will start once the CFP closes.\n\n
+ You will be notified regarding comments/selection/rejection of your talk via email.\n"""
+ html_content = 'Visit this <a herf = "http://scipy.in/2016/view-abstracts/"> link </a> to view status of your submission.<br> Thank You ! <br><br>Regards,<br><a herf = “http://scipy.in/2016>SciPy</a> India 2016,<br>FOSSEE - IIT Bombay.'
email = EmailMultiAlternatives(
- subject,'',
+ subject,text_content,
sender_email, to,
headers={"Content-type":"text/html;charset=iso-8859-1"}
)
- email.attach_alternative(message, "text/html")
+ email.attach_alternative(html_content, "text/html")
email.send(fail_silently=True)
return render_to_response('cfp.html', context)
else:
@@ -210,7 +206,7 @@ def submitcfw(request):
Thank You ! <br><br>Regards,<br>SciPy India 2016,<br>FOSSEE - IIT Bombay.
""".format(
social_user.first_name,
- request.POST['title']
+ request.POST['title'],
'http://scipy.in/2016/view-abstracts/', )
email = EmailMultiAlternatives(
subject,'',
@@ -492,6 +488,10 @@ def status_change(request):
proposal = Proposal.objects.get(id = proposal_id)
proposal.delete()
context.update(csrf(request))
+ proposals = Proposal.objects.all()
+ context['proposals'] = proposals
+ context['user'] = user
+ return render(request, 'view-abstracts.html', context)
elif 'dump' in request.POST:
delete_proposal = request.POST.getlist('delete_proposal')
try: