'label',
'api_entity',
'api_params',
+ 'created.display_name',
+ 'modified.display_name',
+ 'created_date',
+ 'modified_date',
'GROUP_CONCAT(display.name ORDER BY display.id) AS display_name',
'GROUP_CONCAT(display.label ORDER BY display.id) AS display_label',
'GROUP_CONCAT(display.type:icon ORDER BY display.id) AS display_icon',
angular.module('crmSearchAdmin').controller('searchList', function($scope, savedSearches, crmApi4) {
var ts = $scope.ts = CRM.ts('org.civicrm.search'),
ctrl = $scope.$ctrl = this;
+ $scope.formatDate = CRM.utils.formatDate;
this.savedSearches = savedSearches;
this.afformEnabled = CRM.crmSearchAdmin.afformEnabled;
this.afformAdminEnabled = CRM.crmSearchAdmin.afformAdminEnabled;
<th>{{:: ts('Displays') }}</th>
<th>{{:: ts('Smart Group') }}</th>
<th ng-if="$ctrl.afformEnabled">{{:: ts('Forms') }}</th>
+ <th>{{:: ts('Created') }}</th>
+ <th>{{:: ts('Last Modified') }}</th>
<th></th>
</tr>
</thead>
<tbody>
<tr ng-repeat="search in $ctrl.savedSearches | filter:$ctrl.searchFilter">
- <td>{{ search.id }}</td>
- <td>{{ search.label }}</td>
- <td>{{ $ctrl.entityTitles[search.api_entity] }}</td>
+ <td>{{:: search.id }}</td>
+ <td>{{:: search.label }}</td>
+ <td>{{:: $ctrl.entityTitles[search.api_entity] }}</td>
<td>
<div class="btn-group">
<button type="button" disabled ng-if="!search.display_name" class="btn btn-xs dropdown-toggle btn-primary-outline">
</ul>
</div>
</td>
- <td>{{ search.groups.join(', ') }}</td>
+ <td>{{:: search.groups.join(', ') }}</td>
<td ng-if="::$ctrl.afformEnabled">
<div class="btn-group">
<button type="button" ng-click="$ctrl.loadAfforms()" ng-if="search.display_name" class="btn btn-xs dropdown-toggle btn-primary-outline" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
</ul>
</div>
</td>
+ <td>{{:: ts('%1 by %2', {1: formatDate(search.created_date), 2: search['created.display_name']}) }}</td>
+ <td>{{:: ts('%1 by %2', {1: formatDate(search.created_date), 2: search['modified.display_name']}) }}</td>
<td class="text-right">
<a class="btn btn-xs btn-default" href="#/edit/{{:: search.id }}">{{:: ts('Edit') }}</a>
<a class="btn btn-xs btn-default" href="#/create/{{:: search.api_entity + '?params=' + $ctrl.encode(search.api_params) }}">{{:: ts('Clone') }}</a>