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

drf_pagination

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

drf_pagination

Django REST framework additional pagination

  • 1.0.0
  • PyPI
  • Socket score

Maintainers
1

drf-paginations

Other paginations based on Django REST framework

PyPI - Version PyPI - Downloads

  • Author: xcai
  • Version: 1.0.0
  • License: MIT

drf-paginations is a collections of paginations for Django REST framework. includes: LimitOffsetPaginationForDataTable...

drf-paginations 增加适配前端Datatable表格组件的limitoffset分页器,例如LimitOffsetPaginationForDataTable

Documentation

  • Install drf-paginations from PyPI(安装):
        pip install drf-paginations
  • Import the pagination class into your project(使用):
from drf_pagination.pagination import LimitOffsetPaginationForDataTable
from rest_framework.generics import ListAPIView


class MyStoryListAPIView(ListAPIView):
    ...
    pagination_class = LimitOffsetPaginationForDataTable

  • Response format data(接口返回数据格式,适配Datatable):
{
    "draw": 1,
    "recordsTotal": 100,
    "recordsFiltered": 10,
    "data": [
      {...},
      {...}
]}

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