This repository implements a weather app that uses Open Weather API and Django as a backend framework.
The following is a basic workflow that you can use as a quick reference for developing a Django Project.
Within a new directory, create and activate a virtualenv. Install Django.
django-admin.py startproject
Templates and Static Files
- Create a templates and static directory within your project root.
- Update settings.py to include the paths to your templates.
- Add a HTML file to the templates directory.
- Update the views.py file as necessary.
Models and Databases
Forms
- Create a forms.py file at the App to define form-related classes; define your ModelForm classes here.
- Add or update a view for handling the form logic - e.g., displaying the form, saving the form data, alerting the user about validation errors, etc.
- Add or update a template to display the form.
- Add a urlpattern in the App’s urls.py file for the new view.
- Create a UserForm
- Add a view for creating a new user.
- Add a template to display the form.
- Add a urlpattern for the new view.
User Registration