Django plgooge practice modules.
Project description
Django plgooge practice modules.
Documentation
The full documentation is at https://django-dj-plugin.readthedocs.io.
Quickstart
Install django-dj-plugin:
pip install django-dj-plugin
Add it to your INSTALLED_APPS:
INSTALLED_APPS = ( ... 'django_dj_plugin.apps.DjangoDjPluginConfig', ... )
Add django-dj-plugin’s URL patterns:
from django_dj_plugin import urls as django_dj_plugin_urls urlpatterns = [ ... url(r'^', include(django_dj_plugin_urls)), ... ]
If you want to sort menu or hidden menu, replace ‘django.contrib.admin’ with ‘custadmin’ in your INSTALLED_APPS:
INSTALLED_APPS = ( ... # 'django.contrib.admin', 'custadmin', ... )
Add attribute(menu_hidden/menu_index) to your modelAdmin:
from django.contrib import admin @admin.register(XXXModel) class XXXModelAdmin(admin.ModelAdmin): menu_hidden = True # True:hidden the menu menu_index = 1 # type is int, The lower the value, the higher the rank
If you want add self-defined menu, Add it to your INSTALLED_APPS and execute: python manage.py migrate:
INSTALLED_APPS = ( ... 'custmenu', ... ) execute: python manage.py migrate
Features
- TODO
Running Tests
Does the code actually work?
source <YOURVIRTUALENV>/bin/activate (myenv) $ pip install tox (myenv) $ tox
History
0.1.0 (2020-01-22)
- First release on PyPI.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
django-dj-plugin-0.10.0.tar.gz
(14.0 kB
view hashes)