From 3ad2ea698caa0c3d6286274702e75e2bd4267bdd Mon Sep 17 00:00:00 2001 From: Tim Otten Date: Thu, 19 Feb 2015 14:15:13 -0800 Subject: [PATCH] CRM-15979 - crmMailingAB - More symmetry between edit and report modes. The top level file is "main.html" which includes either "edit.html" or "report.html" depending on whether the test has been submitted. --- js/angular-crmMailingAB.js | 12 +----------- partials/crmMailingAB/edit.html | 17 +++++------------ partials/crmMailingAB/main.html | 12 ++++++++++++ partials/crmMailingAB/report.html | 3 +++ 4 files changed, 21 insertions(+), 23 deletions(-) create mode 100644 partials/crmMailingAB/main.html diff --git a/js/angular-crmMailingAB.js b/js/angular-crmMailingAB.js index 97251357b9..0dd847c310 100644 --- a/js/angular-crmMailingAB.js +++ b/js/angular-crmMailingAB.js @@ -29,7 +29,7 @@ } }); $routeProvider.when('/abtest/:id', { - templateUrl: '~/crmMailingAB/edit.html', + templateUrl: '~/crmMailingAB/main.html', controller: 'CrmMailingABEditCtrl', resolve: { abtest: function ($route, CrmMailingAB) { @@ -38,16 +38,6 @@ } } }); - $routeProvider.when('/abtest/:id/report', { - templateUrl: '~/crmMailingAB/report.html', - controller: 'CrmMailingABReportCtrl', - resolve: { - abtest: function ($route, CrmMailingAB) { - var abtest = new CrmMailingAB($route.current.params.id); - return abtest.load(); - } - } - }); } ]); diff --git a/partials/crmMailingAB/edit.html b/partials/crmMailingAB/edit.html index 3def3ebbea..357d96fcc6 100644 --- a/partials/crmMailingAB/edit.html +++ b/partials/crmMailingAB/edit.html @@ -1,20 +1,13 @@ -
-
{{abtest.ab|json}}
-
{{abtest.mailings|json}}
-
- -
-
-
- -
-
+
+
{{ts('Save Draft')}}
- +
diff --git a/partials/crmMailingAB/main.html b/partials/crmMailingAB/main.html new file mode 100644 index 0000000000..668df76369 --- /dev/null +++ b/partials/crmMailingAB/main.html @@ -0,0 +1,12 @@ + +
+
{{abtest.ab|json}}
+
{{abtest.mailings|json}}
+
+ +
+
+
+
diff --git a/partials/crmMailingAB/report.html b/partials/crmMailingAB/report.html index 0e6d4cbc38..5cde438664 100644 --- a/partials/crmMailingAB/report.html +++ b/partials/crmMailingAB/report.html @@ -1,3 +1,6 @@ +
-- 2.25.1