From e5dc1c48ea48177e21cff6670a2dbf0c4c4cf262 Mon Sep 17 00:00:00 2001 From: Aamir Khan Date: Fri, 10 Aug 2012 06:21:15 +0530 Subject: Feature : Add tag to email threads --- hyperkitty/templates/thread.html | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'hyperkitty/templates/thread.html') diff --git a/hyperkitty/templates/thread.html b/hyperkitty/templates/thread.html index a1bc38c..20248f1 100644 --- a/hyperkitty/templates/thread.html +++ b/hyperkitty/templates/thread.html @@ -93,7 +93,24 @@ }); + $("#add_tag_form").submit( function () { + + {% if user.is_authenticated %} + $.ajax({ + type: "POST", + data : $(this).serialize(), + url: "{% url add_tag mlist_fqdn=list_address, email_id=first_mail.message_id %}", + success: function(data){ + console.log('Tag is added successfully'); + } + }); + return false; + {% else %} + alert('You need to login in order to add tag'); + {% endif %} + }); + + }); - {% endblock %} -- cgit