This is an educational project to teach Flask to people who already know Python and the basics of how the HTTP protocol works.
See this playlist: https://www.youtube.com/playlist?list=PL6f2gQ2RXLosWiXDHM7vOr1MPdfxPAm_t
See this video: https://www.youtube.com/watch?v=WWkJLTMbL9A
Create your virtualenv (using python3):
$ python3 -m venv .venv
Install requirements:
$ pip install -r requirements.txt
Configure your local .env
file:
$ cp contrib/env-sample .env
Open .env
with your favorite editor and configure your paramethers. Run your server with command below:
$ python manage.py runserver
More information? Follow explanatory videos below.
Inside on your virtualenv:
$ python manage.py shell
Import db and model:
from tvseries.ext import db
from tvseries.core.models import TVSerie
Bind your session with your application:
db.app = app
Quering example:
db.session.query(TVSerie).all()
If operation is "create", "update" or "delete" dont forget to run commit operation to confirm operation:
db.session.commit()
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/1.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/1.0
- See video: https://www.youtube.com/watch?v=i5ewUO-zX4g
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/2.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/2.0
- See video: https://www.youtube.com/watch?v=CxVhTwGtb3Y
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/3.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/3.0
- See video: https://www.youtube.com/watch?v=KGNFeMb39A0
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/4.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/4.0
- See video: https://www.youtube.com/watch?v=8h9CC2zexsI
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/5.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/5.0
- See video: https://www.youtube.com/watch?v=VsFtrqTFyEE
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/6.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/6.0
- See video: https://www.youtube.com/watch?v=ZMGimM8pE78
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/7.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/7.0
- See video: https://www.youtube.com/watch?v=-XDWUBIccrw
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/8.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/8.0
- See video: https://www.youtube.com/watch?v=mjrJOQAoDWk
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/9.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/9.0
- See video: https://www.youtube.com/watch?v=8hZQGDSA1Yo
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/10.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/10.0
- See video: https://www.youtube.com/watch?v=guKkJmTGVgc
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/11.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/11.0
- See video: https://www.youtube.com/watch?v=k1IagndK9F8
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/12.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/12.0
- See video: https://www.youtube.com/watch?v=t4dGoI4S4SE
- See release code: https://github.com/rafaelhenrique/flask_tutorial/tree/13.0
- See explanation about release: https://github.com/rafaelhenrique/flask_tutorial/releases/tag/13.0
- See videos: