Join my free course on working with the database and models in Django: prettyprinted.com/djangodatabase
@jacksorjacksor3 жыл бұрын
If ever I'm stuck and I see there's a Pretty Printed video about it I breath out a sigh of relief
@theshahrukhfit31544 жыл бұрын
What I have noticed in all your videos is that you cover all the things. I watched many form model videos no one showed how to use the instance parameter which I really was confused about. Somehow I knew you would cover that. Thanks for not letting me down. You are awesome!
@xtremehackerzpro95117 жыл бұрын
Nice video, especially part of object updating, keep going :)
@i701Dev3 жыл бұрын
What about a model that has relations? Can you do a video on that?
@abdelmoumenamine8914 жыл бұрын
best tutorial i have seen
@Omni_G6 жыл бұрын
Hi Anthony, one thing I always find confusing is when to use which. Like, when do I use Form? When do I use ModelForm? When do I use View? When do I use Generic View?
@prettyprinted6 жыл бұрын
Use a ModelForm when your form is very closely related to the model. Use generic view if you're doing something that a generic view gives you, like displaying a single item out of the database or a list of items.
@Omni_G6 жыл бұрын
Wait, can a normal view not display a single item out of the database with get()?
@prettyprinted6 жыл бұрын
Yeah, a normal view can do anything. The generic views are just shortcuts.
@AsaduzzamanSohel7 жыл бұрын
When will you start Django rest API tutorial? I will wait for this.
@prettyprinted7 жыл бұрын
I'm thinking next week.
@greetingsgentlemen.81794 жыл бұрын
@@mounika_bathina um ya learn
@praveenkumar-bz3qi4 жыл бұрын
I liked this video, also i watched your many django and flask videos. Could you please make a video on django-select2 module ?
@SrimalSamarasooriya6 жыл бұрын
I'm trying this. and I get AttributeError: 'tuple' object has no attribute '_meta' . Any thoughts
@prettyprinted6 жыл бұрын
What line gives you that error?
@pedrobianchi19296 жыл бұрын
I have a question. If I did have more than one model field, the app creates more than one form , right? But how do I express those different forms in the html file separately? Like I have one model for name and another for company, and I use the ModelForm, then, the app will create more than one form, and I want to express these forms in different places of my web or html file, what do I do ?
@prettyprinted6 жыл бұрын
Just give each form a more unique name than 'form' Then you can place multiple of those generated forms in your tag in your HTML. Everything else will work the same.
@nikhilbhardwaj60556 жыл бұрын
Hey can u make a video on CreateView uploading images with foreign key involved
@prettyprinted6 жыл бұрын
I'll consider it. Thanks for the idea.
@TheShash10017 жыл бұрын
Great video
@akshi.b6 жыл бұрын
Ah man where have you been my whole life????
@akshi.b6 жыл бұрын
Can you help me out a little bit? So I've created a URL shortener. I'm totally new to django so half of the time I don't know what I'm doing. So I created it for a single url but want to upgrade it so that user can add multiple url at the same time and shorten them. The url input is taken in form.py and I added a ''+'' button in my home.html, it has a submit button too. Now I want an array to be created for my multiple url and send request for each added entry to shorten it. How do I do this? Also I want my page not to reload so I have to use ajax right? I'm so confused. The app is working fine for single url shortening.
@prettyprinted6 жыл бұрын
If you want to send the request on each click of the + button, then yeah you'll need to use JavaScript and AJAX. Look into my sending request without page refresh videos here.
@akshi.b6 жыл бұрын
that's only sending request, but how do I pass the array strings one by one in database? do you have a video for that? I couldn't find it. If you do please share the link