Jennifer
https://dpaste.org/T8JRq - urls page
Jennifer
https://dpaste.org/rmGvt - donate.html
Charly
https://dpaste.org/Q3K6i
This code is not properly indented, we need the real code you are using
Jennifer
I pasted this from my views file in my project folder. May I know which code you need?
Charly
I pasted this from my views file in my project folder. May I know which code you need?
I don't know how you pasted it but just look at it, the indentation is messed up
Jennifer
One second I'll check again
Jennifer
https://dpaste.org/rkPd7 - views
Jennifer
is this okay?
Jennifer
https://dpaste.org/jmwPT - donate.html
Charly
https://dpaste.org/rkPd7 - views
You need to compare it with GET not get. But I recommend you to use POST, ir it won't show the form. And do not out the full code in that try catch that does nothing or you'll hide errors silently.
Jennifer
I tried to change it to GET and also changed it to POST. Still not working.
Faraz
I tried to change it to GET and also changed it to POST. Still not working.
Restart the Dajango Server Again The Reapply the request process.
Ohama |
Anyone know how to validate form for response_post_save_change
Doragonsureiyā
Ohama |
Impossible to help without details.
It's details if you look at in django source in part response_post_save_change exist
Ohama |
https://stackoverflow.com/a/35921686
Targoon
where is the easiest place to get a job and make money as a django backend developer
fagbemi
Hello devs I want to implement a notification in a Django restframework project i want the notification to be sent from my Django server to mobile apps.eg when a user buys a course I want to send push notifications to the user from django server which best options will u recommend
dimmmmmma
Please help optimize the Django ORM query, I don't understand how to attach something here from .select_related()/.prefetch_related() /.prefetch_related(Prefetch()) and whether it help MailingSettings.objects.filter(settings__user__email__in=data, something=True) data = set(...) settings = models. OneToOneField(ReportingSettings) user = models.ForeignKey(settings.AUTH_USER_MODEL)
Yeganeh
Hi I wanna use zarinpal gateway for our site payment developed by django and react.js When a request payment is successful zarinpal call our verify route how to redirect to react and android app if transaction success?
Georg
hello, how can I name related fields when I inherit models ?
SudheerG
Can someone help me with below piece of code that is failing to create a product? def perform_create(self, serializer): pk = self.kwargs.get('pk') stores = Store.objects.get(pk=pk) serializer.save(sto=stores) Django Error: Store matching query does not exist.
Koen de
Can someone help me with below piece of code that is failing to create a product? def perform_create(self, serializer): pk = self.kwargs.get('pk') stores = Store.objects.get(pk=pk) serializer.save(sto=stores) Django Error: Store matching query does not exist.
By default a new object does not have a pk just yet. So pk from self.kwargs will be None or zero right? Are you using a ModelSerializer? Check this for inspiration https://stackoverflow.com/questions/69751582/how-to-properly-extend-create-method-in-model-serializer or https://www.django-rest-framework.org/tutorial/1-serialization/#working-with-serializers
Koen de
Yes I am using ModelSerializer & will check the link.
Good luck. I’ve added a second link to the official documentation as well
Сергей
Hi all. I really want to get rid of a long query to my database and its lengthy processing. The bottom line is that the site, when requested, must "read the database" and build a table, but it does this a very long time. How can this process be accelerated?
AM96
Hi! Could someone help me with django code? I'm trying to create a form whit django forms but I get the AtributeError: 'ImageField' object has no attribute 'is_hidden'. I don't understand why
Muflone
is the is_hidden error shown after post or right on rendering the view?
Muflone
the is_hidden attribute is used from django. I think you're passing the data in a wrong way to the ModelForm
AM96
I think I have solved it by removing images, price and stock from widgets
AM96
Thank you for help
Cheshtaaaaaaa
Can anyone please help me in sharing any source of video to learn 0Auth with DRF
Charly
No options?
No while you don't show exactly what you are doing and how much is taking
Сергей
I can’t show, because the media is not attached here. In general, the database is large, in order to fulfill the request, the server needs to find everything in the database with the desired parameter, and then builds a table and displays.
Сергей
How big is large in your case? How much is taking?
The search is carried out in the database among 62600 records. To the question of how many records go to the output - in different ways, but not more 1600(This is maximum). Such a request is processed in about 20-25 seconds. But on average, up to 500 records need to be displayed, depending on the choice.
Charly
Can anyone please help me in sharing any source of video to learn 0Auth with DRF
What you have found and why is not working? Why don't writteng posts instead of videos thatmay be hard to follow?
Cheshtaaaaaaa
What you have found and why is not working? Why don't writteng posts instead of videos thatmay be hard to follow?
The django doc contains very less information regarding this I have more understanding of videos , sometimes written posts doesn't work for me
Charly
I don; t know how this can have less information that a video where you can't even copy code
cj
The django doc contains very less information regarding this I have more understanding of videos , sometimes written posts doesn't work for me
you're totally wrong, Django's documentation is one of the best written out there in the Internet
Cheshtaaaaaaa
you're totally wrong, Django's documentation is one of the best written out there in the Internet
Sorry man! It is best actually,was specific regarding some topic but nvm
Maq
hello, asking for help once more( I have trouble with downloading media files via admin panel the interesting part is: file is being deleted, yet downloading it from admin panel results in 404 error https://imgur.com/a/EiTm5Xm error screenshot https://pastebin.com/GYebBmFx settings.py https://pastebin.com/0KGUmb8h url.py
Masoud
helllo , i have @authentication_classes([JWTAuthentication]) @permission_classes([IsAuthenticated]) class CommentViewSet(viewsets.ModelViewSet): and def list def comments_by_product def comments_by_user Now I want this( def list ) function to be exempt from authentication
K
hello I have an application and this one thanks to a form I want to receive all the houses registered in the database according to the 'city'and display it. But when I throw my query does not return anything. Help if you can!!
K
No one can help you until you explain your difficulties.
ok can I have a Django source code allowing to retrieve all the properties registered in the database according to the name of a city thanks to a form?
Umidjon
hi guys! I have problem can u help?
Umidjon
I have deployed my websocket prpject to server but I can't create a websocket service for autorun
Umidjon
Help please
Umidjon
or who did it. gimme link for ur project doc please
AmirAli
Expected a date, but got a datetime. Refusing to coerce, as this may mean losing timezone information. Use a custom read-only field and deal with timezone issues explicitly. ??
Mirco
How can I solve it?
Share the code via pastebin.org
Илья
Hi! Is there recommended OpenID client library. I found a lot of libraries and can`t chose the right one. Many of them are outdated or not popular. Is django-oauth-toolkit appropriate lib for Client?
Maq
Url path not given the correctly please check the url once.
what do you mean? I'm using FileField for this and url is autogenerated I believe, so what do you want me to check?
Manikanta
what do you mean? I'm using FileField for this and url is autogenerated I believe, so what do you want me to check?
Actually it's showing that's url not in your url's list..... I think your url was not generating automatically please check once.
Ms
Any ideas?
Ms
For example my city model has foreign key to country But in response i only get the country id I know all the way for get country name but im very confused about what's the best way for this ( cleanest) repesent function and serializers data in that. Use a char field and use source params like ( country.name ) Or using stringrelated field Or using the entire country serializers Country = country serializer() Or using depth key in city serializer Or write a property inside city model to return self.country.name and use this method inside serializers
Ms
Thanks dude
🟢 Denys
Hello Django community Need a little help ) I studied Django with REST framework and Postgre SQL some time ago. It was great ) I want to refresh this knowledge, with some tutoral or guide of building a simple project. Can you suggest ? Thank's a lot.