Skip to main content

Description

The Results Per Page Directive allows you to change the number of documents that are returned from the platform. The results per page tag should be wrapped in a Layout Controls Tag.

Usage

as element:
<search:results-per-page
       response="{object}"
       [title="{string}"]
       [options="{string}"]>
</search:results-per-page>

Directive info

  • This directive creates new scope.

Parameters

ParamTypeDetails
responseobjectA response object
title (optional)stringThe title to display before the result count options.
options (optional)stringWhich options to provide the user. Should be a comma-separated list of integers.

Example

Source

<layout:controls>
  <search:results-per-page response="response" options="10,20,25,50"></search:results-per-page>
</layout:controls>
angular.module('lightning')
.controller('ExampleController', ['$scope', function($scope) {
          $scope.response = {

          }
        }]);

Result

Result
I