django-model-mixin 
GitHub

Test

Check Demo Project
- Check the demo repo on GitHub
Requirements
- Python 3.9+ supported.
- Django 3.2+ supported.
Setup
- Install from pip:
pip install django-model-mixin
- Modify
settings.pyby adding the app toINSTALLED_APPS:
INSTALLED_APPS = [
"django.contrib.admin",
"model_mixin",
]
- Modify your project
models.pywith needed imports and class extends:
from model_mixin.models import AuditModelMixin, PublishModelMixin
class MyCustomClass(AuditModelMixin, PublishModelMixin):
pass
- Execute Django's command
makemigrationsinside your project's root:
python manage.py makemigrations
- Finally, execute Django's command
migrateinside your project's root:
python manage.py migrate
Run Example Project
git clone --depth=50 --branch=django-model-mixin https://github.com/DLRSP/example.git DLRSP/example
cd DLRSP/example
python manage.py runserver
Now browser the app @ http://127.0.0.1:8000
Metadata
Release files for django-model-mixin 0.3.10
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| django_model_mixin-0.3.10.tar.gz | 18.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| django_model_mixin-0.3.10-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 38.1 kB
Release files / django_model_mixin-0.3.10.tar.gz
| Download URL | django_model_mixin-0.3.10.tar.gz |
|---|---|
| Size | 18.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2c8e1409f8c767ee3b1ac0a36be7dabd8e47391e698865fb7b9b56c4baa92e2c
|
|
BLAKE2b-256 checksum How to use checksums |
2c623ba1767d7c212fa6ea4c1585eff1d0c9b8ad7e49d9791ea1a1b75d24c73f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / django_model_mixin-0.3.10-py3-none-any.whl
| Download URL | django_model_mixin-0.3.10-py3-none-any.whl |
|---|---|
| Size | 19.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
77c9d04145af4d4fb6cb4f07854393effa59bc5eca6f43672debc07fedd981f0
|
|
BLAKE2b-256 checksum How to use checksums |
2b199829c386f958069570ccf7a46fd470f710195aecc9efb35d86cd8a7c52c2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|