This App provides RESTfull APIs for products at ECC
Python 3.6.5 Django==3.1.12 djongo==1.3.6 MongoDB - V4 and up - installed locally or in Docker
Make sure above Stack is avaiable on the machine for local installation
- update databse name, host, port in product/setting.py
- Create local python enviornment using virtualenv
- run following command to install requirments
pip install -r requirements.txt
- Migrate Database - if not already set (this will create an empty database)
python manage.py migrate
- Import initial data available under mongo-see/init.json to pro.productApi_product
App (Django and mongodb) can be installed using following docker commands and is available at http://localhost:3000/api/products This should provide two container, one for APP and another for mongo db. Data will be pre-populated from mongo-seed/dump using mongorestore
docker-compose build --no-cache
docker-compose up
Swagger http://localhost:3000/doc/
List all prodcuts http://localhost:3000/api/products
Display full information about a product http://localhost:3000/api/products/
Keep Developer names in array when making an edit else it will break the format, this is a temp solution and needs to be modified.
When you add new project, make sure to add multiple developer names sepeated by comma: