brack3t / Djrill

[INACTIVE/UNMAINTAINED] Djrill is an email backend and new message class for Django users that want to take advantage of the Mandrill transactional email service from MailChimp.
BSD 3-Clause "New" or "Revised" License
319 stars 64 forks source link

Mandrill Templates expect {name:'', content:''} #24

Closed joual closed 11 years ago

joual commented 11 years ago

And Djrill provides {name:'', value:''} pairs for template_content.

This is what mandrill received in one call using template_name/template_content on EmailMessage().

{"template_content": [{"name": "description", "value": "This is how I found it"}, {"name": "page", "value": "\/dashboard\/"}, {"name": "title", "value": "I found a bug"}, {"name": "type", "value": "bug"}, {"name": "user", "value": "...@gmail.com"}], "template_name": "beta_feedback", "message": {"text": "", "from_name": "Feedback Service", "from_email": "...", "to": [{"email": "...@gmail.com", "name": ""}], "subject": "Feedback submitted"}, "key": "..."}

and in the api they clearly state :

"template_content": [
        {
            "name": "example name",
            "content": "example content"
        }
    ],

So basically I receive the correct email but all mc:edit fields are empty.

p.s. : I replaced any sensitive content with (...)

medmunds commented 11 years ago

Oops, you're absolutely right. The same problem also affects merge_vars and global_merge_vars. Fix going in now.