• 개발

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#4, 로그인과 auth인증

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#4, 로그인과 auth인증

    4 - Authentication and permissions - Django REST framework Currently our API doesn't have any restrictions on who can edit or delete code snippets. We'd like to have some more advanced behavior in order to make sure that: Code snippets are always associated with a creator. Only authenticated users may create snipp www.django-rest-framework.org 장고 튜툐리얼#4 포스팅이다. 인증 및 권한을 다루는데 게시물을 작성할때 유저체크를 하고, 유..

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#3, 장고 Class view, mixins, generic view

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#3, 장고 Class view, mixins, generic view

    3 - Class based views - Django REST framework We can also write our API views using class-based views, rather than function based views. As we'll see this is a powerful pattern that allows us to reuse common functionality, and helps us keep our code DRY. We'll start by rewriting the root view as a cla www.django-rest-framework.org 함수형이 익수해졌기 때문에, 굳이 class형으로 view를 짜야할까라는 의구심이 가득했었다. 그러나 해당 튜토리얼을..

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#2, request.data, Response,

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#2, request.data, Response,

    2 - Requests and responses - Django REST framework From this point we're going to really start covering the core of REST framework. Let's introduce a couple of essential building blocks. REST framework introduces a Request object that extends the regular HttpRequest, and provides more flexible request pars www.django-rest-framework.org 튜토리얼#2 에서는 requset와 response 그리고 status를 그냥 status를 보내는 것이 아..

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#1, serializers 사용법

    [Django] django-rest-framework 공식문서 튜토리얼 따라하기#1, serializers 사용법

    1 - Serialization - Django REST framework This tutorial will cover creating a simple pastebin code highlighting Web API. Along the way it will introduce the various components that make up REST framework, and give you a comprehensive understanding of how everything fits together. The tutorial is f www.django-rest-framework.org 장고공부를 시작하면서 순수장고의 MVT패턴을 이용해 장고로 백엔드 서버를 만들어 봤었다. 그 이후 리액트로 프론트 장고를 A..

    [Django] 리액트 장고 연동#4, url구조, 장고로POST GET DELETE 서버 만들기, DRF없이 JSON 프론트로 보내기

    [Django] 리액트 장고 연동#4, url구조, 장고로POST GET DELETE 서버 만들기, DRF없이 JSON 프론트로 보내기

    [React] 리액트 장고 연동#3, GET,DELETE,POST 요청 장고로 보내기, POST,DELETE후 자동으로 GET하기, 리액트 [React] 리액트 장고 연동#2, 리액트 한 파일에서 두개 컴포넌트 만들기, 구조분해를 사용하여 props [React] 리액트 장고 연동#1 , input태그 여러개한번에 관리하기, React에서 form사용하기 앞전에 node.j devforyou.tistory.com 프론트에서 장고로 요청하는 거 까지 #1~#3까지 완성했다. 이제는 장고에서 request에 대한 response를 쏴줄 차례이다. 인터넷 검색하면서 나름 공부를 하면서 어떻게 설계해야할지 고민했는데, 보통 DjangoRestFramework(DRF)를 많이 사용하는 듯 했다. 자동으로 시리얼라..

    [React] 리액트 장고 연동#3, GET,DELETE,POST 요청 장고로 보내기, POST,DELETE후 자동으로 GET하기, 리액트 함수 자손으로 내려보내기

    [React] 리액트 장고 연동#3, GET,DELETE,POST 요청 장고로 보내기, POST,DELETE후 자동으로 GET하기, 리액트 함수 자손으로 내려보내기

    [React] 리액트 장고 연동#2, 리액트 한 파일에서 두개 컴포넌트 만들기, 구조분해를 사용하여 props [React] 리액트 장고 연동#1 , input태그 여러개한번에 관리하기, React에서 form사용하기 앞전에 node.js를 한참 공부했었는데, 공부해보면서 나한테는 사실 뭔가 잘 맞는거 같지가 않았다. 조금 체계 devforyou.tistory.com 두근두근 이제 만들 틀은 다 만들었다. axios를 사용하여 데이터를 주고, 또 받아오도록하자. #api명세 [Back-end 구현사항] 1. 먼저 추가를 누르면 제품이 추가되야한다! 2. 삭제를 누르면 제품이 삭제되어야한다! 3. DB에서 제품의 정보를 받아올 수 있어야한다! 난 그렇기 때문에 장고 백엔드를 다음과 같이 설계할 것이다. M..