Python Django Tutorial #6: Django Class Based Views (CBV), Django Mixins | Django blog project

Описание к видео Python Django Tutorial #6: Django Class Based Views (CBV), Django Mixins | Django blog project

This Python Django Tutorial is about Django Class Based Views or Django CBV, and using of Django Mixins. This is the 6th part of my Python Django tutorial. In this Django tutorial we'll figure out what are Django Class Based Views (CBV), what are Django Mixins and how Django mixins work, and also how to use them.

Class Based Views in Django are just Python classes that handles user response, like functions, that we wrote before. Each CBV has get(), post() and other method that handle get or post requests respectively.
The benefit of using Django Class Based Views is that we can use inheritance.
And the Inheritance mechanism allows us to use Django mixins.
Mixins are just Python classes that contains common behavior for each Django CBV that you want to create.

For example, creating of posts and tags for our Django blog requires from us to perform almost identical actions.
The difference between creating a post and tags - are just in the name of a model, a template to render, and returning object that's it.
And so we can create a Django mixin that will contain common behavior for each Django class based view.

In this Django mixins tutorial I use a low level method. I use the generic View class to create Django mixins and cbv. BECAUSE it's a Django Mixins and Django Class Based View TUTORIAL!!!

ListView and other GCBV can use anyone. But I think that it's necessary to understand how Django mixins and Django Class Based Views work under the hood. And that is why I don't use GCBV in this Django Class Based Views tutorial.


Follow me @:
Telegram: https://t.me/red_eyed_coder_club
Twitter:   / codereyed  
Facebook: https://fb.me/redeyedcoderclub


============ SOURCE CODE ================
📎️ The SOURCE CODE is available via Patreon:
  / django-3-blog-34240101  
======================================


✴️✴️✴️ Web Scraping course ✴️✴️✴️
is available via Patreon here:
  / red_eyed_coder_club  

or its landing:
https://red-eyed-coder-club.github.io...


➥ Please ➥ Like ➥ Comment ➥ Subscribe


▶️ This Django blog tutorial. List of videos:

#0. Demo
   • Python Django Tutorial #0: Demo of Dj...  

#1. Django Project Structure
   • Python Django Tutorial #1: Django str...  

#2. Routing and Handling requests
   • Python Django Tutorial #2: Django rou...  

#3. Template Inheritance
   • Python Django Tutorial #3: Django Tem...  

#4. Models. Blog Posts
   • Python Django Tutorial #4: Django Mod...  

#5. Tag Model and ManyToMany Relationships
   • Python Django Tutorial #5: Django Man...  

#6. Django Class Based Views, Django Mixins
   • Python Django Tutorial #6: Django Cla...  

#7. Django Forms. Creating Tags.
   • Python Django Tutorial #8: Django Mod...  

#8. Forms. Creating Posts
   • Python Django Tutorial #8: Django Mod...  

#9. Updating via Forms
   • Python Django Tutorial #9: Django Upd...  

#10. Deleting via Forms
   • Python Django Tutorial #10: Django De...  

#11. Using custom CSS
   • Python Django Tutorial #11: Django st...  

#12. Restricting access
   • Python Django Tutorial #12: Django pe...  

#13. Django Pagination
   • Python Django Tutorial #13: Django Pa...  

#14. Django Basic Search
   • Python Django Tutorial #14: Django Ba...  

✴️✴️✴️ PLAYLISTS ✴️✴️✴️

🔹Django 3 Tutorial: Blog Engine
   • Python Django Tutorial #0: Demo of Dj...  

🔹Kivy Tutorial: Coppa Project
   • Python Kivy tutorial #0: Demo Project...  

🔹Telegram Bot with Python (CoinMarketCap)
   • Python Telegram Bot Tutorial: Demo an...  

🔹Python Web Scraping
   • Python Ebay Scraping Tutorial: Web sc...  


➥➥➥ SUBSCRIBE FOR MORE VIDEOS ➥➥➥
Red Eyed Coder Club is the best place to learn Python programming and Django:
Subscribe ⇢    / @redeyedcoderclub  

Python Django Tutorial #6: Django Class Based Views (CBV), Django Mixins | Django Crash Course
   • Python Django Tutorial #6: Django Cla...  

#django #djangocbv #redeyedcoderclub

Комментарии

Информация по комментариям в разработке