Create django front-end data apps
Project description
Django Front Data
A reusable dependency free django front data apps
Sometimes we need to fetch unstructured data from back-end to front-end such as navbar. But this is boring task as you have to design database for every type of data. We can avoid this by using a good JSON editor. This package contains a good JSON editor for admin panel. Also this package has built-in serializers and django rest api support.
Installation
-
Install the package
pip install django-front-data
-
Add into yours settings INSTALLED_APPS
front_data',
- If you have django rest framework installed you can add package urls to your
URL config
path('front-data/', include('front_data.urls'))
You can only use front_data.urls if you have djangorestframework installed
Settings
DEFAULT_SITE_DATA
You can use this setting to automatically add template. examples:
DEFAULT_SITE_DATA = [ { "name": "nav-bar", "data": [], "templates": [ { "text": "Navbar", "value": { "text": "", "link": "" } } ] } ]
Above example will create front data instance named navbar
when you start
your server. It will skip if there is already navbar
instance in
database. This will also create a template named navBar
. See
template section about what you can do with template.
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
Hashes for django_front_data-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a2edc3f51775ff9ba1450c0a03a41d6375fd10c9406efa190b4e31492db26138 |
|
MD5 | 6b3208340cb2adcf956f6c4c6568858f |
|
BLAKE2b-256 | b55b86f3f5dcf0d9dbf48a110722eb01eb90878666571e2c3e96499393847a81 |