DoSomething/dosomething — pull request #3640 by DeeZone (2014-12-16 03:09:41+00:00)
Title: Issue3523 mbp international settings

Fixes #3523

Moves from hard coded template setting in transactional payloads to dynamic setting by "Application ID" (Affiliate country code) and available templates in Mandrill.

- Adds admin setting for "Application ID" (Affiliate country code) that's connected to the same setting in `message_broker_producer` module.
- Adds admin setting for Mandrill API key.
- Uses cURL call to Mandrill API to lookup templates by "Application ID" (Affiliate country code).
- Adds admin interface to manage template assignment to email transaction types: `user_registration`, `user_password`, `campaign_signup`, `campaign_group_signup` and `campaign_reportback` by "Application ID" (Affiliate country code) .
- Uses template assignments to define 'template` value in message payloads replacing hard code / US specific settings.

**To test**:
- go to `/admin/config/dosomething/dosomething_mbp`
- Add "Application ID", ex: "CA". Currently only template entries for "CA" and "GB".
- Add Mandrill Key setting
- Save form to be presented with "Transactional Template" settings for each transaction type
- Create test transaction to trigger transactional messages using selected template.