Django Tutorial for Beginners - 39 - REST API Serializer JSON

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

I spent a half a day trying to understand what a serializer is, was being thrown off completely until i spotted this video. Concept explained nicely without any confusions. Thank you.

shanbifi
Автор

Cinnamon Toast Crunch is indeed the greatest cereal! Truer words have never been spoken!

tantanvano
Автор

bucky you have been getting really better at teaching over the years

arashfarvardin
Автор

Finally a good tutorial about this topic, thank you!

ITZmaNiacMENZ
Автор

Bro, hope you will live forever! That is how everyone should explain things!

dekito
Автор

World class comedy right here, officer

philh
Автор

Till now I get verything :) Thankyou Bucky

shivGGG
Автор

Hi Bucky, Could you make tutorial for only just REST API in detail. Please. Cheers Wai

thanwai
Автор

Excellent and precise tutorial. thanks a lot

madhousenetwork
Автор

You make the best tutorials :) keep it up!

AndyWang
Автор

Hello, I'm unsure if I understood the way of listing the fields, for more than one model. Would it be like the following, for two models:


from rest_framework import serializers
from .models import Stock

from .modelsB import Bond


class
class Meta:
model = Stock
fields = ('ticker', 'volume')


class
class Meta:
model = Bond
fields = ('__all__')

tonyiguru
Автор

Quick tip:
Don't name your files the same as modules you're importint into that file - that can cause some hard to figure out problems :)
In this case name your serializer file just serializer.py NOT serializers.py becouse you're importint serializer from rest_framework. Cheers !

michakwiatek
Автор

Let's say I have a Django model like this:

Class City:
city_name as the model field,
Class State:
state_name as the model field,
Class Country:
country_name as the model field,

OR

Class Location:
city as the model field,
state as the model field,
country as the model field,

Now, I have a form field in my HTML template where I need to use the jQuery autocomplete to get country list in that form field.

My question is, would the country list be called from the Country Model Class or as a Model Field from the Location Model? How do I go about this?


Thanks in advance :D

donpislik
Автор

hey Bucky, from where i can read the entire django documentation?

yoco
Автор

I can access the Django admin page at the beginning but later on, it shows 404 not found can someone help me?

jasperjoe
Автор

NameError: name 'APIView' is not defined

panwi
Автор

it gives me an error on import rest_framework

nizarhawawreh
Автор

Can anyone provide the code of the above project in the github please

yashbahuguna
Автор

i hope you bought a new keyboard until now

arashfarvardin
Автор

This is the worst lecture on REST I've seen.

sto