Anonymous
Forms are needed to develop webpages with Django You could avoid them if you think to use DRF only
Ok like I was doubted because if I could use form without creating a forms.py and just by only depending models and html
Chikal
Ok like I was doubted because if I could use form without creating a forms.py and just by only depending models and html
I develop healthcare management system and industrial monitoring system without forms.py
Chikal
for me forms make it difficult to costumize form UI and handle any custom POST request etc
Chikal
just because my client desires specific features, and I find it challenging to customize using Django forms, so I decide pure html
Raad
just because my client desires specific features, and I find it challenging to customize using Django forms, so I decide pure html
Forms made my life easier. It's a great way to validate user inputs before it hits your view code. Also, I can easily include and exclude whatever field in the model because sometimes I don't need all the fields in some places. All I need is to loop over the label names to generate the fields. There are more advantages such as the easiness of understanding the code later
Believe
I want a suggestions that is it better to append slash at end of every url ?
Raad
What about UI of forms?
In the template code you can do it or in the forms.
Raad
I want a suggestions that is it better to append slash at end of every url ?
What do you mean exactly? Like why you want to append slash to every url?
Believe
To end with slash or not
Muflone
No
The user model must be set as the first thing, before running makemigrations and migrate
Rom..
AttributeError: Manager isn't accessible via student instances
Rom..
Okk
Promiscuous Ferris
i have always heard that django is a back-end development framework, but the way that vanilla django goes into rendering html is way too aggressive for it to be called a back-end framework.
Promiscuous Ferris
In that context then how do you use Django’s forms? Like totally abandon it or use certain features only
django's forms are completely related to templates. so i don't know if that's a possibility. but for now, i'm using serializers which are free from template hassles
Sid
This page isn’t working right nowIf the problem continues, contact the site owner. HTTP ERROR 405
Sid
anyone else got this error while making social media app from book
Charly
This page isn’t working right nowIf the problem continues, contact the site owner. HTTP ERROR 405
Did you put that on a server or is your local version? Have you googled what 405 http code means?
Sid
its on my local server
Sid
and i googled it also on stack overflow i didn't get any solution
Charly
its on my local server
Do you have DEBUG = True in the settings?
Sid
yes
Charly
405 method not allowed means you are sending a GET request to a POST view for example.
Charly
yes
Then it should show the common Django errors with traceback and so on. Not that message.
Sid
but i does'nt know why it did'nt show me the traceback
Sid
path('logout/', auth_views.LogoutView.as_view(), name='logout'),
Sid
this is the path which is not working
Sid
Method Not Allowed: /account/logout/[31/Dec/2023 12:49:11] "GET /account/logout/ HTTP/1.1" 405 0
Charly
Method Not Allowed: /account/logout/[31/Dec/2023 12:49:11] "GET /account/logout/ HTTP/1.1" 405 0
As I told you that view only accepts POST not get: https://docs.djangoproject.com/en/5.0/topics/auth/default/#django.contrib.auth.views.LogoutView
dot_ipa
when install channels and django-eventstream i get error no model channels , why ?
Mahesh
How to do jwt time based Otp authentication using django rest framework anyone have links or information share me
Raad
are you a full-stack dev? are other any react/vue etc. devs in your team? cuz i think that rendering html using forms is not an option when the front end dev wants their own rendering.
You can render it using whatever you like but you need to validate user inputs using forms.py. You don't want the user to give you a number for a date field because I can change anything I want in the client side. Also, you don't want to validate the input in the view code. I hope you got me.
Raad
Use filter instead of all() I don't know how your models look like and how the user selected objects looks like
Promiscuous Ferris
You can render it using whatever you like but you need to validate user inputs using forms.py. You don't want the user to give you a number for a date field because I can change anything I want in the client side. Also, you don't want to validate the input in the view code. I hope you got me.
That’s the thing though. I know there are different render engines but can those work with delicate and complex designs made by front end devs? One standard of working as of now is: Backend dev recies json, returns json. The the front end will not be limited by the backend. It’s a good abstraction.
Promiscuous Ferris
I find the serializer method much more sane for a back end framework. And the reason they didn’t go with that in the first place is weird to me. And they’re reluctant to integrating serializers into vanilla django. Don’t get me wrong. Forms and listviews work fine for a small project when you don’t know much front end. But i think it’ll cause a lot of problems when you’re working alongside front end devs. If anyone has worked with forms in a huge company with seperate teams for front end, i would like to know about their experiences.
Mehrdad
Hi Does anyone has a django CRM source with full functionality and practical usage?
Rajan
Can anyone tell me how we can have add money option from bank to wallet
TSS
Hello friends, do you have a Django training course on Telegram?
Manish
Hi, is this possible to authenticate only login page 📃 without sign up page
𝙼𝚊𝚖𝚋𝚊𝙳𝚎𝚟
Narendra
hello can i know which richtexteditor can i use with django seamlessly
Rupesh
select level1user,string_agg(level2user::text, '||') from public.tbl_levelvslevel group by level1user how to write this query equivalent code in django ORM?
Narendra
Tinymce
can i customize that according to my need
Roy
Can anyone please suggest me a good YouTube course for drf ( django rest framework ) where it covers from fundamental to project based topics
Roy
Try this https://youtu.be/c708Nf0cHrs
Thanks brother for helping.
ʜᴀssᴀɴ 🥴
Tell me about django please
Anonymous
Guys my frnd asked whether he should learn mern stack to django what should I say? He wants to earn and he said he wants job
py
Could some tell me the best but free platform to deploy Django project please?
Arman
guys how u handling static files paths in html ? I mean it's kinda boring to do it mannually, so do u use any kind of tool or scripts ?
King of dollars
Hostinger is also good
𝙰𝚜𝚑𝚠𝚒𝚗
Netify
Netlify is only for the deployment of modern static sites
King of dollars
Muflone
Could some tell me the best but free platform to deploy Django project please?
For very easy requirements, python anywhere is the most easy to use
Arman
Auto django extension(vscode)
Any alternative for pycharm community edition?
Doragonsureiyā
Any alternative for pycharm community edition?
Your question is not related to Django. If it's a Python related question go to @Python group, otherwise please move to @PythonOfftopic group and ask there.
Driptamine
how to configure django, so that when you type startproject it would use postgres instead of sqlite3, I’m tired of going into settings.py every time :/
Muflone
how to configure django, so that when you type startproject it would use postgres instead of sqlite3, I’m tired of going into settings.py every time :/
you can add --template to provide a custom template directory https://docs.djangoproject.com/en/5.0/ref/django-admin/#startproject
Muflone
wow, could you share any templates for postgres?
get the standard template (it's linked in the page) and customize it
Driptamine
i can't find, anyway thank you for this --template flag