With this package you can paginate and sort inline admin
Project description
Django inline column extension
It's a django package that you can use in django inline admin for pagination and sorting columns like change list page.
How to use this?
First add inline_admin_extensions to your django apps:
INSTALLED_APPS = [
'...',
'inline_admin_extensions',
'...',
]
then define your models:
#models.py
from django.db import models
class Author(models.Model):
name = models.CharField(max_length=100)
class Book(models.Model):
author = models.ForeignKey(Author, on_delete=models.CASCADE)
title = models.CharField(max_length=100)
isbn = models.CharField(max_length=100)
then in your admin.py:
#admin.py
from django.contrib import admin
from inline_admin_extensions.admin import PaginationInline
from inlineadmin.models import Author, Book
class BookInline(PaginationInline):
model = Book
per_page = 5
@admin.register(Author)
class AuthorAdmin(admin.ModelAdmin):
inlines = [BookInline]
you see like this:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file django_inline_column_extension-1.0.tar.gz.
File metadata
- Download URL: django_inline_column_extension-1.0.tar.gz
- Upload date:
- Size: 7.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2badf1872b81f89fe242628ea5ef224efe956d5e583d1d8602696d1dde0613d7
|
|
| MD5 |
c3161b9c8c19df7ac65350b35554eb8c
|
|
| BLAKE2b-256 |
230a0615ea1d843e2240bdf3133bf2c22f2e0e96c7534693e980e86dd6cbba9a
|
File details
Details for the file Django_inline_column_extension-1.0-py3-none-any.whl.
File metadata
- Download URL: Django_inline_column_extension-1.0-py3-none-any.whl
- Upload date:
- Size: 9.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
90da391234a4326a8fc821b22833ea86b8039a8a9ce8d5d15a06fcb09320b725
|
|
| MD5 |
b4db1143ed56ba057349ab364ca6f555
|
|
| BLAKE2b-256 |
2fe23b37dfdd8b8dcdae11d633b322e0531f6bdadcf7733ff933aa8ff3c57997
|