Mirco
@pyflare
All this stuff is backend job not template side
Mirco
Take a book , tutorials etc and study more Whatever books will show you an example exactly like what you wanna achieve For example Practical Django 2 will show you an e-commerce like with statuses etc
Anonymous
All this stuff is backend job not template side
i did in backend no result but in template it give at least a result
Mirco
i did in backend no result but in template it give at least a result
You need to study more, you are a bit confused
šяıяαм〘CID〙
File "D:\Project\manager\views.py", line 87, in otpVerify login(profile.user,request) File "C:\Users\MY PC\AppData\Local\Programs\Python\Python310\lib\site-packages\django\contrib\auth\__init__.py", line 106, in login if SESSION_KEY in request.session: AttributeError: 'CustomUser' object has no attribute 'session' Bro i am getting this error any sol
Anonymous
You need to study more, you are a bit confused
i developed 3 database and sold it already in django this was the first time i encounter this error
šяıяαм〘CID〙
Anonymous
Pythonero
yes bro
and did u configure it in the settings.py file?
šяıяαм〘CID〙
and did u configure it in the settings.py file?
i have done everything i have done with login and signup they are working fine now i like to add otp in my login page then i have encountered that error
šяıяαм〘CID〙
Pythonero
views? or complete code
Share your code here. No DM. Bro.
Pythonero
views? or complete code
Also your models.py.
šяıяαм〘CID〙
Also your models.py.
https://pastebin.com/LLwE8HMt
Hunter
Hunter: Am facing issues with my first django app, even if I change urls.py, settings.py and views.py. Still am getting same output Doing the same as mentioned in the documentation and on videos, still having same issue
Dharmu
Django api call working in debug but after deployment it gives xmlhttprequest error in flutter web and in chrome console it gives *has been blocked by CORS POLICY
༒•Ⱨ₳Ɽ₴Ⱨ•༒
Hunter
Can someone share with me the hello world program in Django, Actually while going to localhost:8000/my-app, getting a 404 error. Tried multiple times and check settings, urls.py, views.py. But same issues
-------
How to see the raw SQL queries Django is running?
运维
But it gives error
remove cors from middleware in settings.py
Sergey
hi everyone. why swager not showing queryparams that must be from filterset_class and from pagination_class?
Sergey
and this only on one url (viewset)
Aloooo
Hi guys. I wrote the following code in the panel "yum reinstall cwp-httpd" . But the website is not working now. "diyetzone.com"
Doragonsureiyā
Hi guys. I wrote the following code in the panel "yum reinstall cwp-httpd" . But the website is not working now. "diyetzone.com"
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.
Jerome
what do you mean by internal external? create what you think internal then others will be external by deduction
Yazan
is there a package that i give a google map link then it gives me places near me? in django
Doragonsureiyā
is there a package that i give a google map link then it gives me places near me? in django
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.
Евгений
Plz explain
maybe you use adblock and it blocks cors
Александр
Hello, I'm just starting to work with django and the question arose how can I get query results in groups, for example, 2000 records? Model.objects.filter(created_date__range=(date_from, date_to)).iterator() returns records one by one, maybe just cut the query result? if it works in lazy mode...
Vijay
Is it possible to save a query set in views.py file.
Rex
Hi I'm using Linux ubuntu 22 And I want to locate site-package/django /contrib in the project folder but I can't see it Any help
Rex
I have created the env file and in my lib/ python3.10/site-packages I can't see django folder
运维
maybe you use adblock and it blocks cors
remove all strings including cors in settings.py
Nana
Hello guys, I am creating a poll application. The poll creator will need a question and some choices. The poll can add many as choices to the poll, How do I implement this feature in my models.py ?
Frenchie
Guys I am using POSTGIS I have a point field in my db I am creating a polygon with bounds Using from_bbox Then I am searching for points within the polygon.
Frenchie
Guys I am using POSTGIS I have a point field in my db I am creating a polygon with bounds Using from_bbox Then I am searching for points within the polygon.
My question is, if there is no points inside that polygon, How can I increase the polygon so that more area could be searched
Frenchie
I have been looking the internet since 2 days please help
Vidya
All the Coordinates of polygon .
Frenchie
Vidya
Like multiply coordinates by 2 . If you still don't find any point in it , multiply by 3 etc .
Vidya
Welcome .
Pythonero
Read the Django documentation.
Charly
By rewriting it
Abhie
Hi, i have 2 user model in 2 different apps of same project, i want one-to-one relationship between them, however at view.py when I try to store the I'd of another (User1_id = User1.objects.get(user_id = request.user.id) ) user in order to create new user throws an error
Rohan
Hello guys I'm new to django and I'm trying to run my code but it's not rendering my static files
Samrah
Is it a good idea to send base64 encoding of an image rather than the actual image from frontend to backend?
~:$
Is it a good idea to send base64 encoding of an image rather than the actual image from frontend to backend?
Depends on your choice and use case. Small images are okay but for large files you can send them as form data or binary data. Converting a image to base64 takes time if the file is large.
~:$
How large a file are we talking?
In mbs.... Everything is possible .. but for performance point of view..... Base64 increases the data comparatively binary or form data. So more data consume more bandwidth and take a litter longer to upload. Well we can neglect these things... Again it is your choice. If you want to send in KBs like icon etc then base64 is good to go. Even you can save the base64 in database. Do your search and act accordingly to your use case.
Samrah
Oh okay. Actually Im making something like an amazon product page with different colors and each color having different sets of images. I wanted to send these images to backend but didn't know how I would keep image and color relation intact
Doragonsureiyā
Looking for Django tutorials? you can follow these three recommended ones: * Official documentation and tutorial * Tutorial from MDN * Tutorial from django-girls
Woh
Hi there! There is a task: to return a list of files located in a certain directory to a get request. Its specified that the root directory is placed in config.py. What does it mean?
WIPEDREAM
Hi. Please anyone has every run into an issue. While trying to work with graphql through Django. The status code is 200 but no content or graphql form on the web it's blank.
Mihir
By rewriting it
Seems accurate.
Mihir
Hi there! There is a task: to return a list of files located in a certain directory to a get request. Its specified that the root directory is placed in config.py. What does it mean?
You have to read the contents of folder and return the list of names of file present in it. Whether you've to send the files themselves or just the names would be present in the question/task itself.
Adam
Hello, i have problem with swagger (drf_yasg). When i use custom APIView the documentation (swagger) says "No parameters". But for generics views i can see data parametrs. How can the problem be solved? Googled that Swagger captures fields from the serializer_class variable. But how can it be documented for APIView?
Alex
Hi everyone👋 Help please. How to autostart background loop task at django startup. That process should to work with channels (channel group.send)
Nityananda
Free templates for creating django projects
Maxim
Free templates for creating django projects
are you asking or suggesting?
Eng_Salah Aldin Alhaj
how i can secure GOOGLE_APPLİCATİON_CREDENTIALS when upload my project to GitHub