mirror of
https://github.com/himool/HimoolERP.git
synced 2024-11-15 11:58:42 +08:00
18 lines
375 B
Python
18 lines
375 B
Python
from rest_framework.pagination import PageNumberPagination
|
|
|
|
|
|
class BasePagination(PageNumberPagination):
|
|
invalid_page_message = '无效页面'
|
|
page_size_query_param = 'page_size'
|
|
max_page_size = 64
|
|
page_size = 16
|
|
|
|
|
|
class OptionPagination(BasePagination):
|
|
max_page_size = 999999
|
|
page_size = 16
|
|
|
|
|
|
__all__ = [
|
|
'BasePagination', 'OptionPagination',
|
|
]
|