// Ex: <crmAddName crm-options="['Alpha','Beta','Gamma']" crm-var="newItem" crm-on-add="callMyCreateFunction(newItem)" />
crmMailingAB.controller('ABListingCtrl', function ($scope, crmApi,mailingABList) {
$scope.mailingABList = mailingABList.values;
+ $scope.testing_criteria = {
+ '1': "Subject lines",
+ '2': "From names",
+ '3': "Two different emails"
+ };
});
crmMailingAB.controller('ReportCtrl', function ($scope, crmApi, selectedABTest,$location) {
<tr>
<th>Title</th>
<th>Id</th>
+ <th>Test Type</th>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
- <tr ng-repeat="ab in mailingABList">
- <td>{{ab.name}}</td>
- <td>{{ab.id}}</td>
- <td><a class="action-item crm-hover-button" ng-href="#/mailing/abtesting/{{ab.id}}">Edit</a> 
- <a class="action-item crm-hover-button" ng-href="#/mailing/abtesting/report/{{ab.id}}">Results</a></td>
+ <tr ng-repeat="mailingAB in mailingABList">
+ <td>{{mailingAB.name}}</td>
+ <td>{{mailingAB.id}}</td>
+ <td>{{testing_criteria[mailingAB.testing_criteria_id]}}</td>
+ <td><a class="action-item crm-hover-button" ng-href="#/mailing/abtesting/{{mailingAB.id}}">Edit</a> 
+ <a class="action-item crm-hover-button" ng-href="#/mailing/abtesting/report/{{mailingAB.id}}">Results</a></td>
</tr>
</tbody>