Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

QuerysetPaginator

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

QuerysetPaginator

This package helps in paginating evaluated querysets

  • 0.0.2
  • PyPI
  • Socket score

Maintainers
1

Evaluated Queryset Paginator

This python package has been developed in order to overcome the issues of the default django.core.Paginator which does not paginate the evaluate query sets properly.

Functions
  • __init__() Constructor of the class which takes two parameters as input:

    1. query_set: The entire query set that needs to be paginated
    2. objects_per_page: The number of objects that are required for each page
  • paginate() This function is called by the constructor by default and performs the main task of forming the pages

  • page() Input parameters- page_number and returns the total number of pages generated

Exceptions

  • EmptyPageException This Exception is raised when the objects_per_page value passed is 0

  • EmptyQuerysetException This Exception is raised when the total number of objects in the query_set is 0

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc