Mukesh
https://stackoverflow.com/questions/66560724/applying-selected-model-data-to-form-django
b
hey guys, I'm creating social media websites for my final year project.. so I'm using abstractuser User to define user roles, my question is that should I add other fields of profile like name, picture, description etc in abstractuser User or make another onetoonefield UserProfile model to User? which is better and why
AMIN
Can anyone introduce me a video for learning Django rest
b
If you want to create a user from scratch then use AbstractBaseUser
I'll use abstractuser to define user roles, what I'm asking is which is best.. adding those fields(name, description etc) to inherited abstractuser User or make another separate model UserProfile/Profile ?
Luis
I'll use abstractuser to define user roles, what I'm asking is which is best.. adding those fields(name, description etc) to inherited abstractuser User or make another separate model UserProfile/Profile ?
I think that creating a profile model is better than extending user class. Because you let Django take care of user's staff and you can add all you need to user's profile. Remember to add some signals to create or update profile after user creation/modification.
Luis
Hope it helps
Doragonsureiyā
Can anyone introduce me a video for learning Django rest
Are you looking for Django REST Framework documentation? Here you have it: https://www.django-rest-framework.org/
Anonymous
Can anyone tell me if django can be a full time career or not ..should I focus on other things too?
Charly
Can anyone tell me if django can be a full time career or not ..should I focus on other things too?
there are a lot of poeple doing django full-time, and you should aslo focus on other things relatated to development (e.g git, sql, servers, etc)
Anonymous
https://i.imgur.com/E64Cwqq.png
Anonymous
Anyone knows how to solve this error??
Charly
Anonymous
yout cut the erro message
celery-service_1 | django.db.utils.OperationalError: ('HYT00', '[HYT00] [Microsoft][ODBC Driver 17 for SQL Server]Login timeout expired (0) (SQLDriverConnect)')
Anonymous
I know, but this only happens on Celery My app is working OK
Anonymous
I can log in and use the web app normally, but celery is not working https://i.imgur.com/hsCt3nK.png
Anonymous
What should I do?
Yulia
Hi all. I have a question about forms. For example i have a list of authors and i want by the click on one author go to a form only for this author's books. How i can do it?
Someone
Hi, I am working with django. I have a queryset with which am calculating rank using dense rank. When am applying filter on queryset window expression is applied on filtered queryset. Is there a way I can keep the ranks persist ?
Anonymous
django-decouple is not updating my alterations on .env file
Damron
hi! do u know is it possible to add same as in left side search input to the right side in filter_horizontal in admin?
Shivendra
Can anyone suggest me how to improve business logic in django
𒂵𒐊𒍝𒊏
Hi i am makeing new model & i makeing makemigrations & migrate &register it in admin. py but its does not work
𒂵𒐊𒍝𒊏
What is the error message?
operational Eroor ar /admin/app name/model name
𒂵𒐊𒍝𒊏
no such tabel: app name_model name
Sodaney
manage.py migrate --run-syncdb
Sodaney
Try this command
Chandu
Python manage.py sqlmigrate (app name& on model migrate number)
𒂵𒐊𒍝𒊏
Sodaney
Here are some solution you might need: https://stackoverflow.com/questions/34548768/django-no-such-table-exception
Deleted
https://stackoverflow.com/questions/66594047/add-request-authentication-for-ldap-login-in-django
𒂵𒐊𒍝𒊏
i rmove my sql & i hope it work
𒂵𒐊𒍝𒊏
it work
Anonymous
https://i.imgur.com/Z1zBrIW.png
Anonymous
'HYT00', '[HYT00] [Microsoft][ODBC Driver 17 for SQL Server]Login timeout expired (0) (SQLDriverConnect)'
Anonymous
receiving this error when I try to connect to MSSQL
Anonymous
I am using the django-mssql-backend modulle
Neo
Can you send the codes of model and serializer field
Hi Please find the model serializers and views code https://pastebin.com/iCKyjBMm
Ganesh
How can I test my real-time chat application on local host? I have to log out one user and then log in with other user to check msg. So page is getting reloaded so I am not sure if it is real time chat any Solution ?
Fox
{% if section =='dashboard' %} not working
Fox
It says could not parse the remainder
Ganesh
Use incognito mode and normal mode together
Never thought solution was as simple as that. it's working... Thanks 🙏
Fox
https://stackoverflow.com/questions/66595094/operator-not-working-inside-an-html-element-in-django-template
Fox
Can somebody take a look at this please
Arslan
Add proper spacing and it will work. – Abdul Aziz Barkat 7 mins ago
Arezoo
hi,how can i solve this problem?
Arezoo
https://github.com/postmanlabs/postman-app-support/issues/6780
Arezoo
How is this related to django?
i want to run request of django drf,and i can not login in postman!!
🅐🅢🅗🅘🅚
Hi Please find the model serializers and views code https://pastebin.com/iCKyjBMm
Try giving the name of the fields inside the models instead of the ones you assigned in serializers. Eg :- master_events = MasterEventSerializer(many=True, read_only=True) to vc_main_title = MasterEventSerializer(many=True, read_only=True) If its not working, try calling them as keys and values and assign them to a new dict. It's better, cause we can assign things as preffered for the json response *Note = I am just a beginner and can't say these will work perfectly. But, I have a working app with serializations(based on abstract data).
🅐🅢🅗🅘🅚
Kk
Anonymous
When we click button the output should receive from the backend..? Can any one help me with this..?
kritikos
When we click button the output should receive from the backend..? Can any one help me with this..?
With output ? What you what to show on the web page ? You can make ajax call to your backend to retrieve data you want to show
Anonymous
Yaa i want to display outpot un webspage
kritikos
Yaa i want to display outpot un webspage
Ok . Use ajax/axios call to your backend . https://stackoverflow.com/questions/13733767/django-button-ajax-click
Anonymous
Okay
kritikos
Okay
👍
Onks
How do I used a model class more than once?
Onks
If that doesn't make sense.. I have a list of colleges and each college can have a varying number of courses
Onks
Right now I can just store one course with my model class but I need to be able to store multiple courses. any ideas? Thanks
Onks
Il just kill myself if all that made no sense ._.
Hamouda
{ "user": { "username": "string", "email": "user@example.com", }, "birthDate": "2019-08-24", "phone_number": -2147483648, } ================================= { "id": 0, "uri": "http://example.com/", "username": "string", "email": "user@example.com", "birthDate": "2019-08-24", "phone_number": -2147483648, }
Hamouda
how to change from first response to second :/
Hamouda
i have a nested user in a model Client
Hamouda
i dont want it to represent it as nested
Almaz
Hi guys, how to run celery worker and beat in the background on the Ubuntu server, who know, please help)