

URL dispatcher (https://docs.djangoproject.com/en/3.0/topics/http/urls/)Cool URIs don't change (https://www.w3.org/Provider/Style/URI)
1. python manage.py makemigrations 2. python manage.py migrate

models.py ์์ฑ๋ ํ ์ด๋ธ ํ์ธ
Django / select_related์ prefetch_related๋ฅผ ์ ๋ณตํด๋ณด์ (https://bmh8993.github.io/Django/select_related%EC%99%80-prefetch_related%EB%A5%BC-%EC%A0%95%EB
1) ๊ฐ์ํ๊ฒฝ ๋ฆฌ์คํธ ํ์ธ (\"conda env list\") >conda env list 2) ๊ฐ์ํ๊ฒฝ ์์ฑ (\"conda create -n ๊ฐ์ํ๊ฒฝ๋ช \") >conda create -n ์์ฑํ ๊ฐ์ํ๊ฒฝ์ด๋ฆ python=์์ฑํ ๊ฐ์ํ๊ฒฝ์๋ฒ์ ๋ช ์ 3) ์์ฑ๋ ๊ฐ์ํ
Step#1์์ ์์ฑํ ๊ฐ์ํ๊ฒฝ์์ ์ฅ๊ณ ๋ฅผ ์ค์นํ๊ธฐ ์ ์! ์ฅ๊ณ ์ด์ฉ?์ ์ํด ํ์ํ ํ์ด์ฌ ํ์ ํ๋ก๊ทธ๋จ์ ์ค์นํ๊ฒ ์ต๋๋ค! ํ์ด์ฌ ํ์ ํ๋ก๊ทธ๋จ์ "pip"๋ผ๋ installer๋ฅผ ์ด์ฉํ ๊ฑฐ์์! pip๋ python3.7์๋ ๋ํดํธ๋ก ํฌํจ๋์ด ์์ด์! 1) pip
Step#1์์ ์์ฑํ ๊ฐ์ํ๊ฒฝ์ ๋๋์ด! Django๋ฅผ ์ค์นํด ๋ณด๊ฒ ์ต๋๋ค! 1) django ์ค์นgo! ("pip install django") >pip install django==๋ฒ์ ๋ช ๋ฒ์ ๋ช ์ ๋ช ์ํ์ง ์์ผ๋ฉด ๊ฐ์ฅ ์ต์ ๋ฒ์ ์ผ๋ก ์ค์น๊ฐ ๋ฉ๋๋ค! ์๊ธฐ์๋ ๊ฐ์ฅ ์ต
๊ฐ์ํ๊ฒฝ์์ django ๋๋ ํฐ๋ฆฌ ์์ฑํด๋ณผ๊ฒ์! 1) django ํ๋ก๊ทธ๋จ์ ๋ช ๋ น์ด ์ดํด๋ณด๊ธฐ 2) ํ์ฌ ์์น์ django ๋๋ ํฐ๋ฆฌ ์์ฑํ๊ธฐ ("django-admin startproject ์์ฑํ ๋๋ ํฐ๋ฆฌ๋ช .") >django-admin startproject ์
1) ์ฅ๊ณ ๋๋ ํฐ๋ฆฌ์ ๊ตฌ์กฐ django๊ฐ ์คํ๋๋ฉด ๋งจ์ฒ์์ ์ต์ด์์ฑ๋ ์ฅ๊ณ ๋๋ ํฐ๋ฆฌ๋ฅผ ๋ฐ๋ผ๋ณด๊ฒ ๋์ด์์ด์. ์ ๊ฐ ๋ง๋ django ๋๋ ํฐ๋ฆฌ๋ช ์ "mynewjangodirec"์ ๋๋ค. django ์๋ฒ๊ฐ ์์๋๋ฉด mynewjangodirec ๋๋ ํฐ๋ฆฌ ํ๋จ์ settings
1) ์ฅ๊ณ APP ์์ฑํ๊ธฐ >python manage.py startpp ์์ฑํ ์ฑ์ด๋ฆ 2) ์์ฑ๋ APP ํ์ผ ์ดํด๋ณด๊ธฐ
1) ์์ฑ๋ APP์ ์กด์ฌ๋ฅผ ์ฅ๊ณ ์๊ฒ ์๋ ค์! Step#6์์ "user"๋ผ๋ ์ด๋ฆ์ APP์ ์์ฑํ์๋๋ฐ์! ์์ฑ๋ APP์ ์กด์ฌ๋ฅผ ์ฅ๊ณ ์๊ฒ ์๋ฆฌ๊ธฐ ์ํ์ฌ, ์ฅ๊ณ ๋ก ์์ฑํ ํ๋ก์ ํธ ๋๋ ํฐ๋ฆฌ ์์ settings.py์๋ค๊ฐ ์๋์ ๊ฐ์ด "INSTALLED_APPS"์
models.py๋ ์ฅ๊ณ DB์ ์ค๊ณ๋๋ผ๊ณ ํ ์ ์์ด์. step#6์์ ์์ฑํ "user"๋ผ๋ ์ด๋ฆ์ app์ db ๋ชจ๋ธ์ ์ค๊ณํด ๋ณผ๊ฒ์. "user"์ฑ์ ํ์์ ๋ณด๋ฅผ ๊ด๋ฆฌํ๋ ์ฑ์ด์์. ๊ทธ๋์ "user"์ฑ ์์ models.py์ ํ์์ ๋ณด db๋ฅผ ์ค๊ณํ๋ ค๊ณ ํฉ๋๋ค.
views.py๋ ํด๋น APP์ ๋ก์ง์ ๋ด๋นํ๋ ํ์ผ์ ๋๋ค. step#6์์ ์์ฑํ "user"๋ผ๋ APP์ views.py ํ์ผ์ ๋ง๋ค์ด ๋ณด๊ฒ ์ต๋๋ค. 1) views.py ๋ด์ฉ ์์ฑ 2) ํด๋น APP์ urls.py ์์ ํ๊ธฐ ์์์ ์์ฑ๋ views.py๋ฅผ ์ฌ์ฉํ
1) ์ฅ๊ณ ๋๋ ํฐ๋ฆฌ์ urls.py ๋ด์ฉ ์์ ํ๊ธฐ ์ฅ๊ณ ์๋ฒ๊ฐ ์คํ๋๋ฉด ๋ฌด์กฐ๊ฑด ์ฅ๊ณ ๋๋ ํฐ๋ฆฌ์ urls.py๋ฅผ ๋ฐ๋ผ๋ณด๊ฒ ๋์ด์์ด์. ๊ทธ๋ฐ๋ฐ ๊ทธ urls.py์๋ ์์ง "user"๋ผ๋ ์ฐ๋ฆฌ๊ฐ ๋ง๋ app์ ๊ฒฝ๋ก๊ฐ ์์ด์. ๊ทธ๋์ ์ถ๊ฐํ ๊ฒ์! 2) ์ฅ๊ณ ์๋ฒ์คํํ๊ธฐ imag
1) "comment"๋ผ๋ ์ด๋ฆ์ APP ์์ฑ 2) ๋๊ธ์ ์ ์ฅํ db ์์ฑ: ๋๊ธ DB ํด๋์ค ์์ฑ(models.py) 3) ์์ฑํ "comment" ์ฑ์ settings.py์ ์ถ๊ฐํ๊ธฐ 4) comment ์ฑ migrate ํ๊ธฐ 5) comment ์ฑ์ vi
1) cors-headrs ํ๋ฌ๊ทธ์ธ ์ค์นํ๊ธฐ >pip install django-cors-headers 2) setting.py ์์ ํ๊ธฐ
1) bcryp์ pyjwt ํ๋ก๊ทธ๋จ ์ค์น 2) bcrypt ์ฌ์ฉ๋ฐฉ๋ฒ >bcrypt๋ก ํด์ ํจ์ค์๋ ์์ฑํ๊ธฐ bycrypt.hashpw(๋ฐ์ด๋๋ฆฌ๊ฐ, bcrypt.gensalt()) >bcrypt ํด์ํจ์ค์๋ ๊ฐ ์ฒดํฌ bycrypt.checkpw(๋ฐ์ด๋๋ฆฌ๊ฐ, ๋นํฌ๋ฆฝํธ
1) ๋ก๊ทธ์ธ ์ฑ์ views.py ์์ ํ๊ธฐ 2) ์ฅ๊ณ ์๋ฒ ์คํํด์ ํ ์คํธํ๊ธฐ image.png image.png
1. flake8 ์ค์นํ๊ธฐ 2. flake8 ์ฌ์ฉํ๊ธฐ

./blog/models.py์์ ๋ชจ๋ธ์ migrateํ๋ฉด DB์๋ ์ด๋ค ํ ์ด๋ธ๋ค์ด ์๊ธธ๊น?blog_blogblog_authorblog_entry๊ทธ๋ฆฌ๊ณ Entry์ ManyToManyField ์ค์ ์ ์๊ธด!blog_entry_authorsblog_blogCREATE T

https://docs.djangoproject.com/en/3.1/ref/models/fields/
django ์ฟผ๋ฆฌ์ ์์ ์ ํตํ ์น์๋น์ค ์ฑ๋ฅ ๊ฐ์ - select_related, prefetch_related (https://wayhome25.github.io/django/2017/06/20/selected_related_prefetch_related/

https://www.slideshare.net/perhapsspy/django-42665652


์ฌํ ํํ ๋ฆฌ์ผ: ์ฌ์ฌ์ฉ ๊ฐ๋ฅํ ์ฑ์ ๋ง๋๋ ๋ฒ (https://docs.djangoproject.com/ko/3.1/intro/reusable-apps/)Django Tutorial Blog ๋ง๋ค๊ธฐ - 3. ์ฑ (https://nachwon.githu
Pycham์์ Django(์ฅ๊ณ ) ์ค์น ๋ฐ ์คํํ๊ฒฝ ๊พธ๋ฏธ๊ธฐ (https://bk-worm.tistory.com/4)

https://nachwon.github.io/django-3-app/

https://en.wikipedia.org/wiki/Django_Reinhardthttps://docs.djangoproject.com/ko/3.1/faq/general/#which-sites-use-django

https://docs.djangoproject.com/ko/3.1/faq/general/\* https://docs.djangoproject.com/ko/3.1/topics/cache/
https://greeksharifa.github.io/references/2019/02/07/PyCharm-usage/
How to use Django Message Framework (https://medium.com/swlh/how-to-use-django-messages-framework-be0f380a219e)

๊ฐ์PostgresQL์ ๊ด๊ณํ ๋ฐ์ดํฐ๋ฒ ์ด์ค ์์คํ ์ ์ผ์ข ๊ฐ์ฅ ์ง๋ณดํ ์คํ์์ค ๋ฐ์ดํฐ๋ฒ ์ด์ค ์์คํ ์ด๋ผ ํ ์ ์์Unix/Linux,MAC OS, Soraris, Window ๋ฑ์ OS๋ฅผ ์ง์ํจPostgreSQL์ ์์ ๋ฌด๋ฃ ์ํํธ์จ์ด์ํน์งmulti-version co

QuerySet API reference (https://docs.djangoproject.com/en/3.1/ref/models/querysets/
๊ณต์๋ฌธ์๋ฅผ ๋ณด๋ฉด์ ์ฅ๊ณ models.py ์ดํดํ๋ ์ค์๋๋ ์ดํดํ ๋ด์ฉ์ PTT๋ก ์ ๋ฆฌํ๋ ์ค:https://docs.google.com/presentation/d/1oyb-JHkUlhafFBtw2jihOwv_bvqX9gFvaaVKfVowCDs/edit?usp

Reference
https://c10106.tistory.com/4194\* https://dailyheumsi.tistory.com/33https://ko.adpc37.org/opinion/what-s-the-difference-between-a-pip-i
swagger๋ฅผ ์ด์ฉํด๋ณด์! 1ํธ (https://real-dongsoo7.tistory.com/58)
Design Philosophies๋๋ผ๋ ๋ฐ๊ฐ ๋ง์SW๋์์ธ๐ทโโ๏ธ:"Django, แแ ฅแแ ณแซ แแ ตแ แ ฅแแแ ฆ แแ ณแธแแ ตแแ ก." ๋ฆฌ๋ทฐDjango์์ ๋น์ฆ๋์ค ๋ก์ง ๊ด๋ฆฌํ๊ธฐHow to use Django's Proxy ModelsWhere to put business l
RESTfulํ API๋ฅผ ๋ง๋ค์ด ๋ณด์!RESTful API๐ก: ๋์ swag๐ swagger!์ง๋ ฌํ(serialize)๋ ์ ํฉํ ๊ตฌ์กฐ๋ก ์ฌ๊ตฌ์ฑํ ์ ์๋ ํฌ๋งท์ผ๋ก ๋ณํํ๋ ๊ณผ์ ์ ์๋ฏธPython Django ๊ฐ์ข : ์ 7๊ฐ - Serializers (https&#

์ฅ๊ณ ๋ก URL query string์ ๋ง๋๋๋ฐ..ํ์ด์ฌ์์ ํจ์/๋ณ์๊ฐ ๋๊ฐ์ ๋จ์ด๋ก ์ด๋ฃจ์ด์ง๋ ๊ฒฝ์ฐ์๋์ ๊ฐ์ด, ์ค๋ค์ดํฌ๋ ๋ค์ด๋ฐ ๋ฃฐ์ ๋ฐ๋ฅธ๋ค์) data_kind๊ทธ๋ ๋ค๋ฉด URL์ ์ด๋ป๊ฒ?์ฐ์ธ์!๊ตฌ๊ธ ๊ฒ์์์ง์ด ์ธ๋๋ฐ๋ก ๊ตฌ๋ถ๋ ๊ฒฝ์ฐ๋ ํ๋์ ๋จ์ด๋ก ์ธ์!๋ฐ๋ฉด์,ํ์ด
https://lincolnloop.com/blog/using-setuppy-your-django-project/

https://startcodingnow.com/two-scoops-django-config/

Django Annotations and Aggregations (https://medium.com/better-programming/django-annotations-and-aggregations-48685994d149)

https://docs.djangoproject.com/en/3.1/topics/class-based-views/intro/
http://id8436.iptime.org:8080/mediawiki/index.php/%EC%9E%A5%EA%B3%A0:%ED%9A%8C%EC%9B%90%EA%B4%80%EB%A6%AC

https://code.djangoproject.com/ticket/30084
https://twpower.github.io/19-about-python-test-fixture
https://devlog.jwgo.kr/2019/06/05/how-to-set-server-to-serve-django/https://wikidocs.net/76904๋ฐฉ๋ฒ2)
https://ssungkang.tistory.com/entry/Django-render-%EC%99%80-redirect-%EC%9D%98-%EC%B0%A8%EC%9D%B4
์ฑ /Two Scoops of Django 3.x

๋ชจ๋ ์์ ์ ์ฌ๋ฌผ์ ์ธ๊ฒฉ?!์ ์ฌ์ ๋์ฌ๋ฌผ์ ์ํผ์ ๋ฃ์ ๋ ์์ฑ๋๋ค.interface๋ ๊ธฐ์ ์ ์ํผ์ ๋ํ ๊ฒ ๊ฐ๋คํด๋ฆญํ๋๋ฐ ๋ฐ์ํ์ง ์๋๋ค๋ฉด๋ถ๋ฌ๋ ๋๋ต์ด ์๋ ๋๊ณผ ๊ฐ๋ค์ฌ์ฉ์๊ฐ ๊ธฐ์ ๊ณผ ์ํตํ๊ณ ์๋ค๋ ๋๋์ ๋ฐ๋์ ์ ๊ฒฝํ์ ์ํด ์ค์ํ ๋ถ๋ถ ์ค ํ๋๋ ๋ก๋ฉ์ด ์์ ๊น
https://realpython.com/django-migrations-a-primer/
https://blog.live2skull.kr/django/django-orm-03-group/
https://docs.djangoproject.com/en/3.2/topics/auth/passwords/
https://docs.djangoproject.com/en/3.1/topics/auth/default/