This is a Django project to manage mobile data, including information about mobile models, country producers, nationalities, prices, colors, sizes, and availability status.
- Save Mobile Data: Add new mobile models with related information to the database.
- Forms: Use simple templates to store mobile data with validation.
- Reports: Retrieve data in JSON format based on specific criteria.
- Unpredicted Data and Functions: Additional functionality for future use.
- Clone the repository to your local machine.
- Install the required dependencies by running:
pip install -r requirements.txt
- Create the database and perform migrations by running:
python manage.py makemigrations
andpython manage.py migrate
- Run the development server with:
python manage.py runserver
-
Save Mobile Data:
- Access the form to add new mobile models and their details by visiting
http://localhost:8000/add/
- Access the form to add new mobile models and their details by visiting
-
Reports:
- Get a list of all mobiles with nationality "korea":
http://localhost:8000/report/korea_nationality/
- Get a list of mobiles with the same brand name (provide brand_name in POST data):
http://localhost:8000/report/brand_mobiles/
- Get a list of mobiles with the same country producer and nationality:
http://localhost:8000/report/same_country_nationality/
- Get a list of all mobiles with nationality "korea":