Script to generate views, templates and tests files for a given Django Model
Project description
Django Basic Crud Generator
- Django Basic CRUD Generator is a simple python script to generate views, templates and tests files for a given Django Model.
- The Script will generate the following files, using as base the templates inside django_basic_crud_generator/templates
├── APP_NAME
│ ├── templates
│ │ ├── MODEL_NAME
│ │ │ ├── MODEL_NAME_list.html
│ │ │ ├── MODEL_NAME_create.html
│ │ │ ├── MODEL_NAME_detail.html
│ │ │ ├── MODEL_NAME_update.html
│ │ │ ├── MODEL_NAME_delete.html
│ ├── tests
│ │ ├── MODEL_NAME
│ │ │ ├── __init__.py
│ │ │ ├── MODEL_NAME_list_test.py
│ │ │ ├── MODEL_NAME_create_test.py
│ │ │ ├── MODEL_NAME_detail_test.py
│ │ │ ├── MODEL_NAME_update_test.py
│ │ │ ├── MODEL_NAME_delete_test.py
│ ├── views
│ │ ├── MODEL_NAME
│ │ │ ├── __init__.py
│ │ │ ├── MODEL_NAME_list.py
│ │ │ ├── MODEL_NAME_create.py
│ │ │ ├── MODEL_NAME_detail.py
│ │ │ ├── MODEL_NAME_update.py
│ │ │ ├── MODEL_NAME_delete.py
│ │── urls.py
Installation:
Download the repository
git clone https://github.com/J-hanks/django_basic_crud_generator.git
Install using pip
pip install django_basic_crud_generator
Usage:
You must set app_name and model_name options
python -m django_basic_crud_generator --app_name YOUR_APP --model_name YOUR_MODEL
Options:
--app_name
: Your Django application name--model_name
: Your Django model name you want crud generated
Manually fix urls file:
- The urls.py file will need mannualy inspection
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
File details
Details for the file Django Basic CRUD Generator-0.1.tar.gz
.
File metadata
- Download URL: Django Basic CRUD Generator-0.1.tar.gz
- Upload date:
- Size: 5.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0bf74bdccc106ef19d1b93dd11147587117765585d9aa6b9a8d6b3e234ca1d26 |
|
MD5 | 7f3794c6958d706bbdd7f837b58297dd |
|
BLAKE2b-256 | 9f62ea08273a6b3defaf0d04b38afb6d4d117ba19327fd1e04ea2ca7ff2a0197 |
File details
Details for the file Django_Basic_CRUD_Generator-0.1-py3-none-any.whl
.
File metadata
- Download URL: Django_Basic_CRUD_Generator-0.1-py3-none-any.whl
- Upload date:
- Size: 11.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5b66552e8767c90aa41226a853085675cba21e641965939bdffd7d2d07870fd2 |
|
MD5 | c6069577cbcf4ed0b7fb035d862ef591 |
|
BLAKE2b-256 | b000a11e408bca59fc26e3b7e5d82e28441efe439d8b90944b8c07641b33d312 |