This project is a web application built using the Django framework. Django is a high-level Python web framework that encourages rapid development and clean, pragmatic design. It is used to handle the backend logic, database interactions, and server-side processing for this project.
- User authentication and authorization
- Database management with Django ORM
- Dynamic HTML rendering with Django templates
- Static file handling
- Form handling and validation
- URL routing and request handling
-
Clone the repository:
git clone https://github.com/ngxvu/commerce.git cd commerce
-
Create a virtual environment and activate it:
python -m venv venv source venv/bin/activate # On Windows use `venv\Scripts\activate`
-
Install the required packages:
pip install -r requirements.txt
-
Apply migrations:
python manage.py migrate
-
Run the development server:
python manage.py runserver
- Open your web browser and navigate to
http://127.0.0.1:8000/
. - Register a new user or log in with existing credentials.
- Explore the features of the web application.
Django is used in this project to:
- Handle HTTP requests and responses: Django's URL dispatcher maps URLs to views, which process requests and return responses.
- Manage the database: Django ORM (Object-Relational Mapping) allows for easy database interactions without writing raw SQL.
- Render HTML templates: Django's template engine dynamically generates HTML pages based on the data passed from views.
- Handle static files: Django manages static files like CSS, JavaScript, and images.
- Form handling and validation: Django simplifies form creation, validation, and processing.
- Fork the repository.
- Create a new branch (
git checkout -b feature-branch
). - Make your changes and commit them (
git commit -m 'Add new feature'
). - Push to the branch (
git push origin feature-branch
). - Open a pull request.
This project is licensed under the MIT License. See the LICENSE
file for more details.