Yash
In evening i will send u
Yash
Currebtly i am not with the pc
Naol
search it on google there is a clear explanation on medium
Hikmet
Hi everyone, I have a problem. I created custom user model inheriting AbstractUser class, with phone as login and password. Now I registered and logined through postman and got my token, okey so far. Then I connected this custom user with my products model and what I want is, when I post some product using user token in authorization headers, I want the user id to be returned to my request along with the products, but instead i get error: "user" - this field is required. P.S i swear the problem is that i forgot to override some method in my custom user, because with default User model it works fine
Hikmet
I also overdefined perform create method, but it didn't help
Hikmet
https://dpaste.org/Rp3o Here is all code needed
Creator
Hey There I developing a quiz app where I am using Next & Previous Buttons I want to select one of the option and go to next question but when I am coming back i want the option that i selected must be there but not getting it so How can i do this suggestion/refferal/topics??
Mirco
Buy it.
Anonymous
Mirco
Ok
Piracy is not supported here
Driptamine
is there way/command to start django project with default PostgreSQL database intead of SQLite?
Aleksandr
is there way/command to start django project with default PostgreSQL database intead of SQLite?
I don't know exactly but I suppose that there is not, because migrating from one DB to another is made with about 3 string of code
Driptamine
I don't know exactly but I suppose that there is not, because migrating from one DB to another is made with about 3 string of code
I really loved Ruby on Rails for that brilliant command, seemed so easy to set up PostgreSQL into project
Anonymous
Abdulloh
Hi everyone how to make data of one column don't equal to data of another column in django models
sainath
I'm new to web development having python background... Actually, I have a doubt which background is very good for web development python or javascript... because in web development javascript web framwork always takes first place(react) than django....
Kid
Python and Django whit Django rest try
Hello
I'm new to web development having python background... Actually, I have a doubt which background is very good for web development python or javascript... because in web development javascript web framwork always takes first place(react) than django....
Depends on the project bro.. If you want to quickly make a web app which will be used for internal use or suppose a MVP then django would be a good choice.. If you want something which is damn fast then go If you want to leverage async then node Im new, people with more experience please correct me if im wrong 😊
Sobhan
Hey everyone I have maken 3 models in jango But when i click them i see error
Justin
how i could download Python best tour templates? there?
usEr1024
Best bitcoin payment gateway for django app
Jack
Best bitcoin payment gateway for django app
https://github.com/cryptoapi/Python-Django-Flask-Bitcoin-Payments
Sobhan
How i can connect jango to templates?
Warlock
hji
Doragonsureiyā
How i can connect jango to templates?
Looking for Django tutorials? you can follow these three recommended ones: * Official documentation and tutorial * Tutorial from MDN * Tutorial from django-girls
Naol
this should be the last place to look for someone to hire you as a diango dev
Mirco
!job
Doragonsureiyā
Rule 🔟: Job offers are only allowed in the offtopic chat - @PythonOfftopic. To avoid being marked as spam, make your offer include skillset/techstack, salary/reward, contact information and a brief description of what work you want done.
Warlock
ok
Mirco
Even if yours is not an offer
Naol
like there are about 10000 django devs here
Arezoo
When i call serializer in method in views.py it do not get url with host.why? But when i call serializer in class it get url with host
Arezoo
Share code via pastebin
https://dpaste.org/fgQm
Arezoo
Share code via pastebin
avatar return as below : /media/avatar/brain_12x_4LZYfUf.png
Arezoo
I want to return as 127.0.0.1:8000/......
Mirco
avatar return as below : /media/avatar/brain_12x_4LZYfUf.png
Just use a SerializerMethod to return the avatar url instead of path
Hemraj
Hi my views file class BlogDetail(generic.DetailView): model = Blog template_name = 'front/blog_detail.html' And i have defined url path('<slug:slug>/', views.BlogDetail.as_view(), name='blog_detail'), And define in template {% url 'blog_detail' blog.slug %} But i am facing error when i am open my blog NoReverseMatch at /blog/ Reverse for 'blog_detail' with arguments '('',)' not found. 1 pattern(s) tried: ['blog/(?P<slug>[-a-zA-Z0-9_]+)/$']
Hemraj
Could you please please correct me where i am doing wrong?
Mirco
I used serializer.can you see my code?
Yes, can u check documentation ? So you will understand my answer
Hemraj
Thank you guys 🙏🏻 problem is resolved
Arezoo
Yes, can u check documentation ? So you will understand my answer
Thanks.but i do not know ....why when i use this serializer in class (generic.retrieve) it get full path with same url
Erfan
No, slug is a valid converter in Django
It's better to save the slug field in the model using slugify
Erfan
and yes, you are right
Mirco
It's better to save the slug field in the model using slugify
The answer is simple, that slug is empty I just bet he did not generate it pre-saving a blog instance
Gkm
how to add the number of days to recover from the computer example: January 12, 2021 +10 = January 22, 2021 help me
ken
add timedelda num_days 10
Gkm
Fichier models or views ???? day_jobs= model.datafield(auto_now=true)+timedelda num_day10??? where in place????
Neeraj
how to add the number of days to recover from the computer example: January 12, 2021 +10 = January 22, 2021 help me
Convert it into string then split on basic of space then add number in index where you want ( before add convert into int then add) and in last again convert into date format.
Arezoo
Hi can i use post method to read data?
Sumit
hi, i have both python 3.8 and python 3.9
Sumit
but when i am typing pip it is taking it from python 3.8 and when pyython then it is from python 3.9
Sumit
how to run pip from python 3.9
Vadym
how to run pip from python 3.9
Hi, I'd recommend you to use virtual environment for different python versions
Anonymous
Naol
Naol
how good is django for devops,
Naol
the testing got me thinking of that
alhrmjmml
Hi, I'd recommend you to use virtual environment for different python versions
Hi, I recommended also Conda. You can to create virtual environment, In my opinion, of form more easy and structurate.
cj
sorry give me an example on code please 🙏
do to @Python then... you need to learn Python first
Gkm
do to @Python then... you need to learn Python first
we learn every day. looking for knowledge because I do not know everything. an example suits me thank you
cj
we learn every day. looking for knowledge because I do not know everything. an example suits me thank you
move to @Python as your question is not related to Django at all, you need to learn basic Python first
Gkm
move to @Python as your question is not related to Django at all, you need to learn basic Python first
I know python. now I am in front of a web project so I have to add 10 days after an order from a customer