Django Rest Framework Series - Filters and Search features - Part-6

  Рет қаралды 34,493

Very Academy

Very Academy

Күн бұрын

Hello, we are back again for the sixth tutorial in this Django Rest Framework Series. In this series of tutorials we will go through the Django Rest Framework and in addition build a React application to consume our Django Rest API. In this tutorial we look at filtering data from the database and returning it to the front-end. We got though a number of filtering examples gradually getting into more powerful techniques and tools. Once we finish looking at some examples we implement a React Front end search feature.
🎉More from this Django Rest Framework Series:
• Learn Django Rest Fram...
00:00 Introduction
01:02 Example of React Search front-end in action
06:35 Example 1 - Basic Filter
13:01 Example 2 - Filter against URL
20:48 Django-Filter 2.3.0 Optional Install
22:09 Example 3 - Search filter example
🐱‍🏍React Development
28:21 Building a simple search function
Code Repository:
github.com/veryacademy/YT-Dja...
👍SUBSCRIBE to get more free tutorials, courses and code snippets!
/ @veryacademy
👍👍Follow us on Facebook
/ veryacademycom-1132321...
👍👍👍Follow use on Twitter:
/ veryacademy

Пікірлер: 70
@arion750
@arion750 2 жыл бұрын
Great work Zander, I've learnt so much from your videos. Thank you!
@ryujinyeong
@ryujinyeong 3 жыл бұрын
I have subscribed you since last week, and i realised that this channel is the best Django and DRF tutorial i haven't seen before. Just doing stuff like this. You se great and unlock my skill :D. Thank you very much for creating youtube content like this. Hope you will get moe subscribers asap.
@veryacademy
@veryacademy 3 жыл бұрын
Welcome aboard! Appreciate you giving up your time to make that comment - hopefully we can keep on inspiring you to fulfil your goals. Any suggestions or comments that will make learning easier or better for you please just let me know either here - or if you prefer through a Facebook PM.
@mateusz.2881
@mateusz.2881 2 жыл бұрын
Thank you so much, I was looking for it for ages!
@jeraldjoshuaechavia1108
@jeraldjoshuaechavia1108 3 жыл бұрын
I'm developing here by series, and figured out that implementing search bar, makes the Single post detail error 404 by clicking in a single post, and it's because on the previous tutorial Part 5, you kind of changed that to DefaultRouter my comment is that maybe you could make use of the code repo last tutorial so that viewers don't get confuse especially when they're following the from Tutorial Part 1 until here. Thanks you so much! Good job again with this very informative tutorial!
@franklinmutwiri4342
@franklinmutwiri4342 3 жыл бұрын
Zander, Thank you so much for this wonderful playlist
@veryacademy
@veryacademy 3 жыл бұрын
My pleasure!
@safwansuhaib2930
@safwansuhaib2930 3 жыл бұрын
Thanks a lot, I've learnt a lot from you...
@OneSickBastardII
@OneSickBastardII 2 жыл бұрын
GREAT Channel!
@digitaldata-surveying
@digitaldata-surveying 3 жыл бұрын
One of the best
@taoxu352
@taoxu352 3 жыл бұрын
Thank you so much for all these excellent tutorials. I suggest that you post a guest tutorial on Traversy Media.
@veryacademy
@veryacademy 3 жыл бұрын
Thank you - that is a good idea! 👍
@user-vg9kl4ip3g
@user-vg9kl4ip3g 2 жыл бұрын
谢谢,受益匪浅
@nicocouss7849
@nicocouss7849 3 жыл бұрын
Best serie! thx a lot :)
@veryacademy
@veryacademy 3 жыл бұрын
Glad you enjoy it!
@saharamanson1970
@saharamanson1970 3 жыл бұрын
This is the best channel............................ awesome bro
@veryacademy
@veryacademy 3 жыл бұрын
Thank you so much 😀
@budi0580
@budi0580 3 жыл бұрын
I have wathcing your django series whole day. Thanks for such great videos bro. It would be more complete, if you could have videos about django + sqlalchemy. Since some folks say django orm has limitation for complex query.
@veryacademy
@veryacademy 3 жыл бұрын
Hey Budi, thank you - not even my wife wants to listen to me that much - so much appreciated. That is a great suggestion - I have planned another 20 or so ORM and can think of many more. I Agree - I tend to just write SQL if things start to get difficult. sqlalchemy makes the tutorials useful for flask users too - so again great idea - thank you!
@tiendungnguyen158
@tiendungnguyen158 2 жыл бұрын
thanks for what you make sir can i filter posts if condition slug contain key search instead of start with key search ?
@rangabharath4253
@rangabharath4253 2 жыл бұрын
Hi. Awesome tutorial. I am working on ascending and descending ordering a non model field like active clients count. I tried many ways. But not able to work it out. Can you please make a video on ordering a non model field. Please consider this as a request. Waiting for the awesome tutorial. Thank you so much
@ambrosearuwa9458
@ambrosearuwa9458 Жыл бұрын
Suggestion. Love your ecommerce series, but can you do that using django rest framework and react 18 and mui 6 Thanks alot
@elonmusk2142
@elonmusk2142 3 жыл бұрын
oooo congratss 1k subs I said you 1 day your chanel will have a lot of subs . gradualy you are achieving this
@veryacademy
@veryacademy 3 жыл бұрын
Thank you! Slowly everything is moving forward! Any ideas how we can make things better around here please, good or bad - always appreciate any feedback or suggestions
@aashayamballi
@aashayamballi 3 жыл бұрын
Thank you 👍🏽
@veryacademy
@veryacademy 3 жыл бұрын
As per normal, you are very welcome and thank you for your continues support. 👍
@sergiaguilar1
@sergiaguilar1 2 жыл бұрын
why we need two user serializers one in blog_api and the other in users?
@fkamss
@fkamss 2 жыл бұрын
I didn’t understand that whenever we inherit listview how is that get_queryset() method get called? Because that is not called by any constructor method. Please guide me, I’m coming from different programming background,
@alkfalfnsflgjslfj2127
@alkfalfnsflgjslfj2127 3 жыл бұрын
i have postgresql as backend still @full-text- search is not working ---- Unsupported lookup 'search' for CharField or join on the field not permitted --showing this error
@elonmusk2142
@elonmusk2142 3 жыл бұрын
Thank U again
@veryacademy
@veryacademy 3 жыл бұрын
Always welcome
@rangabharath4253
@rangabharath4253 3 жыл бұрын
awesome
@veryacademy
@veryacademy 3 жыл бұрын
Thank you Ranga, plenty more coming!
@GinesLA
@GinesLA 9 ай бұрын
No routes matched location "/search/?search=Ju" error
@rohanr7123
@rohanr7123 3 жыл бұрын
How do we override search_fields using the action decorator? For extra actions
@veryacademy
@veryacademy 3 жыл бұрын
stackoverflow.com/questions/53368144/filtering-on-action-decorator-django-rest-framework
@shn8822
@shn8822 2 жыл бұрын
Warning: Unknown event handler property `onRequestSearch`. It will be ignored. because onRequestSearch with maturial ui if want to use normal search bar without maturial how can i replac it i mean onRequestSearch
@Sasuke-px5km
@Sasuke-px5km 10 ай бұрын
Sir I've subscribe to you. One question that I need to now, how can we get the user information using JWT that is generated after login from the backend?
@ivayloivanov3744
@ivayloivanov3744 3 жыл бұрын
Nice series, thank you! But why the code is different in almost every next video compared to the last? Seems the code is reworked in between the videos without explanation, which makes it really hard to follow.
@veryacademy
@veryacademy 3 жыл бұрын
That is correct - sorry , this tutorial like a few in the series are meant to be stand-alone tutorial for learning purpose only. Its just showing you some options. - The new quiz api series I started wont be that way. This is one of the mistakes I made and why I decided to stop the series - I am still learning.
@arielsashcov99
@arielsashcov99 3 жыл бұрын
the search doesn't work for some reason... the frontend part was way too fast to follow
@satishkurakula
@satishkurakula 3 жыл бұрын
Hi what are your urls while you're getting the data through slug. I am not getting the output when I use slug for details. It's showing Page not found 5:11
@veryacademy
@veryacademy 3 жыл бұрын
Hey Satish, sorry my friend, please take a look at the sample code if that should help you?
@satishkurakula
@satishkurakula 3 жыл бұрын
@@veryacademy ok sure.
@satishkurakula
@satishkurakula 3 жыл бұрын
@@veryacademy Hi I found it there is a need of small change in blog_api urls: path('/', PostDetail.as_view(), name='detailcreate'), instead previously it was path('/', PostDetail.as_view(), name='detailcreate'), like this.
@shn8822
@shn8822 2 жыл бұрын
@@satishkurakula Thank you so much. Your comment was extremely beneficial to me. I had spent many hours trying to solve the problem before seeing your comment. I wish you a wonderful day.
@satishkurakula
@satishkurakula 2 жыл бұрын
​@@shn8822 that's great as my comments are helpful to you.
@satishkurakula
@satishkurakula 3 жыл бұрын
Hi I'm trying to get the data through the react but it was not getting in react but its been displayed in django url, what can I do get this issue resolved? this is the error shown in the react site : Unhandled Rejection (Error): Request failed with status code 403 and it's showing the error is in app.js at axiosInstance.get()
@satishkurakula
@satishkurakula 3 жыл бұрын
Hi there I was not able to get into post details in REACT can you please help with it. or else if you have any whatsapp group please share me the link I will connect to you through it.
@satishkurakula
@satishkurakula 3 жыл бұрын
Hi why don't you reply me.
@veryacademy
@veryacademy 3 жыл бұрын
Hi Satish, thank you for your question. I can not give you a solution based upon the information you have provided. Unfortunately I am not providing individual technical support other than, when I get time to do so reading comments and where best and able answer them. A good place to ask questions is stackoverflow 👍
@satishkurakula
@satishkurakula 3 жыл бұрын
@@veryacademy ok thank you
@satishkurakula
@satishkurakula 3 жыл бұрын
@@veryacademy can we connect in LinkedIn?
@Crouchu26
@Crouchu26 3 жыл бұрын
sadly search bar component doesnt work anymore
@veryacademy
@veryacademy 3 жыл бұрын
Ok - noted - I will take a look later and get back to you
@Crouchu26
@Crouchu26 3 жыл бұрын
@@veryacademy thank you
@shawonhossain519
@shawonhossain519 3 жыл бұрын
index.js:1 Warning: Unknown event handler property `onRequestSearch`. It will be ignored.
@veryacademy
@veryacademy 3 жыл бұрын
Thanks 👍
@shawonhossain519
@shawonhossain519 3 жыл бұрын
@@veryacademy i'm facing this problem on console
@shn8822
@shn8822 2 жыл бұрын
Did you fix this error?
@harishsivaramakrishnan6999
@harishsivaramakrishnan6999 2 жыл бұрын
in the last video you used Viewsets and recommended to use it and now you are using generic API Views !! why are you confusing the viewers??
@veryacademy
@veryacademy 2 жыл бұрын
Now the viewer is aware of viewsets and api views! Thank me later when you work on software that uses either approach 👍 Confusion is actually a great place to be at, it provides you actions to seek further clarity, on the internet that is always recommended. One persons view on code never reflects all.
@siddharthshukla3557
@siddharthshukla3557 3 жыл бұрын
this video was little disorganized. instead of mixing up everything in blog_api/views you should have explained everything one-by-one. gonna need multiple watch here... also a lot of coding was done behind the scenes which makes it unclear to viewers.
@veryacademy
@veryacademy 3 жыл бұрын
Hi Siddharth, thank you for the great feedback - I agree that many videos are not up to the standard I want to get to. Most videos I do quickly in my lunch break - I don't get time to fully review but I try my best to ensure a coherent flowing tutorial. As we grow and I get more time please expect better quality that is much more polished. I want to thank you for watching these videos in such great detail, all the best to you and your learning.
@siddharthshukla3557
@siddharthshukla3557 3 жыл бұрын
@@veryacademy yes it is already getting better day by day. all the best to you.
@alitariq171
@alitariq171 3 жыл бұрын
you are lifeline
@veryacademy
@veryacademy 3 жыл бұрын
Hi Ali, I am Zander, currently based in the UK. Nice to meet you 👍
@WtfSwitchesz
@WtfSwitchesz 2 жыл бұрын
This was the worst video of this series, usually loved the series but your code was so mismatched with previous episodes and the way you went over filters was just not understandable to be honest. Appreciate the hard work.
@veryacademy
@veryacademy 2 жыл бұрын
Thanks Sidar. It has been quite the journey over the last 2 years. I would be more than happy to remove all videos and start again fresh.
@omki2504
@omki2504 Жыл бұрын
This course sucks, all it does is cause an infinite loop
Django Rest Framework Series - CRUD with React Front-end  - Part-7
51:10
Search Products - Django Wednesdays ECommerce 26
21:05
Codemy.com
Рет қаралды 3,4 М.
Heartwarming Unity at School Event #shorts
00:19
Fabiosa Stories
Рет қаралды 17 МЛН
Who has won ?? 😀 #shortvideo #lizzyisaeva
00:24
Lizzy Isaeva
Рет қаралды 64 МЛН
Cool Items! New Gadgets, Smart Appliances 🌟 By 123 GO! House
00:18
123 GO! HOUSE
Рет қаралды 17 МЛН
Django filter And Pagination
35:17
TauhidCodes
Рет қаралды 22 М.
Django Search
1:31:18
Very Academy
Рет қаралды 19 М.
React Search Filter Tutorial Beginner to Advanced
26:50
Lama Dev
Рет қаралды 258 М.
Django REST JWT authentication |  Simple JWT
14:41
Code Aura
Рет қаралды 35 М.
My Favorite Way to Fetch Data in React
16:28
Josh tried coding
Рет қаралды 69 М.
Django Rest Framework for Beginners - Simple CRUD API
14:22
John Watson Rooney
Рет қаралды 47 М.
Heartwarming Unity at School Event #shorts
00:19
Fabiosa Stories
Рет қаралды 17 МЛН