CRM-15578 - crmMailing - Fix for sending tests
authorTim Otten <totten@civicrm.org>
Thu, 18 Dec 2014 08:11:32 +0000 (00:11 -0800)
committerTim Otten <totten@civicrm.org>
Thu, 18 Dec 2014 10:51:19 +0000 (02:51 -0800)
commit58dfba8d4b6ad8a7f13672de86be9cd7b087f303
treede5eee43e789de97902fa0979ebc3289161916fc
parent1af78dba45e9c0e88795f48d5338badc5258b091
CRM-15578 - crmMailing - Fix for sending tests

The basic problem is that one must save before sending a test -- and the
"save" mechanics are necessarily different for crmMailing and crmMailingAB.

This commit resolves the problem by refactoring to eliminate PreviewMailingCtrl.
Now:

 * Ultimate authority for deciding how to perform a preview or test mailing lies with
   the main page (EditMailingCtrl, crmMailing/edit.html, CrmMailingABEditCtrl, crmMailingAB/edit.html)
 * We don't want it to be difficult for the main page to do that, so we define two reusable
   components -- directive crmMailingBlockPreview and service crmMailingPreviewMgr.
js/angular-crmMailing.js
js/angular-crmMailing/directives.js
js/angular-crmMailing/services.js
js/angular-crmMailingAB.js
partials/crmMailing/edit-unified.html
partials/crmMailing/edit-unified2.html
partials/crmMailing/edit-wizard.html
partials/crmMailing/edit.html
partials/crmMailing/preview.html
partials/crmMailing/review.html
partials/crmMailingAB/edit.html