UIPaging constructor

UIPaging({
  1. required WebRequest rq,
  2. required String widget,
  3. Map<String, Object?> params = const {},
  4. required int page,
  5. required int total,
  6. int pageSize = 20,
  7. String profix = 'page',
  8. Map<String, String> otherQuery = const <String, String>{},
  9. int widthSide = 2,
  10. bool useRequsetQueries = false,
  11. String orderBy = '',
  12. bool orderReverse = false,
})

Creates a new UIPaging instance.

The constructor requires the current request object rq, a widget identifier, and the page and total number of items. Optional parameters include:

  • pageSize: The number of items per page (default is 20).
  • profix: The page query parameter name (default is 'page').
  • otherQuery: Additional query parameters.
  • widthSide: The number of pages to show on each side of the current page (default is 2).
  • useRequsetQueries: Whether to include request query parameters.
  • orderBy: The field used for ordering.
  • orderReverse: Whether the order is reversed (descending).

Implementation

UIPaging({
  required super.rq,
  required super.widget,
  super.params,

  ///
  required this.page,
  required this.total,
  this.pageSize = 20,
  this.profix = 'page',
  this.otherQuery = const <String, String>{},
  this.widthSide = 2,
  this.useRequsetQueries = false,

  ///
  this.orderBy = '',
  this.orderReverse = false,
});