From 8d8eb785e6bda35fb36dd15ebdf4f3e487af00e2 Mon Sep 17 00:00:00 2001 From: aditya-nambiar Date: Sun, 15 Jun 2014 00:50:34 -0400 Subject: [PATCH] 3rd stage --- js/angular-crmMailingAB.js | 83 +++++++++++++++++++++++ partials/abtesting/helloworld.html | 95 +++++++++++++++++++++++++++ partials/abtesting/modal.html | 11 ++++ partials/abtesting/subject_lines.html | 2 +- 4 files changed, 190 insertions(+), 1 deletion(-) create mode 100644 partials/abtesting/helloworld.html create mode 100644 partials/abtesting/modal.html diff --git a/js/angular-crmMailingAB.js b/js/angular-crmMailingAB.js index c1b21625ad..cb86d3516c 100644 --- a/js/angular-crmMailingAB.js +++ b/js/angular-crmMailingAB.js @@ -73,6 +73,8 @@ {name:'2emails',url: partialUrl('two_emails.html')} ]; $scope.template = $scope.templates[0]; + $scope.slide_value = 0; + }); @@ -104,6 +106,87 @@ }; }); + crmMailingAB.directive('groupselect',function(){ + return { + + restrict : 'AE', + + link: function(scope,element, attrs){ + + $(document).ready(function() { $(element).select2({width:"400px",placeholder: "Select the groups you wish to include"}); + + }); + + } + }; + + }); + + crmMailingAB.directive('sliderbar',function(){ + return{ + + restrict: 'AE', + + link: function(scope,element, attrs){ + + $(element).slider(); + $(element).slider({ + slide: function( event, ui ) { + scope.slide_value = ui.value; + scope.$apply(); + + } + }); + } + + }; + + }); + + crmMailingAB.directive('modal_win',function(){ + return { + + restrict: 'AE', + + + + link: function(scope,element,attr){ + + + + scope.$watch("automated", function() { + alert("cgh"); + console.log("Sd"); + + }); + + + } + + }; + + }); + + crmMailingAB.directive('num_select',function(){ + return { + + restrict: 'AE', + + link: function(scope,element,attr){ + + $(element).spinner(); + } + + + }; + + + }); + + + + + diff --git a/partials/abtesting/helloworld.html b/partials/abtesting/helloworld.html new file mode 100644 index 0000000000..7b775cc9e5 --- /dev/null +++ b/partials/abtesting/helloworld.html @@ -0,0 +1,95 @@ + + + +
+ + +
+ + + + +
+ +
+ +

What would you like to test ?



+ +   Subject Lines

+   From Names

+   Two different Emails

+  
+
+
+ +
+ +
+
+ +
+ + + + +
+ +
+ +
+ +
+ +
+

Select the groups you would like to add


+ + +  

+ +

Select the size of your test group


+ +   Percentage Selected - {{slide_value}}% + +
+ +

How will the winner be decided


+   Open

+   Total Unique Clicks

+   Total Clicks on a particular link

+ +

Do you want the A/B test to be automated

+  Yes   +   No

+ + + +

Declare the winner in how much time?

+ + + + +
+
+
+ +
dsfdfbdfg + + +
+
+ + + +
\ No newline at end of file diff --git a/partials/abtesting/modal.html b/partials/abtesting/modal.html new file mode 100644 index 0000000000..ca824545b3 --- /dev/null +++ b/partials/abtesting/modal.html @@ -0,0 +1,11 @@ +
+ +

Please enter the confidence level at which a decision can be made

+
+ +

If the confidence level is not reached what do you want us to do?

+   Inform me

+   Send Version A

+   Send Version B

+ +
\ No newline at end of file diff --git a/partials/abtesting/subject_lines.html b/partials/abtesting/subject_lines.html index 588fb53745..4522eb2923 100644 --- a/partials/abtesting/subject_lines.html +++ b/partials/abtesting/subject_lines.html @@ -7,7 +7,7 @@ From Email Address:
Use Template :
Mail Subject A:
- Mail Subject B:
< + Mail Subject B: