Adding more structure to JSONFields
Project description
Adding more structure to JSONFields
Documentation
The full documentation is at https://structjsonfield.readthedocs.io.
Quickstart
Install Django Structured JSONField:
pip install structjsonfield
Add it to your INSTALLED_APPS:
INSTALLED_APPS = (
...
'structjsonfield',
...
)
Use the StructJSONField in your form
from structjsonfield import StructJSONField
ingredients = StructJSONField(
structure={
'name': forms.CharField(label=_('Name')),
'amount': forms.CharField(label=_('Amount')),
'units': forms.CharField(label=_('Units'))
})
Prerequisites
Make sure you have jQuery loaded in your template
Make sure you load the necessary form media (js + css)
Features
TODO
Running Tests
Does the code actually work?
source <YOURVIRTUALENV>/bin/activate (myenv) $ pip install tox (myenv) $ tox
History
0.1.0 (xxxx-xx-xx)
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
structjsonfield-0.1.0.tar.gz
(9.5 kB
view hashes)
Built Distribution
Close
Hashes for structjsonfield-0.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5bd2ecc57576929fc774c36147951b0c6f5f49214c86adda0ac765c385fb7ee9 |
|
MD5 | 2d1f26409347b3ac494cc1d3140a8525 |
|
BLAKE2b-256 | 5bcc3af2548a2db76f309c8d3083eb5b06f8ee4299de8783f1563e3a81841bd1 |