Deepak R
I am very confused in when to use APIView and when to use viewset ?
Deepak R
Please can anybody suggest some good examples.
inchidi
I am very confused in when to use APIView and when to use viewset ?
use APIView when you want to do uncommon things like certain calculation without "crud" any data. use viewset when you want to make crud for certain model in no time
Vaibhav
I want ro run My app from other machine , how do i do this
Mirco
Stop asking help, ask what you need
Shubham
so basically I am going though the multi user authentication
Shubham
in DRF
Shubham
https://www.goldencloud.co/multiple-custom-user-auth-models-in-django-rest-framework
Shubham
followed this and my project as https://github.com/shubham1507/school
Shubham
it has an error
Shubham
AUTH_USER_MODEL refers to model '%s' that has not been installed" % settings.AUTH_USER_MODEL django.core.exceptions.ImproperlyConfigured: AUTH_USER_MODEL refers to model 'user_management.User' that has not been installed
Shubham
https://dpaste.de/xbSc
Mirco
https://dpaste.de/xbSc
What's user_management ?
Shubham
Auth model
Shubham
means I went throuhg the link and followed it
Nithin
https://dpaste.de/xbSc
Your user_management app is not installed.
Shubham
okay
Nithin
Add it in INSTALLED_APPS
Shubham
🆗
Shubham
thanks @nithinmurali
Artyom
Hello, Guys!!!
Artyom
How to fix this problem: <django.db.models.fields.related.ForeignKey> is not JSON serializable.This is comes when I tryiing to POST or GET from frontend
Artyom
share your code 😊
https://stackoverflow.com/questions/55616356/typeerror-at-django-db-models-fields-related-foreignkey-is-not-json-serial I think you have seen it already))
Artyom
I have model with few fields with Many-to-one relationship. Are ForeignKey fields. And one from them (or all) has problem with serializing
Artyom
Serializer.py looks like usuall
Artyom
I really haven't idea what is wrong
Mirco
yep but what's your actual code ? not his one
Artyom
yep but what's your actual code ? not his one
There is actual code, but it hasn't general diffirences. https://pyfiddle.io/fiddle/486edc79-6252-4d9e-86a9-5ba8e6dccd25/?i=true
Artyom
problem with FcaUse serializer
Mirco
You are offtopic, find a js group
E
Guys i want to hear your opinion: frontend vs backend?
Muflone
Middle-end
Firdaus
No-end
Sebastian
Without-end (?)
Guillermo
middle out?
Anonymous
Guys i want to hear your opinion: frontend vs backend?
ass is good but some of us prefer boobs
Anonymous
Hello Everyone , i a new to python and programing all together , i have been trying to install django but i cant understand what is wrong any idea ? http://prntscr.com/ndpgxc
Anonymous
Hey frienda
Guillermo
Anonymous
thanks just did it . it worked )))) i really appriciate your time )))
Anonymous
http://prntscr.com/ndpiuy
satyam
pip install --force-reinstall boo*
Thanks a lot The problem got solved I forgot to mention in this group
Pk
How to do selective update in crud operation in django rest framework using serializers??
Pk
Now it's working only when I update all the fields otherwise it showing field required
Juris
Guys, I'm looking to build a webapp that extends AbstractUser into User, and then User further into 2 types of users: Candidate & Recruiter. Question: What Django module/app/feature would you recommend to implement 1-to-1 messaging between these two users? Caveat: At a later stage of development, it's meant to include logic that would only allow one of the User subclasses (i.e. Recruiter) to initiate the messaging, and would later need to include ability exchange automatically generated documents, securely.
Diego
Does someone know how to make a custom logging handler? Because mine is only triggered/reached when DEBUG=True I have opened a question in SO. In case someone might help they can find the code there: https://stackoverflow.com/questions/55747658/custom-logger-is-not-being-triggered-when-debug-false/55748760#55748760
Diego
But none of those docs help
Diego
I have followed exactly the documentation, but can't get it working
Mirco
So read again, read better and keep playing with logging 😁
Diego
I've been doing so for 4 hours 😅 But thanks anyway, I'll see what I can find
Diego
Little question: If I declare a language in settings.py as ('pt_BR', _('Portuguese')),, I guess that the locale folder has to be pt_BR and not pt-BR, right?
Diego
Have you checked on docs ?
Yeah, but it's weird
Diego
I have a language Selector which makes a post to the i18n url, without modifications All languages work properly, except that one
Diego
If I pick that one, page reloads but the language is set to English, default one
Diego
And docs say that pt_BR is the correct locale name
Mirco
Mmm share your code , it's better
Muflone
Can I share an interesting article on optimizing Django ORM queries? (Not mine)
Алишер
well, I think noone kill you for that 😅
Muflone
It's not meant for spam. It was published today on Medium. I'm not affiliated in any way
Muflone
https://medium.com/@ljodal/pushing-the-orm-to-its-limits-d26d87a66d28
Muflone
If they ask you money to read it, just open an anonymous browser session
Ronald
Hey guys. Any reason why this wouldn’t be working? https://dpaste.de/rcri
Ronald
it’s via Ajax call
Ronald
I receive the data fine
Ronald
but it’s not authenticating - returns None
Anonymous
Anyone knows, Good books for Advanced Django Development based on version 2.2
Anonymous
i have been learning basics for a while and now i want to go deep
Mirco
Anyone knows, Good books for Advanced Django Development based on version 2.2
Federico Marani's Practical Django 2 and Channels 2