Emina
Emina

Reputation: 33

How to change ng-table pagination?

How to change ng-table pagination? Default values are 10, 25, 50, 100. I want to start with minimum of 100, and when I change count to be 100 pagination still starts from 10

$scope.tableParams = new NgTableParams({ page:1, count: 100 }

Upvotes: 0

Views: 1442

Answers (1)

Jorge Parga
Jorge Parga

Reputation: 11

ng table on the init accepts two objects as parameters

var tableSettings = {},
    tableParams =  {
        counts: [100, 200, 300]
    },
    table = false;

table = new NgTableParams(tableSettings, tableParams);

on the second object you can declare the counts you want to show and use over the table.

Upvotes: 1

Related Questions